On Mon, 2004-02-02 at 03:10, Tim Bunce wrote:
On Sun, Feb 01, 2004 at 04:16:44PM -0800, Michael Peppler wrote:
On Sun, 2004-02-01 at 13:33, Tim Bunce wrote:
Which databases cannot accept, and do something reasonable, with a
VARCHAR field declaration of 1024 characters?

Sybase < 12.5 will throw an error on the create statement, and will probably fail on the insert as well (though I don't have a server running here right now that I can test it on).

Sybase >= 12.5 will handle the 1024 limit with no problems, although you
will get a warning message if the total width of the table could exceed
the page size (2k by default, but configurable up to 16k).

Thanks. Do you (or anyone else) know if the same issues apply to MS SQL?

On MS SQL Server 2000 running:


CREATE TABLE foo (
  id int not null identity,
  mytext varchar(1024)
)

gives no error, and:

INSERT INTO foo ( mytext ) VALUES ( 'X-repeated-1024-times' )

inserts it properly.

Chris

--
Chris Winters
Creating enterprise-capable snack systems since 1988



Reply via email to