forums › forums › SQLyog › Sync tools, Migration, Scheduled Backup and Notifications › SJA job running for 11 hours
- This topic is empty.
-
AuthorPosts
-
-
May 23, 2005 at 9:33 am #17902
Ritesh
MemberIt also depends upon your table structure and data. If there are too many blob columns then it takes time to generate checksums for the row.
-
May 23, 2005 at 10:25 am #17903
peterlaursen
Participant@ ritesh
There are a lot of big varchars and some mediumtext's – most of which are empty or only contain relatively few characters.
So your theory about BLOBs and the like could very well be true. But wil SJA have to “unfold” those variables. A varchar[255] containing the string 'abc' takes 4 bytes on the server – one “control byte” and three data bytes. Why calculate checksums of 255 bytes when there is only 3 bytes of data? Same argumentation goes for BLOBS. At least skip calculating checksums where data fields are empty! If any optimization like this is possible it should be implemented …
It's is more than 2 times as fast to do INSERT as UPDATE. Why ? Could it have something with the php-configuration at the server to do ?
-
May 23, 2005 at 12:56 pm #17904
Ritesh
MemberQuote:It's is more than 2 times as fast to do INSERT as UPDATEThere is valid reason to that. Its how MySQL (for any database) are designed. Reading the MySQL docs wil throw more light on the subject.
-
May 23, 2005 at 12:58 pm #17905
Shadow
MemberINSERTs are usually a lot faster than UPDATEs when BLOB fields are affected. Why? BLOB values are not stored in the table structure, only a pointer is placed there. Therefore MySql has to (1) locate the record to be updated, (2) get BLOB pointer(s), (3) locate BLOB value(s), update BLOB value(s). Inserting data is lot simpler…
-
-
AuthorPosts
- You must be logged in to reply to this topic.