473,698 Members | 2,404 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

ORA-00904: "ACTION": invalid identifier

4 New Member
Hey guys I am trying to create an trigger, but getting this error. My code is as follows
Expand|Select|Wrap|Line Numbers
  1. CREATE OR REPLACE TRIGGER vendorpricingTR
  2. BEFORE UPDATE OF pricing ON vendors
  3. FOR EACH ROW
  4. DECLARE 
  5. ActionVar char(6);
  6. BEGIN
  7.  
  8. IF UPDATING THEN
  9. ActionVar :=’UPDATE’;
  10. END IF;
  11. INSERT into VENDORS
  12. (vendorsname,addr,pricing,ratings, Action)
  13. VALUES (:old.vendorsname, :old.addr, :new.pricing,  :old.ratings, Actionvar);
  14.  
  15. END;
  16.  
error is

LINE/COL ERROR
-------- -----------------------------------------------------------------
8/1 PL/SQL: SQL Statement ignored
9/36 PL/SQL: ORA-00904: "ACTION": invalid identifier
Dec 12 '09 #1
6 8549
debasisdas
8,127 Recognized Expert Expert
Is action a field in your table ?
Dec 12 '09 #2
viny2cool
4 New Member
Action is a new column I want to insert in the table.......... .....
Dec 12 '09 #3
amitpatel66
2,367 Recognized Expert Top Contributor
Can you please post the output of the below command here for reference:

Expand|Select|Wrap|Line Numbers
  1.  
  2. SQL> desc VENDORS
  3.  
  4.  
Dec 14 '09 #4
debasisdas
8,127 Recognized Expert Expert
the column must exist in the table to insert the value into it.
Dec 14 '09 #5
Saii
145 Recognized Expert New Member
Re-check your trigger code for following
1. There are no :old values when inserting to a table.
2. This is row level trigger, you need to store the values of the row to use it later.
Dec 17 '09 #6
dbcodeerror
1 New Member
Hi,

This oracle error Action is : Enter a valid column name. A valid column name must begin with a letter, be less than or equal to 30 characters, and consist of only alphanumeric characters and the special characters $, _, and #. If it contains other characters, then it must be enclosed in double quotation marks. It may not be a reserved word.

Source : http://www.dbcodeerror.com/oracle-da...id-identifier/
Dec 21 '09 #7

Sign in to post your reply or Sign up for a free account.

Similar topics

6
3906
by: Tomislav Petrovic | last post by:
I have following code on my page.... $ora_tns = "(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=pirana)(PORT=1521)) )(CONNECT_DATA=(SID=pirana)(SERVER=DEDICATED)))"; $ora_username = "username"; $ora_password = "pwd"; $db = OCILogon($ora_username, $ora_password, $ora_tns);
0
1983
by: Alan Cobban | last post by:
Hello, I'm in the process of tuning our auditing procedures. At present we have one table, mp_event_audits which holds username, date/time, change type, data changed etc columns - DEV> desc mp_event_audits Name Null? Type ------------------------------- -------- ---- EA_ID NOT NULL NUMBER(8)
2
3119
by: smanicom | last post by:
Hi all I need help urgently as I am in the middle of a migration and can't resolve a TNS error. My db has been fine for months! Today I connected as sysdba and shut down the db. Now I am trying to bring it back up but when i try connect as sysdba I get ORA-12154: TNS:could not resolve service name This is odd because I have not changed the tnsnames file at all. Please help Am I missing something simple here?
4
2922
by: mallz | last post by:
hi, im incrementing my id by using sequence in oracle.........but i dont know what to specify in my insert statement in my jsp page.......... while i tried in oracle it worked........i said : insert into table values(id.nextval,'aaa'); but, in my jsp page im getting an error saying : invalid number....... please help me out with this
2
10094
by: Nestor Fra | last post by:
Hi guys I'm tried to open a conection with oracle databse, but I received thoses error(see below). My knwologed about db it's very poor (like my dba), how I can explain to him more clear where he should to check or Fix ? , seems to me that the problem it's of permission.. Thanks in advance Nestor ORA-00604: error occurred at recursive SQL level 1 ORA-12705: Cannot access NLS data files or invalid environment specified
6
38257
by: bhushanbagul | last post by:
Hi All, I m facing mentioned error while executing below code at line no 3. CREATE or REPLACE DIRECTORY MY_DIR AS '/outputs/EXTRACTS'; GRANT READ,WRITE ON DIRECTORY MY_DIR TO public; fileID := UTL_FILE.FOPEN('MY_DIR', fileName,'W'); I tried all the possibe ways but still not understood what is the problem there. Please give ur sugeetions guys so i can try.
3
13974
by: Alv | last post by:
I need a solution how to connect 2 oracle databases using DBLink. Oracle is installed for Linux. It is working properly when I connect from the Oracle for Windows to Oracle for Linux, but there is a problem to connect from Oracle for Linux to Orcale for Linux/Windows. CentOS 4.2 Oracle 9.2 Error: ORA-12154: TNS: could not resolve service name
6
2456
by: julietmachiwa | last post by:
I have an existing database 8i . I just installed Developer 2000 for Windows NT I am failing to connect to the database. How should I configure it? I tried using SQL Net Easy Configuration and Also changed tnsnames.ora but I am getting error "invalid or unknown NLS parameter value specified" when connecting to SQL PLUS 3.3 or Forms Please help
1
3086
by: shashikanth69 | last post by:
Hello, when i try to execute the code it says, ORA-00972: identifier is too long at adapter1.Fill(Ora_Dataset) Sub BindGrid() sSql=”Select * from Audit_Exceptions where Audit_ID=’”+ sauditid +”’ and TO_CHAR(Audit_Date,’MM/DD/YYYY’)= ‘”+sauditdate +”’ and Exception_Status=’”+ exceptionStatus+”’” adapter1=New OracleDataAdapter(sSql,Ora_Conn) adapter1.Fill(Ora_DataSet )
3
1941
by: nur08 | last post by:
/* Note: default for serveroutput is OFF. Therefore no 'Insert attempted' as I did not switch it on by set serveroutput on; */ SQL> CREATE OR REPLACE PROCEDURE add_vacc (pat_id in char, vis_vdate in date, vis_act in number, vac _vacc in char) 2 AS 3 BEGIN 4 insert into vaccinations(pid,vdate,action,vaccinated) values(pat_id,vis_vdate,vis_act,vac_vacc) ;
0
8675
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9160
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
8897
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8862
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7729
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
4370
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4619
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
2331
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2002
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.