MySQL Forums
Forum List  »  Triggers

Re: check two columns
Posted by: Mohamed Mansour
Date: December 08, 2005 12:33AM

Are you trying to insert into the database?
or receive?

If your recieving, please take this note:
your trigger even can be either INSERT, LOAD DATA, REPLACE, UPDATE, DELETE.

Therefore no SELECT. Use views if you want to select.

Any why wont you make a javascript or serverside check? Instead of a database check.

If your inserting, you could do this..

create a procedure that checks when if each row is null or empty

and then use your trigger to call that procedure...


Hope it helps, I recommend you to read
http://dev.mysql.com/doc/refman/5.0/en/create-trigger.html
and
http://dev.mysql.com/doc/refman/5.0/en/create-procedure.html

Take care, ciao

Options: ReplyQuote


Subject
Views
Written By
Posted
2717
December 08, 2005 12:19AM
Re: check two columns
1521
December 08, 2005 12:33AM
1970
December 08, 2005 12:46AM
2299
December 08, 2005 12:54AM
1865
December 08, 2005 12:59AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.