PL/SQL: ORA-00934: Group feature is not allowed here

Hello

I write a PL/SQL procedure. The structure is like:

SET SERVEROUTPUT ON;
CREATE or REPLACE procedure abc

IS
v_total_ip_rec number (14);
v_total_op_rec number (14);
v_total_rec number (14);


BEGIN
SELECT SUM (CASE
WHEN < condition 1 >
THEN 1
0 OTHERWISE
END
) in v_total_ip_rec.
SUM (CASE
WHEN < condition 2 >
THEN 1
0 OTHERWISE
END
) in v_total_op_rec.
SUM (1) in v_total_rec
OF A, B
WHERE A.Col1 = B.Col1;

EXCEPTION
WHILE OTHERS THEN
raise_application_error (-20001,' an error has occurred - ' |) SQLCODE |' - ERROR - ' | SQLERRM);
END;


When I run this procedure it gives me following error:
"PL/SQL: ORA-00934: Group feature is not allowed here."

Someone has an idea?

Any help would be appreciated.

Thank you.

Should I have any special role?

Have you checked if synonyms exist for tables?
Please check in this order:

#1-synonymes appropriate
#2-appropriate privileges
#3-appropriate roles

Tags: Database

Similar Questions

  • ORA-00934: Group feature is not allowed here

    CREATE or REPLACE PROCEDURE First(
    date1 IN Date,
    date2 IN Date
    )
            AS
    
    date3 employee.start_date%TYPE;
    date4 employee.start_date%TYPE;
    
    Begin
    select min(start_date) into date3 from employee where start_date between date1 AND date2;
    END;
    /
    Above procedure is completed successfully

    But when I changed the query to

    Select min (start_date) date3, max (start_date) in date4 of employee where start_date between date1 AND date2.
    then I get the error message
    ORA-00934: Group feature is not allowed here.
    Why this error happens during execution, but on sqlplus query is executed successfully.
    I checked this in oerr ora-00934 but not able to understand what measures should be taken
    select min(start_date)
    ,      max(start_date)
    into   date3
    ,      date4
    from   employee
    where  start_date between date1 AND date2;
    
  • Group feature is not allowed here

    Hello

    I have a problem running the following sql command, I know that the error is the count function, but I don't know how to solve this problem. Can you please help me solve this problem.
    (I like to select titles that have more than 2 authors).

    Separate select titles.title_id, titles.title_name, titles.publisher_ID
    authors, titles, and author_titles
    where titles.title_ID = author_titles.title_id
    and author_titles.au_id = authors.au_id and count (authors) > 2
    ORDER BY titles.title_id DESC;

    Thank Yoy

    Hello

    You group by expression is absent from the columns you have in your select statement

      SELECT titles.title_id,
             titles.title_name,
             titles.publisher_ID    FROM authors, titles, author_titles
       WHERE titles.title_ID = author_titles.title_id
             AND author_titles.au_id = authors.au_id
    GROUP BY titles.title_id, titles.title_name, titles.publisher_ID
      HAVING COUNT ( * ) > 2
    ORDER BY titles.title_id DESC;
    

    Concerning
    OrionNet

  • Group feature is not allowed

    Hi all...

    When I run the following text in the SQL command screen, it works fine... But when I try to use it in the APEX to fill the values on the page, it gives me error...

    ERROR
    1 error has occurred
    ORA-06550: line 25, column 74: PL/SQL: ORA-00934: Group feature is not allowed here ORA-06550: line 24, column 1: PL/SQL: statement ignored


    CODE THAT WORKS IN THE FORM OF SQL COMMAND

    SELECT
    SUM(CASE WHEN SLOT = 'Q' THEN '1' ELSE '0' END) AS C_SLOT,
    SUM(CASE WHEN TEST = 'P' THEN '1' ELSE '0' END) ACE C_TEST,
    OF TBL_REC;


    CODE THAT GIVES THE ERROR ON THE APPLICATION EXPRESS PAGE

    SELECT
    SUM (CASE WHEN SLOT = 'Q', THEN '1' OTHER '0' END) IN: P2_C_SLOT,.
    SUM (CASE WHEN TEST = 'P', THEN '1' OTHER '0' END) IN: P2_C_TEST,.
    OF TBL_REC;


    The GBA SLOT and TEST have the letter codes, I want just that it count only when it matches a certain letter. In the form of SQL command, it returns a single line, with the charges, all right. This is only a problem when I try to use anywere on a page in Application Express.

    The full version has about 20 lines that are all rows in the sum, but I can't even the worm 2 lines above to work.

    Any thoughts?

    VR;

    SELECT
    SUM (CASE WHEN SLOT = 'Q', THEN '1' OTHER '0' END)
    SUM (CASE WHEN TEST = 'P', THEN '1' OTHER '0' END) IN: P2_C_SLOT,: P2_C_TEST
    OF TBL_REC;

    Published by: seal of hash on June 3, 2009 12:56

  • Help with error - 934 group function is not allowed here

    Hey there will, I'm having problems with a request and just does not know how to do it without error.

    I'm trying to get all the employee emerging infectious diseases that have less than 2 number max of DID (dependants) in the table.

    It's my current query

    SELECT Employee.LName. ' ' || Employee.Fname as Full_Name, Employee.EID

    The left outer JOIN employee depends on Employee.EID = Dependent.EID

    Having Count (DID)--2 > ((select Max (N) as From (SELECT Employee.EID, Count (DID) As N FROM Employee Inner Join Dependent On Employee.EID = Dependent.EID group by Employee.EID, Count (DID))) N)

    Order of Employee.Lname, Employee.Fname

    Which gives me an error on column 4, no matter what I do. If I remove the Count (DID) in the group by clause (which I tried it earlier), it gives me a is not an error of the function of single group...

    The most frustrating thing is that

    Select Max (N) as From (SELECT Employee.EID, Count (DID) As N FROM Employee Inner Join Dependent On Employee.EID = Dependent.EID group by Employee.EID) N

    Works perfectly, but because it's a mission, I have to do in one step (no substeps/views)

    Any help?

    Thank you very much

    Hello

    ac981e5d-D10A-4520-BF42-23a894d04fb7 wrote:

    Ok. I'm taking your code in a view... I get this.

    and there is an orange underscore and a text of the error that says

    Select incoherent list in group by... change the group by clause of e.fname, e.lname, e.eid, count, max

    Which isn't what either the Oracle database would do.  Everything about orange (or any other color) sounds like it is caused by a front-end that could be interacting with Oracle.  In addition, the Oracle error messages always come with a 3-letter-5 code, as ORA-00933.

    under the selection internal (first medium)

    You have deleted the WITH clause.  The parser can recognize the error when it has reached the first left parenthesis.

    Create view AS A10T2

    (

    SELECT e.lname. ' ' || e.fname AS full_name

    e.eid

    (D.) AS this_group_count

    MAX (COUNT (d.)) ON (AS highest_group_count)

    E employee

    LEFT OUTER JOIN dependent d ON e.eid = d.eid

    GROUP BY e.lname, e.fname, e.eid

    )

    SELECT full_name

    eid

    Of aggregate_results

    WHERE this_group_count > = highest_group_count - 2

    ORDER BY full_name

    You need the WITH to define this clause means "AGGREGATE_RESULTS":

    Create view AS A10T2

    WITH aggregate_results AS

    (

    SELECT e.lname. ' ' || e.fname AS full_name

    ...

    Why do you have an ORDER BY clause in a view?   (It is probably not cause of your errors, just make the inefficient view)

    Command line error: column 5: 23

    Error report-

    SQL error: ORA-00933: SQL not correctly completed command

    00933 00000 - "not correctly completed SQL command.

    * Cause:

    * Action:

    This is another indication that some front is getting involved.  Looks like your front-end reports the exact Oracle error message, "0RA-00933" and then builing it's own error code, "00933. 00000 ", on this basis.  ORA-00933 is a reasonable mistake to wait if you omit the line ' WITH the aggregated results AS.  Once again, until I can actually run your code, I can't test it, and I can't run your code until you post CREATE TABLE and INSERT statements for some examples of data, or change the problem to use commonly available tables, such as those in the scott schema.

    and when I try my code

    CREATE VIEW A10T2 AS

    SELECT Employee.LName. ' ' || Employee.Fname as Full_Name, Employee.EID

    The left outer JOIN employee depends on Employee.EID = Dependent.EID

    Seen (Count (DID)) + 2 > (select Max (N) From (SELECT Employee.EID, Count (DID) As "N" FROM Employee Inner Join Dependent On Employee.EID = Dependent.EID group by Employee.EID))

    Order of Employee.Lname, Employee.Fname

    I get

    Command line error: column 2: 8

    Error report-

    SQL error: ORA-00937: not a function of simple-group

    00937 00000 - 'not a single-group function.

    * Cause:

    * Action:

    Then the orange underscore even under my inner ("select employee. EID, Count (DID) as "N" ") says to change the Group of Employee.eid, Count (DID)

    I just don't understand why he tells me to group them by Count (DID)?

    Isn't that what you did in your original post, and I have explained in answer #2?  If you continue to repeat the same mistake, you can expect continue to get the same error.  Given that you have a code, you know causes an error, do you think really that what makes a vision will cause the error to disappear?

    The inner query works fine on its own...

    Right; It's the outer query where you are missing the GROUP BY clause.

  • Database trigger - PL/SQL: ORA-00984: column not allowed here

    I am trying to create a trigger that will update a table of audit used when a row is changed. Using a sequence number to assign an identifier unique to each line as it is created. Need to capture the user ID, date modified and action (update), the image of the front line.
    CREATE SEQUENCE emp_audit_seq START WITH 10;                
    Create table emp (
       empno       NUMBER(4)      Primary Key,
       ename       VARCHAR2(10),
       job            VARCHAR2(9),
       mgr           NUMBER(4),
       hiredate     DATE,
       sal             NUMBER(7,2),
       comm        NUMBER(7,2),
       deptno       NUMBER(2));
    CREATE TABLE emp_audit   (
         audit_uid          NUMBER(15)      Primary Key,
         change_date          DATE,
         change_user          VARCHAR2(30),
         action                  CHAR(1),
         empno                  NUMBER(4),
         ename                  VARCHAR2(10),          
         job               VARCHAR2(9),
         mgr               NUMBER(4),
         hiredate          DATE,
         sal               NUMBER(7,2),
         comm                  NUMBER(7,2),
         deptno                  NUMBER(2));
    CREATE OR REPLACE TRIGGER trig_emp_audit
      BEFORE UPDATE ON emp
      FOR EACH ROW
    BEGIN
      INSERT INTO emp_audit
        VALUES(emp_audit_seq.nextval, change_date, change_user, action, :old.empno, :old.ename, :old.job, :old.mgr, :old.hiredate, :old.sal, :old.comm, deptno);
    END;
    /
    
    Warning: Trigger created with compilation errors.
    
    SQL> show errors
    Errors for TRIGGER TRIG_EMP_AUDIT:
    
    LINE/COL ERROR
    -------- -----------------------------------------------
    2/3      PL/SQL: SQL Statement ignored
    3/149    PL/SQL: ORA-00984: column not allowed here
    Can someone help to help me find what I'm doing wrong with the trigger?

    Published by: LostNoob on August 25, 2012 14:24

    First of all, when you write an INSERT statement, it is always good for the columns that you insert in the list. Which makes the code easier to follow - you do not have separately pull toward the top of the table definition to know what order of columns is inserted. And it makes the code easier to manage because the declaration become invalid if you add a new column to the table in the future.

    Second, CHANGE_DATE, CHANGE_USER and ACTION are not (probably) functions and are not local variables so it is not supposed to use them in an INSERT statement. You need to write code or to take advantage of the existing functions to fill in these columns. I suppose, for example, that you want to use SYSDATE to fill the CHANGE_DATE and the USER to fill the column CHANGE_USER. My guess is that ACTION must always be a 'U' for UPDATE.

    Thirdly, it seems that you left the: old man on the DEPTNO column.

    Put them all together, you would have something like

    CREATE OR REPLACE TRIGGER trig_emp_audit
      BEFORE UPDATE ON emp
      FOR EACH ROW
    BEGIN
      INSERT INTO emp_audit(
          audit_uid,
          change_date,
          change_user,
          action,
          enpno,
          ename,
          job,
          mgr,
          hiredate,
          sal,
          comm,
          deptno )
        VALUES(
          emp_audit_seq.nextval,
          sysdate,
          user,
          'U',
         :old.empno,
         :old.ename,
         :old.job,
         :old.mgr,
         :old.hiredate,
         :old.sal,
         :old.comm,
         :old.deptno);
    END;
    / 
    

    Justin

  • PL/SQL: ORA-00984: column not allowed here

    Sorry, it's probably easy and I forgot something simple, but it's driving me crazy :-)
    VARIABLE g_fk_deduction      VARCHAR2(30)
    VARIABLE g_fk_empno          NUMBER
    VARIABLE g_before_or_after_flag     CHAR(1)
    VARIABLE g_deduction_amount     NUMBER
    
    BEGIN
      :g_fk_deduction           := '401K';
      :g_fk_empno               := 7369;
      :g_before_or_after_flag     := 'B';
      :g_deduction_amount          := 150.00;
    END;
    /
    BEGIN
      INSERT INTO emp_deductions      (fk_deduction, fk_empno, before_or_after_flag, deduction_amount)
       VALUES               (g_fk_deduction, g_fk_empno, g_before_or_after_flag, g_deduction_amount);
      COMMIT;
    END;
    /
    Error: PL/SQL: ORA-00984: column not allowed here on g_deduction_amount
    in the value clause.
    Any help would be appreciated.

    Table is below:
    CREATE TABLE emp_deductions     (
          fk_deduction            VARCHAR2(30),
          fk_empno                  NUMBER(4),
          before_or_after_flag         CHAR(1),
          deduction_amount            NUMBER(6,2));
    Published by: LostNoob on August 23, 2012 19:06

    rp0428 wrote:
    >
    : g_fk_deduction: = "401k".
    : g_fk_empno: = 7369;
    : g_before_or_after_flag: = 'B ';.
    : g_deduction_amount: = 150.00;
    >
    Why did you put a colon here? Get rid of them.

    They are necessary, since they are declared SQL * more variable.

    The problem for the OP, is that in the clause values in the insert the colon are missing.

    Published by: Mark Williams on August 23, 2012 22:31

    Here is your example requested:

    SQL> create table test (c number);
    
    Table created.
    
    SQL> variable v_c number
    SQL> begin
      2    :v_c := 46;
      3  end;
      4  /
    
    PL/SQL procedure successfully completed.
    
    SQL> begin
      2    insert into test values (:v_c);
      3  end;
      4  /
    
    PL/SQL procedure successfully completed.
    
    SQL> commit;
    
    Commit complete.
    
    SQL> select * from test;
    
             C
    ----------
            46
    
    1 row selected.
    
    SQL>
    
  • ORA-01733-virtual column not allowed here - insert using inline view

    Does anyone know why I get ORA-01733-virtual column not allowed here

    SQL > select * from v version $;

    BANNER
    --------------------------------------------------------------------------------
    Oracle Database 11g Enterprise Edition Release 11.1.0.6.0 - Production
    PL/SQL release 11.1.0.6.0 - Production
    CORE 11.1.0.6.0 Production
    AMT for 32-bit Windows: Version 11.1.0.6.0 - Production
    NLSRTL Version 11.1.0.6.0 - Production



    -no error without the WITH CHECK option

    SQL > INSERT INTO
    2 (SELECT
    3 location_id,
    4 city
    5 l.country_id
    6 OF country c, localities, regions r l
    7 where l.country_id = c.country_id
    8 and c.region_id = r.region_id
    9 and r.region_name = 'Asia')
    10 VALUES (5500, 'Common Wansdworth', 'UK');

    1 line of creation.

    SQL > rollback;

    Complete restoration.


    -error with WITH CHECK OPTION


    SQL > INSERT INTO
    2 (SELECT
    3 location_id,
    4 city
    5 l.country_id
    6 OF country c, localities, regions r l
    7 where l.country_id = c.country_id
    8 and c.region_id = r.region_id
    9 and r.region_name = 'Asia' WITH CHECK OPTION)
    10 VALUES (5500, 'Common Wansdworth', 'UK');
    INSERT INTO
    *
    ERROR on line 1:
    ORA-01733: virtual column not allowed here




    I was expecting

    ORA-01402: discovers the violation of where WITH CHECK OPTION clause

    for the second. Am I missing here?

    Coskan wrote:
    Randolf

    Thanks a lot for the update of this old question
    After reading the link, I think I should ignore this error and accept him as ORA-01402

    The information that you have asked me to check me do not have an understanding of the different error types.

    Coskan,

    I didn't know this is an old thread that somehow got updated by someone else.

    Regarding your question: you're right that the output of the script is not really that useful.

    I have just run on 10.2.0.4 and in general, it seems that the output of USER_UPDATABLE_COLUMNS is incorrect regarding the views of join using the WITH CHECK OPTION.

    For example although the location_id from the TEST_V_2 column appears as non-editable (probably because of the rule that "the columns used in the join expression" cannot be modified in a join view when you use the WITH CHECK OPTION) I can run successfully your insert if statement I choose a location_id less than 2000.

    It seems that summed up the difference if you join more than two tables, you'll always get the error "ORA-01733" when you try to insert in the join with the enabled OPTION CHECK view. For example to add a third table TEST_V_2 which does not change the original view, but simply joined meaning for example COUNTRIES to LOCATIONS, will show the same behavior to throw an ORA-01733, however it works fine when the omission of the WITH CHECK OPTION.

    So overall, I tend to say it is really a limitation of the implementation and it is not actually an ORA-01402 but looks like Oracle is simply trying to tell you: Amendment No. INSERT in this possible view. Updates however seem to work, at least I can find some examples of work.

    There seems to be other restrictions of implementation with the WITH CHECK OPTION in place even when the only membership as two tables, for example when trying to join the COUNTRIES and PLACES but by selecting only in PLACES and by using a filter on the COUNTRY_ID predicate fails with ORA-01733 when this predicate is applied to the COUNTRY. COUNTRY_ID but it works if this predicate is applied to PLACES. COUNTRY_ID.

    I could imagine that Oracle has quietly added some of these restrictions with each patch set due to the angle of the case/adverse reactions encountered. I saw this for other features, too.

    Kind regards
    Randolf

    Oracle related blog stuff:
    http://Oracle-Randolf.blogspot.com/

    SQLTools ++ for Oracle (Open source Oracle GUI for Windows):
    http://www.sqltools-plusplus.org:7676 /.
    http://sourceforge.NET/projects/SQLT-pp/

  • ORA-01719: outer join operator (+) not allowed in operand of GOLD or IN

    I'm migrating a stored procedure (package) in Oracle 11 g.  The SQL has an outer join, combined with a "GOLD":

    Select a.row1, a.row2, b.row3, b.row4, c.row5, c.row6

    schema1.table1 a, schema1.table2 b, schema2.table3 c

    where

    ((c.orgunit = a.org (+) and b.newaccount (+) and TO_CHAR(c.createdatetime,'MM/DD/YYYY = c.account and c.feed = 'FOO' ') = TO_CHAR (SYSDATE, ' DD/MM/YYYY'))

    or

    ((c.feed = 'BAR' and c.orgunit = a.org (+) and c.account b.newaccount (+) and TO_CHAR(c.createdatetime,'MM/DD/YYYY =') = TO_CHAR (SYSDATE, ' DD/MM/YYYY'));

    The error is:

    ORA-01719: outer join operator not allowed in operand of GOLD or IN

    * Cause: Outer join appears in a clause or.

    * Action: If A and B are predicates, to achieve the effect of (has or B).

    I do not understand how to apply the suggested action to my query above.  Can anyone provide a solution or a workaround?

    Thank you.

    your base table is c, a and b must be attached to the left

    Select a.row1, a.row2, b.row3, b.row4, c.row5, c.row6

    of schema2.table3 c

    Join schema1.table1 left a c.orgunit on = a.org

    c.account left join schema1.table2 b = b.newaccount

    where c.createdatetime > = trunc (sysdate)

    and c.createdatetime<>

    and (c.feed = 'FOO' or c.feed = 'BAR');

  • ORA-02287: sequence number not allowed here

    < police = "Courier New" >
    Hello
    Why do I have this problem?
    Insert an order tab2 select tab2_seq.nextval, eng_cat from (select distinct job_det eng_cat) by 2.

    SQL > r
    1 * insert into tab2_seq.nextval select eng_cat select (separate eng_cat tab2
    Insert in tab2 select tab2_seq.nextval, eng_cat from (select distinct eng_cat from)
    *
    ERROR on line 1:
    ORA-02287: sequence number not allowed here

    Thank you and best regards,
    Human
    < / make >

    It's 'order of 2' which makes it fail. That makes no sense at all?
    Just remove the order by clause, then it works ;-)

  • ORA-00984: column not allowed here, when you try to use a default UDF

    I am wanting to create a table that has a default value of a user-defined function, and because this default is intended to be used in a few different places so I would use a function rather than in the table definition.

    This is my current code that works very well:
    CREATE TABLE DEPT_HIST
    (
      DEPTNO      NUMBER(2) not null,
      DNAME       VARCHAR2(14),
      LOC         VARCHAR2(13),
      SQL_ACTV_C  CHAR(1) not null,
      EFFT_STRT_S TIMESTAMP(6) default SYSTIMESTAMP not null,
      EFFT_END_S  TIMESTAMP(6) default TO_TIMESTAMP('9999/12/30 00:00:00.000000', 'YYYY/MM/DD:HH24:MI:SS.FF6') not null,
      DELT_F      CHAR(1) default 'N' not null
    );
    but I would get something similar to this work:
    CREATE OR REPLACE FUNCTION EOT
       RETURN timestamp
    IS
       Result   timestamp;
    BEGIN
       RETURN (TO_TIMESTAMP ('9999/12/30 00:00:00.000000',
                             'YYYY/MM/DD:HH24:MI:SS.FF6'));
    END EOT;
    /
    
    select eot from dual;
    
    EOT
    ---------------------------------------------------------------------------
    30/DEC/99 12:00:00.000000000 AM
    
    CREATE TABLE DEPT_HIST
    (
      DEPTNO      NUMBER(2) not null,
      DNAME       VARCHAR2(14),
      LOC         VARCHAR2(13),
      SQL_ACTV_C  CHAR(1) not null,
      EFFT_STRT_S TIMESTAMP(6) default SYSTIMESTAMP not null,
      EFFT_END_S  TIMESTAMP(6) default EOT not null,
      DELT_F      CHAR(1) default 'N' not null
    );
    but I get an error of:
      EFFT_END_S  TIMESTAMP(6) default EOT not null,
                                       *
    ERROR at line 8:
    ORA-00984: column not allowed here
    Any ideas? I guess I could use a trigger but not exactly what I'm after.

    Hello

    Sorry; No function defined by the user in the DEFAULT clause.
    From SQL, under "CREATE TABLE Statement" language manual
    http://download.Oracle.com/docs/CD/B28359_01/server.111/b28286/statements_7002.htm#sthref7119

    Restriction on default column values


    A DEFAULT expression cannot contain references to the functions PL/SQL or other columns, the nickname CURRVAL, NEXTVAL, LEVEL, PRIOR and ROWNUM, or date constants that are not completely specified.

    I wouldn't use a trip just for that. If you need a trigger for other reasons, then maybe you can include the definition of this column in the trigger, too, but, in general, avoid triggers when there is an alternative.

  • ORA-00976 LEVEL, PRIOR or ROWNUM not allowed here in the PO_DOCUMENT_CH package

    Hello

    EBS R12.1
    OEL 5.4

    Operations of requisition and PO doing im but I got error
    ORA-00976 LEVEL,PRIOR, or ROWNUM not allowed here in Package PO_DOCUMENT_CHECKS_PVT Procedure CHECK_REQUISITIONS.
    
    Solution
    
    1. Please check HR Locations setup corresponding to location_id=XXX. For example the Country should be 'KE' instead of 'Kenya'. 
    Compare with that of location_id=YYY which is correct as per FND log. 
    
    select location_id,location_code,country 
    from hr_locations_all 
    where location_id in (142,182); 
    
    2. After changing above setup, please run the SQL again to confirm the value. 
    Note > ORA-00976 error while approving internal requisitions [968651.1 ID]
    is the same thing with my mistake. But it is specific to the country in KENYA. :(
    How can I get my FND journal so that I can see what location_id who got the error?
      1* select location_id,location_code,country from hr_locations_all
    SQL> /
    
    LOCATION_ID LOCATION_CODE COUNTRY
    ----------- ------------- --------
    censored
    
    Im selecting the table but it seems the location and country code are fine.
    
    Please help me resolve this one based on the notes above.
    
    Thanks a lot,
    
    Ms K
    
    Edited by: user_unlimited on Sep 16, 2010 10:28 PM                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        

    Salvation;

    Please update thread when you did at the end of reading

    Respect of
    HELIOS

  • Procedure returns ORA-00984: column not allowed here

    Get an error returned by my procedure and can't understand it. Someone has an idea?
    Thanks in advance,
    Carpet

    14/2 PL/SQL: statement ignored
    15/80 PL/SQL: ORA-00984: column not allowed here



    CREATE OR REPLACE PROCEDURE basket_add_sp
    (p_idproduct in NUMBER,
    p_price in NUMBERS
    p_quantity in NUMBERS
    p_idbasket in NUMBERS
    p_option1 in NUMBERS
    p_option in NUMBERS)
    IS
    lv_seq_num bb_basketitem.idbasketitem%TYPE;
    BEGIN
    SELECT bb_idbasketitem_seq. NEXTVAL
    IN lv_seq_num
    FROM DUAL;
    INSERT INTO bb_basketitem (idbasketitem, idproduct, price, quantity, idbasket, option 1, option 2)
    VALUES (lv_seq_num, p_idproduct, p_price, p_quantity, p_idbasket, p_option1, p_option2);
    COMMIT;
    END;
    /

    What is p_option2 in the INSERT statement? In the settings, you have only p_option1 and p_option.

    I agree with Walter, you can save an e/s by losing the select double.

  • ORA-02021: DDL Operations are not allowed on a remote database

    Hello

    I need to SELECT grants to a role on a synonym, but I got this error:

    SQL > GRANT SELECT ON SYNERGIA. CoDato_SED to ROLE_SYNERGIA;
    GRANT SELECT ON SYNERGIA. CoDato_SED to ROLE_SYNERGIA
    *
    ERROR on line 1:
    ORA-02021: DDL Operations are not allowed on a remote database


    SYNERGIA. CoDato_SED is a synonym of a remote database create with this script:

    CREATE A SYNONYM SYNERGIA. CoDato_SED for GST. CoDato_SED@BDEEDN. DSYN;

    Please how do I deal with these cases.

    Thank you.
    ----------------------------------------------------
    Version of database: Oracle 9i 9.2.0.8.0
    SO: HP - UX 11.23

    Read the docs.

    You grant privileges on objects that are not synonymous.

  • ORA-00976: virtual specified or operator not allowed here

    Hello

    We had error after upgrade of GR 11, 2, in the insert statement.

    INSERT INTO SDE_TBL_FLEXTRIMSITROUT

    (BRANCHCD,

    SOURCECD,

    CURRENTNO,

    BATCHNO,

    DEPTCD,

    CTL

    INITIATIONDATE,

    AMOUNT,

    ACCOUNT,

    ACCOUNTBRANCH,

    TXNCD,

    DEBITCREDIT,

    LCYEQUIVALENT,

    EXCHRATE,

    VALUEDATE,

    INSTRUMENTNO,

    RELCUST,

    ADDLTEXT,

    TXNMIS1,

    TXNMIS2,

    TXNMIS3,

    TXNMIS4,

    TXNMIS5,

    TXNMIS6,

    TXNMIS7,

    TXNMIS8,

    TXNMIS9,

    TXNMIS10,

    COMPMIS1,

    COMPMIS2,

    COMPMIS3,

    COMPMIS4,

    COMPMIS5,

    COMPMIS6,

    COMPMIS7,

    COMPMIS8,

    COMPMIS9,

    COMPMIS10,

    COSTCODE1,

    COSTCODE2,

    COSTCODE3,

    COSTCODE4,

    COSTCODE5,

    RELATEDACCOUNT,

    RELATEDREF,

    USERREFERENCE,

    ACCTPOSTOVERWRITE,

    EXCHRATEOVERWRITE,

    VALUEDATEOVERWRITE,

    ACCTBALOVERWRITE,

    ITRREFER,

    RefinanceAmount,

    PROCESSID)

    VALUES

    (vBranchCode,

    cCreateNewTrimsITR_rec. APPLSYS,

    ROWNUM,

    nBatchNo,

    cCreateNewTrimsITR_rec. DEPT,

    vCcy,

    To_date (cCreateNewTrimsITR_rec. HOUR, 'YYYYMMDD'),

    nAmount,

    vAccount,

    vAccountBranch, - added by Sibylle

    vTxnCd,

    cDebitCredit,

    nLcyEquivalent,

    nExchRate,

    To_date (cCreateNewTrimsITR_rec. VALUEDATE, 'YYYYMMDD'),

    vInstrumentNo,

    --'      ' || SUBSTR (cCreateNewTrimsITR_rec. ITRREFER, 2, 11),

    vFlxCntry | cCreateNewTrimsITR_rec. APNO,

    vDesc,

    cCreateNewTrimsITR_rec. TRANSOUC,

    RPAD (' ', 9);

    vExpenseMIS,

    vProductMIS,

    RPAD (' ', 9);

    RPAD (' ', 9);

    RPAD (' ', 9);

    RPAD (' ', 9);

    RPAD (' ', 9);

    RPAD (' ', 9);

    RPAD (' ', 9);

    RPAD (' ', 9);

    RPAD (' ', 9);

    RPAD (' ', 9);

    RPAD (' ', 9);

    RPAD (' ', 9);

    RPAD (' ', 9);

    RPAD (' ', 9);

    RPAD (' ', 9);

    RPAD (' ', 9);

    RPAD (' ', 9);

    RPAD (' ', 9);

    RPAD (' ', 9);

    RPAD (' ', 9);

    RPAD (' ', 9);

    RPAD (' ', 20);

    cCreateNewTrimsITR_rec. THEIRREF,

    RPAD (' ', 16).

    cActPostOverwrite,

    cExchRateOverWrite,

    cValueDateOverWrite,

    cAcctBalOverWrite,

    cCreateNewTrimsITR_rec. ITRREFER,

    cCreateNewTrimsITR_rec. REFIAMOUNT,

    nFlexOutProcessId);

    Error: ORA-00976: specified virtual or operator not allowed here

    According to the audit, which are a problem in GR 11, 2 with insert query using rownum in values.

    Someone knows how to fix this?

    I wonder why you want to use rownum as a value of insertion? It's not really worth doing an insert without a select statement.

    If you want to use it, it would look like

    Insert into t1 (name, row_num_value)

    Select name

    rownum

    the t2;

    But then you can use an order by clause, on the other it would spoil the rownum order. So an important question is, where is the rownum used for?

Maybe you are looking for

  • Watch BONES 3: emoticons of scrolling is VERY slow unusable ad

    After having upgraded my Apple Watch (sport, 42mm) to Watch OS 3.0 since the last stable version (no public beta installed before) this terrible bug began to appear: when I get a notification of Whatsapp or iMessage and I would like to answer using t

  • Wireless LAN card Intel 2200 does not connect

    Hello I just bought an Intel Pro/series 2200 b/g. I installed the driver, and it detects the wireless network, but does not connect. I used the Intel and Toshiba drivers, but to no avail. My old card, the 2100 works fine. Can anyone help? Best regard

  • Clear out when it does not

    I'm under LabView 8.6 with modules USB-6525. Is there a way to 'Clear' automatically or set the outputs false when the VI is stopped? I know that I could do set them to false after the Stop button on my time loop is in a hurry, but it would be nice t

  • Function __Chkdsk does not run at startup

    I have installation chkdsk to run on drive C at the start, as I have had several opinions that some files may be corrupted. However, when I restart the chkdsk utility is not initiate and Windows starts normally. Is there a workaround on this? Thank y

  • Windows vista sp2 windows explore Crash!

    Vista sp2 - major repeated crashing windows explore - Help! Signature of the problem:Problem event name: APPCRASHApplication name: explorer.exeApplication version: 6.0.6002.18005Application timestamp: 49e01da5Fault Module name: compstui32.dllFault Mo