Hi Friends
I have a sql question, We have the source data as below.
101 address1, address2, address3
and the output shoulb like below
101 address1
101 address2
101 address3
Required a SQL query for this output.
Please let me know if you have any sql query for this.
Thanks in advance.
Hari M
Answer Posted / ronak
You have to use LPAD function,
Select lpad(address,20,'101')
from tableName;
NOTE: address is column name of address info, 20 is total
characters you want to display including 101 (since in this
case we don't know the characters of address),
Thank you
Ronak
Is This Answer Correct ? | 3 Yes | 0 No |
Post New Answer View All Answers
Explain some differences between mpp and smp?
What are the different table types supported by teradata?
Explain and compare pros and cons of snow flake schemas?
In Teradata, how do we Generate Sequence?
What happens when a node suffers a downfall?
What is a node in teradata? Explain
What does sleep function does in fast load?
Highlight the differences between Primary Key and Primary Index.
what is sysdba and sysdbc ? which has high priority ?
What is the maximum number of dml can be coded in a multiload script?
Explain the most common data types used in teradata?
What do you mean by teradata intelliflex?
What are the string manipulation operators and functions associated with teradata?
Explain the term 'columns' related to relational database management system?
How to find duplicates in a table?