Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Varchar larger that 255 in SQL 2000 1

Status
Not open for further replies.

tmp14

MIS
Mar 28, 2001
6
0
0
US
SQL Server 2000 allows varchar greater than 255, however I am unable to return more that 255 in the select statement. I have verified that the table does accept and store the larger field size. Does anyone know how to return the full field on the select statement.

Traci
 
Hi traci,
If you are using analyzer tool, Just make sure that the no. of characters per row should be set up as per your requirement.

And if, you are using any other tool to retrieve the data then please specify it.

 

Issue this command.

SET TEXTSIZE 2048

Sets the max number of characters returned at 2048. Terry Broadbent
Please review faq183-874.

"The greatest obstacle to discovery is not ignorance -- it is the illusion of knowledge." - Daniel J Boorstin
 
I Have the same problem in SQL 7 and cannot seem to get Query analyzer to return more than 255 characters. How do I use SET TEXTSIZE - it does not seem to affect anything??
 
Just had the same issue... Seems to be a Query Analyser display issue. Assuming you are using the Query analyser, you need to go to the Tools Menu, Select Options and the Results tab and set the maximum characters from 256 per column to a larger value.

This is probably a bit late for you, but may help someone! ------
Dublin, Ireland.

 
You could use:

SELECT
CAST([Your Field Name]as varchar(500))
FROM [Your Table Name]

Note: The Maximum for SQL 2000 is 8000 characters
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top