Discussion Locked

setMaxFieldSize

0 helpful
6 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.

I'm using MS SQLServer 2000 and Java 1.3. Some columns in my data tables are greater than 255 characters. However, data in excess of 255
characters are "silently discarded". I tried using
Statement.setMaxFieldSize() without any apparent improvement. What is happening here? I didn't design the database table but I have to live with it. Any ideas?

6 replies

by eroberts

What driver are you using to connect to the database (JDBC, ODBC)? If you are using ODBC drivers, you should look at the settings for the driver in the control panel (assuming windows platform). Often there are settings there which restrict size. For JDBC, I'd need to know more.

Not looking for points here, just fishing for more information to help you out.

by Former member

Points just for caring. Enjoy

by Former member

Points just for caring. Enjoy

by Former member

I get to answer my own question. What fun... My db driver has been updated so I have to use a version that can handle varchar columns > 255. Apparently that is something new in SQL Server 7. So with the new driver and a compatibility switch of sql7=true I get all of my data. Thanks to those who made an effort.

by Former member

This question was closed by the author

This discussion is closed to new replies.