how to select the record with one sql statement?

2018-08-13 Thread sea
helle,
   I have a table, like this:
 pigId  dayweigt
  pig1  2018-1-121
  pig2  2018-1-131
  pig3  2018-1-141
  pig1  2018-1-222
  pig2  2018-1-231
  pig3  2018-1-240
  pig1  2018-1-323  pig2  2018-1-330
  pig3  2018-1-341
  .

   only the pig1'weight increase continuously for 3 days.   Giving the input: 
num_of_day(weight increasing continuously for num_of_day);   expecting the 
output: certain_day, pigId;from certain_day,  pigId'weight increasing 
continuously for num_of_day.  How to select the records in one sql 
statement?
thanks

what is the rationale for not allowing LOCK TABLES in a stored procedure

2018-08-13 Thread jeff
Hello, I have read through several pages of the reference manual, and
I've seen several instances where it is stated that LOCK TABLES (and
UNLOCK TABLES) is not allowed in a stored procedure, but so far, I
haven't found an explanation as to *why* that is. Could someone please
enlighten me?

Thanks



--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/mysql