1. Get rid of all advertisements and get unlimited access to documents by upgrading to Premium Membership. Upgrade to Premium Now and also get a Premium Badge!

missing ri parenthesis?

Discussion in 'SQL PL/SQL' started by monkey, Jun 9, 2014.

  1. monkey

    monkey Long Term Member

    Messages:
    156
    Likes Received:
    0
    Trophy Points:
    230
    Code (SQL):
    CREATE TABLE p(
    id_p INT PRIMARY KEY,
    z INT,
    ddv INT,
    fz generate always AS (z*ddv)
    );
    Missing right parenthesis ora 00907???

    many thakns!!!
     
  2. krasnoslobodtsev_si

    krasnoslobodtsev_si Forum Genius

    Messages:
    626
    Likes Received:
    129
    Trophy Points:
    810
    Location:
    Russian Federation
    Hi.
    And where in the table description a field: znesek ?

    you were mistaken in a keyword : generate -> shall be generated
    Code (SQL):


    CREATE TABLE p(
    id_p INT PRIMARY KEY,
    z INT,
    ddv INT,
    fz generated always AS (z*ddv)
    );

     
     
    monkey likes this.
  3. rajenb

    rajenb Forum Expert

    Messages:
    361
    Likes Received:
    114
    Trophy Points:
    655
    Location:
    Mauritius
    You forgot to define the type for fz (I suppose it's a Number).
    And, I can't see the column "zsenek" in the definition of the table.
     
    monkey likes this.
  4. monkey

    monkey Long Term Member

    Messages:
    156
    Likes Received:
    0
    Trophy Points:
    230
    Hello!
    can I define fn as numberif it is ment to be a product of 2 integers?
    many thanks!!
     
  5. monkey

    monkey Long Term Member

    Messages:
    156
    Likes Received:
    0
    Trophy Points:
    230
    Owe U for that k*!!!:tup