I need an oracle query for convert Char to Integer?. Can any
one help me how to do this?
Answers were Sorted based on User's Feedback
Answer / moorthy g
Hi Jey,
Please see the below procedures (integer to varchar or char).
SQL> CREATE TABLE DEPT1 AS SELECT *FROM DEPT
SQL> Truncate table dept1;
SQL> alter table dept1 modify(deptno varchar2(20));
SQL>insert into dept1 select *from dept;
SQL> SELECT *FROM DEPT1
Note:
1. If you want to modify in information please the load type
truncate load or not. (May it will be truncate load only)
Best Regards,
Moorthy. G
| Is This Answer Correct ? | 1 Yes | 1 No |
Answer / ankit kansal
First of all Oracle supports implicit conversion between char to number if the specified text is of number type only.
*********************************************
Lets say sql>select '111'+1 as ans from dual;
ans
---
112
*********************************************
Here, 112 is the output you received it does not matter '112' as string.
But For precautions you can write your query as
***********************************************
sql>select to_number(trim('111'))+1 from dual;
***********************************************
| Is This Answer Correct ? | 0 Yes | 0 No |
Can you generate sequence numbers without using the sequence generator transformation?
How union transformation is used?
What is transformation?
how to convert 101 raja 101 raja sekar reddy 101 sekar----------> 101 reddy
If you have 10 mappings designed and you need to implement some chages (may be in existing mapping or new mapping need to be designed) then how much time it takes from easier to complex?
what is row level and column level indicator?
how can we find the bottle neck in SQL Query in SOURCE QUALIFIER, and how can we tune it..?
Explain about HLD and LLD ?
i have different sources in different databases ,that sources may be 100 tables i want to load these tables in to single target how to pearform the task
What are the types of lookup transformation?
tell me 7.x and 8.x diferrencess(but not transformations)
i have flat file it contains 'n' number of records, i need to send half of the records to one target table and Remaining half to another target table. can any tell me procedure.