Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: Maximum length sql statement
In article <NUqQ5.22$e67.452_at_news.get2net.dk>,
"cho" <cho_at_sondagsavisen.dk> wrote:
> weird stuff ..
>
> here's the create statement in question.
>
> CREATE TABLE INVOICE (INVOICE_NO NUMBER PRIMARY KEY, CUST_NO NUMBER
NOT
> NULL, CUST_AGENCY_NO NUMBER NOT NULL, INVOICE_T VARCHAR(2) NOT NULL,
SPLIT_I
> NUMBER NOT NULL, INVOICE_DT DATE , INVOICE_PAY_DT DATE, INVOICE_B_DUE
> NUMBER, INVOICE_VAT NUMBER, INVOICE_DISC NUMBER, INVOICE_INF NUMBER,
> INVOICE_SEC_DISC NUMBER,INVOICE_LOC_P NUMBER, INVOICE_NOL NUMBER,
> INVOICE_COUNT NUMBER);
>
> I find *really* weird what you're talking about, I've done some
further
> experementing with sql plus, and the thing is, everything after 2
lines, it
> ignores... if i try to backspace my way back from line3 to line2,
that wont
> happen either... 2 lines maximum, and if i havent ended the statement
by
> then, then tough luck. If i mess with the buffer width, the number of
lines
> will adjust accordinly to a fixed length of characters.
> My envoriment is 8.1.6 on windows2000pro
>
> I tried to enter the SQL Via
> SQL PLUS
> JDataExplorer
> SQL Programmer
>
> And they all give me the same error msg.
> The second i back up and put the line in the 295 char range, it
works...
>
> Thx for all your replies.
>
> Cy
>
> "cho" <cho_at_sondagsavisen.dk> skrev i en meddelelse
> news:7k7Q5.41$ct1.2337_at_news.get2net.dk...
> > i cant seem to get more than 295 chars at a time.. Oracle wont have
it,
and
> > willignore anything i put more, telling me i im missing right
parenthesis.
> >
> > I need to do a create longer than this, what to do ?
> >
> > thx.
> >
> >
>
>
Are you saying this create table statement is one single line? IMO this
is bad programming practice, and as per David Fitzjarrells post the
line limit is 2500 chars. Didn't count the statement, but chances you
are exceeding that limit are high.
So please try
this version
CREATE TABLE INVOICE
(INVOICE_NO NUMBER PRIMARY KEY
, CUST_NO NUMBER NOT NULL , CUST_AGENCY_NO NUMBER NOT NULL , INVOICE_T VARCHAR(2) NOT NULL , SPLIT_I NUMBER NOT NULL , INVOICE_DT DATE , INVOICE_PAY_DT DATE , INVOICE_B_DUE NUMBER , INVOICE_VAT NUMBER , INVOICE_DISC NUMBER , INVOICE_INF NUMBER , INVOICE_SEC_DISC NUMBER , INVOICE_LOC_P NUMBER , INVOICE_NOL NUMBER , INVOICE_COUNT NUMBER
Hth,
-- Sybrand Bakker, Oracle DBA All standard disclaimers apply ------------------------------------------------------------------------ Sent via Deja.com http://www.deja.com/ Before you buy.Received on Wed Nov 15 2000 - 03:57:36 CST