| | |
Calling a procedure from Trigger
Please support our MySQL advertiser: PostgreSQL or MySQL? Compare and contrast the two most popular open source databases
![]() |
•
•
Join Date: Oct 2008
Posts: 9
Reputation:
Solved Threads: 0
Hi Group,
I have a small Query regarding calling a procedure from a trigger
please go through the following and please let me knwo if any thing wrong happened.
When I tried to create a trigger to call the procedure it is throwing error.
so please solve my small Query
Thanks in advance
I have a small Query regarding calling a procedure from a trigger
please go through the following and please let me knwo if any thing wrong happened.
sql Syntax (Toggle Plain Text)
DELIMITER $$ DROP PROCEDURE IF EXISTS `test`.`sample` $$ CREATE DEFINER=`root`@`localhost` PROCEDURE `sample`() BEGIN INSERT INTO test.out(num,message) SELECT num,name FROM test.IN,hotel WHERE IN.message = hotel.pin; END $$ DELIMITER ; CREATE trigger `pull` after INSERT on `test.IN` for each row BEGIN CALL sample();
When I tried to create a trigger to call the procedure it is throwing error.
so please solve my small Query
Thanks in advance
Last edited by peter_budo; Jan 6th, 2009 at 9:27 am. Reason: Keep It Organized - For easy readability, always wrap programming code within posts in [code] (code blocks) and [icode] (inline code) tags.
What is the Error that MySQl threw at you ??
Also did you remember to put the "END" at the end of the Trigger.
Also did you remember to put the "END" at the end of the Trigger.
"Any fool can write code that a computer can understand. Good programmers write code that humans can understand."
"How to ask questions the smart way ?"
"How to ask questions the smart way ?"
![]() |
Similar Threads
Other Threads in the MySQL Forum
- Previous Thread: Union Site Search with Relevance
- Next Thread: MySQL Cluster 101 Webcast
| Thread Tools | Search this Thread |
amazon api artisticlicense aws bizspark breathalyzer camparingtocolumns changingprices cmg communityjournalism contentmanagement contractors copyright count court crm data database design developer development distinct drupal dui ec2 email enterprise eudora facebook form foss gartner gnu government gpl greenit groklaw groupware hiring hyperic images innerjoins insert ip joebrockmeier journalism keyword keywords kickfire laptop law legal license licensing linux managing mariadb matchingcolumns metron micromanage microsoft microsoftexchange mindtouch montywidenius mozilla multiple music mysql mysqlcolumnupdating mysqlindex mysqlinternalqueries mysqlquery mysqlsearch news opendatabasealliance opengovernment opensource oracle penelope php priceupdating query referencedesign reorderingcolumns resultset saas select sharepoint simpledb single sourcecode spotify sql sugarcrm syntax table techsupport thunderbird transparency virtualization






