Size Limit on Varchar / Concatenating

Tools

Size Limit on Varchar / Concatenating

I am needing to know if there is a size limit on either varchar fields or concatenated fields in Teradata. Thanks for your help!

Brad
3 REPLIES
Junior Contributor

Re: Size Limit on Varchar / Concatenating

Check the SQL manual, Data Types and Literals:
Maximum size of a char/varchar is 64000

Dieter
Enthusiast

Re: Size Limit on Varchar / Concatenating

When you try to concatenate all columns of a table using || and trmming all whitespaces from all CHAR/VARCHAR fields, I noticed that anything over VARCHAR(31825) when concatenated with other columns, seems to complain of exceeding Max size.

I am not sure if the Max size is set for complete concatenated string or just for large VARCHAR field. I suspect it is set at 32000 for concatenated string.

Enthusiast

Re: Size Limit on Varchar / Concatenating

On an ASCII character set, the Maximum size of a varchar could be 64K because of the maximum row size.

Your character set seems to be UNICODE where each character takes 2 bytes for storage...