Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Dazed and confused

Dazed and confused

From: mar <mar_at_notexist.com>
Date: Mon, 13 Oct 2003 11:14:43 +0200
Message-ID: <bmdqg0$l3ne0$1@ID-174077.news.uni-berlin.de>

8i Ent

DESC "MYTABLE":



XCODE, NOT NULL, CHAR(15)
XFLAG, NOT NULL, NUMBER(1)

SQL> SELECT COUNT(*) FROM MYTABLE WHERE XCODE=1234567890123 AND XFLAG=1;   COUNT(*)


         4

SQL> SELECT COUNT(*) FROM MYTABLE WHERE XCODE=1234567890123 AND XFLAG=0; SELECT COUNT(*) FROM MYTABLE WHERE XCODE=1234567890123 AND XFLAG=0;

                                   *

ERROR at line 1:
ORA-01722 invalid number

(Orcl says XCODE receives an invalid number)

Questions:

  1. why I am allowed to use XCODE=1234567890123 in the WHERE clase at all, since XCODE is a CHAR(15)
  2. why do I get the error above when using XFLAG=0, but not with XFLAG=1

Thanks Received on Mon Oct 13 2003 - 04:14:43 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US