String function

Database
The Teradata Database channel includes discussions around advanced Teradata features such as high-performance parallel database technology, the optimizer, mixed workload management solutions, and other related technologies.
Highlighted
Teradata Employee

String function

How can i use substr function with byte not character .
sel substrb(col2||col1 from 1 for 12) from TEST;

Is there any way to do above? Like substrb oracle function?

1 REPLY
Senior Apprentice

Re: String function

Hi,

Use the substring function, it works on both char and byte (as does substr)

 

try: substring(col2||col1 from 1 for 12) 

 

Cheers,

Dave

Ward Analytics Ltd - information in motion
www: http://www.ward-analytics.com