If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > Sybase > col lenth of 255??

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 03-07-03, 17:49
nmr nmr is offline
Registered User
 
Join Date: Oct 2002
Posts: 29
col lenth of 255??

I have 3 columns as varchar(255). All the three columns are completly filled. When I write the following concatinated select query, it gives only 255 char output.

select rtrim(col1)+rtrim(col2)+rtrim(col3) from tmp

Do you guys know why is that?. Is this sybase (SQL) restriction that length of each output column is max 255?

Thanks
Reply With Quote
  #2 (permalink)  
Old 03-10-03, 05:27
Bernd Dulfer Bernd Dulfer is offline
Registered User
 
Join Date: Sep 2002
Location: Germany, near Aachen
Posts: 120
You try to concatenate three strings of 255 chars length together.
The max stringlength is 255, so the new string will be truncated.

Either try: select rtrim(col1), rtrim(col2), rtrim(col3) from tmp
if possible or upgrade your ASE Version.
Reply With Quote
  #3 (permalink)  
Old 03-10-03, 15:27
nmr nmr is offline
Registered User
 
Join Date: Oct 2002
Posts: 29
Thanks for your reply.

I have ASE 12.0.0.5 Ver. Which version supports more than 255 chars?

Thx.
Reply With Quote
  #4 (permalink)  
Old 03-10-03, 16:52
richardcrossley richardcrossley is offline
Registered User
 
Join Date: Sep 2002
Location: Dublin, Ireland & Woking UK
Posts: 150
What version of open client are you running. Is it 12.0.0.5 as well?

I haven't used 12.0.0.5, but 12.5 allows "large" columns too.
Reply With Quote
  #5 (permalink)  
Old 03-10-03, 20:47
bmalar bmalar is offline
Registered User
 
Join Date: Feb 2003
Location: Brisbane, Australia
Posts: 110
You may also want to check whatever you are using to retrieve the data. In others words if you are using a tool such as WinSQL or SQL Advantage they may limit the information returned. If it is within some code check the length of the variable that retrieve's the data etc.

Just a thought.
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On