16.3.1.9. Replication and LIMIT

Replication of LIMIT clauses in DELETE, UPDATE, and INSERT ... SELECT
statements is not guaranteed, since the order of the rows affected is not
defined. Such statements can be replicated correctly only if they also
contain an ORDER BY clause.

http://dev.mysql.com/doc/refman/5.0/en/replication-features-limit.html


On 4/28/10 11:24 AM, "Jerry Schwartz" <[email protected]> wrote:

>> -----Original Message-----
>> From: David Florella [mailto:[email protected]]
>> Sent: Wednesday, April 28, 2010 10:51 AM
>> To: [email protected]
>> Cc: 'Krishna Chandra Prajapati'
>> Subject: RE: Replication : request DELETE is not executed on slave
>> 
>> Hi,
>> 
>> In the MySQL documentation, it is written that the two versions are
>> compatible to make a replication.
>> 
>> It seems that if I make a DELETE without the 'LIMIT 7500', the query is
>> replicated to the slave.
>> 
> [JS] This might be my ignorance speaking, but since record order is not
> defined for a database how would the slave know WHICH records to delete.
> 
> The DELETE... LIMIT 7500 would have to be translated into 7500 separate
> DELETEs, and there would have to be some unique way of identifying the
> individual records.
> 
> Regards,
> 
> Jerry Schwartz
> Global Information Incorporated
> 195 Farmington Ave.
> Farmington, CT 06032
> 
> 860.674.8796 / FAX: 860.674.8341
> 
> www.the-infoshop.com
> 
> 
> 
>> Regards,
>> 
>> David.
>> 
>> 
>> -----Message d'origine-----
>> De : Krishna Chandra Prajapati [mailto:[email protected]]
>> Envoy� : mercredi 28 avril 2010 11:15
>> � : [email protected]
>> Cc : [email protected]
>> Objet : Re: Replication : request DELETE is not executed on slave
>> 
>> Hi dflorella,
>> 
>> The important thing about mysql replication is same mysql version for both
>> master as well as slave should be used. It should be taken as good practice.
>> 
>> You need to check that master and slave are in sync. Is there any error
>> (replication) on the slave server. Check the mode, strict or some thing
>> else.
>> 
>> Does the delete command exits in binlog.
>> 
>> Regards,
>> Krishna
>> 
>> 
>> On Wed, Apr 28, 2010 at 2:37 PM, David Florella <[email protected]> wrote:
>> 
>>> Hi,
>>> 
>>> 
>>> 
>>> I am using MySQL replication :
>>> 
>>> 
>>> 
>>> -          The version of the master is 4.1.12-log
>>> 
>>> -          The version of the slave is 5.0.41
>>> 
>>> 
>>> 
>>> When I use the query '' DELETE QUICK FROM [TABLE] WHERE [field] < 'xxxxxx'
>>> LIMIT 7500", the query is executed on the master but not on the slave.
>>> 
>>> 
>>> 
>>> Do you know why the request is not executed on the slave?
>>> 
>>> 
>>> 
>>> Regards,
>>> 
>>> 
>>> 
>>> David.
>>> 
>>> 
>> 
>> 
>> --
>> MySQL General Mailing List
>> For list archives: http://lists.mysql.com/mysql
>> To unsubscribe:    http://lists.mysql.com/[email protected]
> 
> 
> 
> 



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

Reply via email to