-
problem in select query
Hi,
When i selected this table i got the following output...
SQL> select ch_crim_function_id from gc_criteria_m WHERE ch_crim_function_id='TFID';
CH_CRIM_
--------
TFID
TFID
TFID
TFID
SQL> select ch_crim_function_id from gc_criteria_m WHERE ch_crim_function_id='TFID ';
CH_CRIM_
--------
TFID
TFID
TFID
TFID
SQL> select ch_crim_function_id from gc_criteria_m WHERE ch_crim_function_id='TFID ';
CH_CRIM_
--------
TFID
TFID
TFID
TFID
SQL> DESC gc_criteria_m
Name Null? Type
----------------------------------------- -------- ----------------------------
CH_CRIM_COUNTRY_CODE NOT NULL CHAR(2)
CH_CRIM_FUNCTION_ID NOT NULL CHAR(8)
Thnaks,
-
Amar
"There is a difference between knowing the path and walking the path."
-
sorry!When i pasted the query with space, the spaces are not getting displayed in the forum.
both the queries give the same output?
WHERE ch_crim_function_id='TFID';
CH_CRIM_
--------
TFID
TFID
TFID
TFID
WHERE ch_crim_function_id='TFID-------------';/
CH_CRIM_
--------
TFID
TFID
TFID
TFID
(to represent blank space after TFID i hav given --------)
the value in the where class with space 'TFID--------' gives the same value as 'TFID'
Last edited by castlerock; 06-27-2003 at 03:00 AM.
-
I still dont see any problem here.
funky...
"I Dont Want To Follow A Path, I would Rather Go Where There Is No Path And Leave A Trail."
"Ego is the worst thing many have, try to overcome it & you will be the best, if not good, person on this earth"
-
It is because the datatype of the ch_crim_function_id column is CHAR(8).
For every row, the column is filled with space to reach the 8 caracters size.
So, it is impossible that the column contains 'TFID' exactly.
A implicit conversion was made ...
Hope this help.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|