Text fields are good if:
1. You need to store large text entries
2. You do not have to search on the value of the field
3. You don't have to join on the field

Varchar is good if:
1. You store small strings
2. You search on the field value (as n any join or where condition
3. You always (as in with all select ... from...) or use the field in joins

As a general rule I define text fields as greater than 200 characters 

The deprecation by M$ and changeover from text to varchar(max) is fairly 
painless as and when it occurs so I'll put it off until needed. One big 
advantage of varchar(max) and varchar is that you can use string functions on 
the fields, so this could sway any decisions.

Dave

-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of 
Rafael Copquin
Sent: 16 May 2012 00:10
To: [email protected]
Subject: Re: Memo Fields in SQL [was...RE: SQL Server Import & VFP Data Source]

I might be wrong. If so, I apologize

I just use SQL Server Express 2008 R2

Rafael Copquin


El 15/05/2012 04:50 p.m., Paul Hill escribió:
> On 15 May 2012 19:23, Rafael Copquin<[email protected]>  wrote:
>> At the risk of joining this thread a bit late, I would suggest you 
>> use
>> varchar(MAX) for memo fields, available only in SQL Server 2008. With 
>> previous versions (ie 2005), use varchar(8000).
> I'm pretty sure SQL 2005 supports varchar(max).
> I can say this because I recently tested my app in SQL 2005 (it worked
> fine) and I use varchar(max) in some tables.
>
> Maybe in SQL 2000 this was not supported?
>

[excessive quoting removed by server]

_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/profox
OT-free version of this list: http://leafe.com/mailman/listinfo/profoxtech
Searchable Archive: http://leafe.com/archives/search/profox
This message: 
http://leafe.com/archives/byMID/profox/[email protected]
** All postings, unless explicitly stated otherwise, are the opinions of the 
author, and do not constitute legal or medical advice. This statement is added 
to the messages for those lawyers who are too stupid to see the obvious.

Reply via email to