473,671 Members | 2,216 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Unable to call the Procedure inside Trigger

1 New Member
I'm just a beginner in PL/SQL. I'm trying to call the TESTPROC procedure inside my TRIGGER. Here is my code:

CREATE TABLE FORTESTING
(
TestName VARCHAR(50) ,
);

CREATE OR REPLACE TRIGGER TESTTRIG
BEFORE INSERT ON FORTESTING
FOR EACH ROW
BEGIN
CALL TESTPROC();
END;
/

CREATE OR REPLACE PROCEDURE TESTPROC (name VARCHAR2)
AS
v_name FORTESTING.Test Name%TYPE;

BEGIN
IF v_name := name THEN
DBMS_OUTPUT.PUT _LINE('Test Name ' || name || ' EXIST' );
END IF;
EXCEPTION
WHEN NO_DATA_FOUND THEN
DBMS_OUTPUT.PUT _LINE ('Test Name ' || name || ' NOT FOUND');
END;
/

After checking the Trigger, i got the below error:
Error(2,10): PLS-00103: Encountered the symbol "TESTPROC" when expecting one of the following: := . ( @ % ; The symbol ":=" was substituted for "TESTPROC" to continue.

Can anyone tell me if my codes are correct and how to fix this error?

Thank you.
Sep 29 '17 #1
0 5195

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

Similar topics

13
2311
by: Marcin Wasilewski | last post by:
Hi, How to call procedure, which is on SQL Server from Access using visual basic? Thanks, mw
1
1481
by: simonZ | last post by:
How can I call sub from aspx page? If I have on aspx page grid view and I call procedure from item Template: <asp:GridView ... .... <ItemTemplate> <%# test()%> and in code behind: protected String test()
1
7857
by: eRTIS SQL | last post by:
hi, I want to use a stored procedure inside a stored procedure simulteanously changing the database. this is my base store procedure alter PROCEDURE create_file @dbname sysname AS declare @fname varchar(30) declare @fsizes nvarchar BEGIN
2
9241
by: kaushikroy | last post by:
i m getting this error when i m executing a stored procedure Maximum stored procedure, function, trigger, or view nesting level exceeded (limit 32). can anyone help me out what exactly the problem
2
2286
by: sscheral | last post by:
can we use stored procedure inside trigger? if yes how
2
2377
by: bandarisathish | last post by:
can we write a procedure inside the function? and the reverse?
5
7269
kaleeswaran
by: kaleeswaran | last post by:
Hi! can i call the procedure inside the trigger?.... thank you, kaleeswaran
0
1445
by: Kozy | last post by:
Hello everyone, I have a problem with a procedure that is calling another procedure. Pasting some code: INSERT INTO LOGGING.POTRDITEV_FAKTURE(A,B,C) VALUES(4, 'POTRDITEV_FAKTURE_DODATEK ZA FAKT_ID = '||TRIM(CHAR(NFAKT_ID)), CURRENT TIMESTAMP); CALL POTRDITEV_FAKTURE_DODATEK(NFAKT_ID, XPODR_ID, XVRDO_ID, XFAKT_FAKTURA, XTBLA_ID, XDELA_ID, XPART_ID, XPART_ID_KUPEC, XPATI_ID, XFAKT_FINSTFAKTURE); INSERT INTO...
0
1447
by: sagarika panda | last post by:
In oracle pl/sql how can i call a procedure inside a function?
8
1889
Ajay Bhalala
by: Ajay Bhalala | last post by:
I have one application in which I used one richtextbox and some buttons. I have 1 button named "Delete". I want to create delete command using the code. When the user clicked the "Delete" button after the entering and selecting the text in richtextbox then the selected text should be deleted. How can I do this?
0
8472
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
8819
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8596
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
8667
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
7428
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
5690
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4221
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
4399
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
1801
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.