Creating Triggers
I am trying to create a trigger which will eventually call a judf.. However my mysql does not understand the delimiter command. actually... help doesnot even list delimiter as a possible command.. I am using MySQL- 5.0-22 Max server ... Installed it from a non-rpm binary distribution.. Also.. is it possible to call UDFs from within Triggers... Hope to hear at the earliest... Thanks in advance. Palani.
creating triggers?
I would like to create a trigger that either updates or inserts a row in my USERS_PER_HOUR table when an entry is made in the LOG table. The log table has LOG_DATE, LOG_TIME and a CUID columns that I would like to either create a new row if the LOG_DATE and LOG_TIME do not exist or update the number of CUIDS for that date and time if it does. I have never done anything with triggers and wonder if this is possible? John Brittingham Marketing and Customer Systems Desk: 425-288-8071 Cell: 425-770-0458
Creating Triggers and procedures in MySQL
Hi All, I am looking into putting triggers, procedures and into MySQL. The tools I am using seem to lack this facility, unless MySQL doesnot actually have these important database features. Any help is appreciated. Gregory Hicks Database Analyst Programmer -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Creating Triggers and procedures in MySQL
Information from the manual: 1.7.4.4 Stored Procedures and Triggers Stored procedures are being implemented in our version 5.0 development tree. See section 2.3.4 Installing from the Development Source Tree . This effort is based on SQL-99, which has a basic syntax similar (but not identical) to Oracle PL/SQL. In addition to this, we are implementing the SQL-99 framework to hook in external languages. A stored procedure is a set of SQL commands that can be compiled and stored in the server. Once this has been done, clients don't need to keep re-issuing the entire query but can refer to the stored procedure. This provides better overall performance because the query has to be parsed only once, and less information needs to be sent between the server and the client. You can also raise the conceptual level by having libraries of functions in the server. However, stored procedures of course do increase the load on the database server system, as more of the work is done on the server side and less on the client (application) side. Triggers will also be implemented. A trigger is effectively a type of stored procedure, one that is invoked when a particular event occurs. For example, you can install a stored procedure that is triggered each time a record is deleted from a transactional table and that stored procedure automatically deletes the corresponding customer from a customer table when all his transactions are deleted. = Last time this was brought up, there was a long discussion between the I love stored-procedures and the I hate store-procedure groups of people. Hopefully, we won't get that again. If you are interested in the lengthy discussion, you may want to search the list archives. On Mon, 06 Oct 2003 10:54:48 -0850 (CDT), Gregory Hicks spoke thusly about Creating Triggers and procedures in MySQL: Hi All, I am looking into putting triggers, procedures and into MySQL. The tools I am using seem to lack this facility, unless MySQL doesnot actually have these important database features. Any help is appreciated. Gregory Hicks Database Analyst Programmer --- Listserv only address. Jeff Shapiro -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Creating Triggers and procedures in MySQL
Jeff, Your name is familiar to me. Are you involved in any way with the Borland C++ Builders list on Topica.com? OK, that explains why I can't find the feature. I consider them to be important, but not mandatory. Their presence can simplfy business rules in data processing. regards greg On Sun, 5 Oct 2003 19:48:36 -0600, Jeff Shapiro wrote: Information from the manual: 1.7.4.4 Stored Procedures and Triggers Stored procedures are being implemented in our version 5.0 development tree. See section 2.3.4 Installing from the Development Source Tree . This effort is based on SQL-99, which has a basic syntax similar (but not identical) to Oracle PL/SQL. In addition to this, we are implementing the SQL-99 framework to hook in external languages. A stored procedure is a set of SQL commands that can be compiled and stored in the server. Once this has been done, clients don't need to keep re-issuing the entire query but can refer to the stored procedure. This provides better overall performance because the query has to be parsed only once, and less information needs to be sent between the server and the client. You can also raise the conceptual level by having libraries of functions in the server. However, stored procedures of course do increase the load on the database server system, as more of the work is done on the server side and less on the client (application) side. Triggers will also be implemented. A trigger is effectively a type of stored procedure, one that is invoked when a particular event occurs. For example, you can install a stored procedure that is triggered each time a record is deleted from a transactional table and that stored procedure automatically deletes the corresponding customer from a customer table when all his transactions are deleted. = Last time this was brought up, there was a long discussion between the I love stored-procedures and the I hate store-procedure groups of people. Hopefully, we won't get that again. If you are interested in the lengthy discussion, you may want to search the list archives. On Mon, 06 Oct 2003 10:54:48 -0850 (CDT), Gregory Hicks spoke thusly about Creating Triggers and procedures in MySQL: Hi All, I am looking into putting triggers, procedures and into MySQL. The tools I am using seem to lack this facility, unless MySQL doesnot actually have these important database features. Any help is appreciated. Gregory Hicks Database Analyst Programmer --- Listserv only address. Jeff Shapiro -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]