write a query following data.
123.45 is input.write a query after decimal (ex:.45) load
into database ?how it possible?
Answers were Sorted based on User's Feedback
Answer / yuvaevergreen
Assuming the column type to be decimal type and the same table to be updated, the string function can be used.
update dbname.tbname
set salary=
substr(cast (salary as char(10)),index(cast (salary as char(10)),'.'))
>>>salary is of type decimal..
| Is This Answer Correct ? | 7 Yes | 1 No |
Answer / ankal
assuming this value is sal colume i mean sal=123.45; u want to update it with after decimal value.i think The following query try.
update table_name set sal=sal-cast(sal as int));
| Is This Answer Correct ? | 4 Yes | 1 No |
Answer / tdguy
Above answers are correct, but data type should be taken
care of.
| Is This Answer Correct ? | 1 Yes | 0 No |
How do you verify a complicated sql?
i am pursuing mca and i want to do tera data .so plz suggest me the best institue in hydrabad who teach real tym scenerio.
what are the file sizes in your project?
Let us say there is a file that consists of 100 records out of which we need to skip the first and the last 20 records. What will the code snippet?
Difference between stored procedure and macro?
how teradata fetches a row from primary index table?
During the Display time, how is the sequence generated by Teradata?
What are the uses of client software involved in teradata?
What are the components provided on node?
Describe the between keyword in teradata?
What are the things to be considered while creating secondary index?
Explain fastload in teradata?