Fournier Jocelyn [Presence-PC] writes:
> I believe the problem occurs only when I execute the DELETE when someone is
> inserting a records at the same time.
> Perhaps the hash index is not updated properly whereas the data are deleted
> properly, which entails a mismatch between data and index ?
> (I believe this because the following behaviour :
>
> mysql> INSERT INTO online1 SELECT * FROM online;
> Query OK, 139 rows affected (0.01 sec)
> Records: 139 Duplicates: 0 Warnings: 0
>
> mysql> DELETE FROM online1 WHERE date < 10151111111;
> Query OK, 139 rows affected (0.01 sec)
>
> mysql> SELECT * FROM online1;
> Empty set (0.00 sec)
>
> mysql> DELETE FROM online WHERE date < 10151111111;
> Query OK, 141 rows affected (0.00 sec)
>
> mysql> SELECT * FROM online;
> ERROR 1030: Got error 124 from table handler
> )
>
> online1 table is not used by anyone, I create it for the testcase, but the
> online table is heavily used and updated.
>
Hi!
I have a temporary fix for you.
Final fix will come in 4.0.2.
*** tmp/hp_rnext.c Wed Mar 6 21:55:06 2002
--- heap/hp_rnext.c Wed Mar 6 14:39:16 2002
***************
*** 24,29 ****
--- 24,35 ----
HP_SHARE *share=info->s;
DBUG_ENTER("heap_rnext");
+ if (!(info->s->records))
+ {
+ my_errno=HA_ERR_END_OF_FILE;
+ DBUG_RETURN(my_errno);
+ }
+
if (info->lastinx < 0)
DBUG_RETURN(my_errno=HA_ERR_WRONG_INDEX);
--
Regards,
__ ___ ___ ____ __
/ |/ /_ __/ __/ __ \/ / Mr. Sinisa Milivojevic <[EMAIL PROTECTED]>
/ /|_/ / // /\ \/ /_/ / /__ MySQL AB, Fulltime Developer
/_/ /_/\_, /___/\___\_\___/ Larnaca, Cyprus
<___/ www.mysql.com
---------------------------------------------------------------------
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http://lists.mysql.com/ (the list archive)
To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php