I have a TEXT column in the table which has multiple commas & spaces and I am trying to replace them to single coma & whitespace using str_replace.

however the problem is , when I tried to store the result into a @str varchar(2000) varaible, long string being truncated after 255 bytes.

So, can anyone help with either :

1. storing a long string into a varible without truncating after 255 bytes.


2. replacing the multiple commas & spaces and write the string back into same text column using 'writetext'.

btw, i am using sybase 12.5.

thanks for your help !