This content has been marked as final. Show 2 replies
921784 wrote:Sorry, it's unclear what you want.
Can any one help me to select varchar2 without approximation .
VARCHAR2s are never approximated. When you say VARCHAR2, do you mean NUMBER?
Date+When SQL*Plus doesn't have room to display a large number, such as 208099876543210, exacly, then it uses scientific notation, as shown above. The number stored in the table is not rounded or approximated.
*16/04/2012 ;208; 10; *2.0810E14**+ this one should not be approximatif
By default, SQL*Plus allows 10 characters for displaying NUMBERs. You can change that for an individual column by using the SQL*Plus COLUMN ... FORMAT command, like this:
To change the default amount of space for all NUMBER columns, you can use the SQL*Plus SET NUMWIDTH command:
COLUMN col_4 FORMAT 999999999999999
Also, instead of displaying a NUMBER, you can use TO_CHAR to explicitly convert it to a VARCHAR2, in whatever format you want:
SET NUMWIDTH 15
SELECT ... , TO_CHAR ( col_4 , '999999999999999' ) AS f_col_4 ...
I hope this answers your question.
If not, post a little sample data (CREATE TABLE and INSERT statements, relevant columns only) for all tables involved, and also post the results you want from that data.
Explain, using specific examples, how you get those results from that data.
Always say which version of Oracle you're using.