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 -> PLS-00049:bad bind variable

PLS-00049:bad bind variable

From: trub3101 <michael_at_bassline01.wanadoo.co.uk>
Date: 29 May 2007 02:28:49 -0700
Message-ID: <1180430929.297416.175320@m36g2000hse.googlegroups.com>


I seem to have got myself into a bit of a pickle with this one.

After creating the 'THIS_IS_MY_MAP' table as user THIS_IS_ME I have then attempted to create
and compile the THIS_IS_MY_INS_SEQ trigger to insert a new ID number into THIS_IS_MY_MAP.IMG_ID
before each row is inserted into the THIS_IS_MY_MAP table.

CREATE OR REPLACE TRIGGER THIS_IS_MY_INS_SEQ BEFORE INSERT

	 ON THIS_IS_MY_MAP
	 FOR EACH ROW
BEGIN
	 SELECT THIS_IS_MY_SEQ.NEXTVAL
	 INTO :NEW.THIS_IS_MY_MAP.IMG_ID
	 FROM DUAL;

END;
/

However, when I attempt to compile the trigger I get the following error message:

PLS-00049: bad bind variable 'NEW.THIS_IS_MY_MAP'

Removing the colon then gives me this error message:

PLS-00201: identifier 'NEW.THIS_IS_MY_MAP' must be declared

After searching the web I concluded that this is a privilege issue and simply granted all on
THIS_IS_MY_MAP to THIS_IS_ME although I am still puzzled as to why I need to do this if I created
all the objects THIS_IS_MY_MAP, THIS_IS_MY_SEQ and THIS_IS_MY_INS_SEQ.

In any case I am still getting the same error messages!

Thanks in advance,

tb31 Received on Tue May 29 2007 - 04:28:49 CDT

Original text of this message

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