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

Home -> Community -> Usenet -> c.d.o.misc -> Re: syntax error

Re: syntax error

From: DA Morgan <damorgan_at_psoug.org>
Date: Fri, 23 Jun 2006 09:45:39 -0700
Message-ID: <1151081139.626766@bubbleator.drizzle.com>


Akhilesh wrote:

> Remove "-" between "COUNT(*) - COUNT"
> 
> 
> Akhilesh
> 
> 
> 
> Karsten Schenk wrote:

>> I 'm a beginner and I have following question:
>> Something seems to be wrong with the syntax of these lines.
>> It must be something tiny.
>> Can anyone help me?
>>
>> EXECUTE IMMEDIATE 'SELECT COUNT(*) - COUNT ('|| c || ') AS nulls,
>> COUNT(DISTINCT ' || c || ') AS different , COUNT ('||c||') AS total'
>> FROM ' || t INTO nulls, different, total;
>> EXECUTE IMMEDIATE 'INSERT INTO ' || dest || ' (id, nulls, different,
>> total) VALUES ( :1, :2, :3, :4)' USING (id, nulls, different, total);
>>
>> Thanks in advance
>>
>> Karsten
  1. Do Not Top Post.
  2. He is trying to perform a subtraction. The minus sign is appropriate.

The issues are many but that isn't one of them. Laurenz: Follow my advice and look at the output. The error will be obvious.

-- 
Daniel A. Morgan
University of Washington
damorgan_at_x.washington.edu
(replace x with u to respond)
Puget Sound Oracle Users Group
www.psoug.org
Received on Fri Jun 23 2006 - 11:45:39 CDT

Original text of this message

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