Error 127

2001-07-18 Thread Walter Lee Davis
I have determined that error 127 is 'index has crashed', but I have no idea if this is recoverable. I have a table with just under 7000 rows, and I am getting this error when I try to count the records and set up the variables to page through the records n at a time. Is there any practical limit t

Table keeps corrupting

2001-07-20 Thread Walter Lee Davis
This is the feedback from repair: mysql> repair table hits -> ; +--++--+ -+ | Table| Op | Msg_type | Msg_text | +--++--+ -+ | counter.hit

Is last_insert_id reliable?

2001-07-20 Thread Walter Lee Davis
I have a hit counter script that logs all its hits in one table, one row per hit. Currently, I have been counting the rows in PHP in order to get the value of the last hit_id in the database like this: $sql4 = "SELECT hits.hit_id from hits"; $result = mysql_query ($sql4, $connection) or die("e

Re: Is last_insert_id reliable?

2001-07-20 Thread Walter Lee Davis
many rows there are in a table. last_insert_id() > has nothing to do with how many rows are in a table. > > If you are going to delete old rows one day, then you might want to do this: > > SELECT MAX(id) as pixels FROM hits > > Hope that helps. > > On Friday 20 July

Re: Is last_insert_id reliable?

2001-07-20 Thread Walter Lee Davis
This is precisely what I did, only I left out the 'as max_hit_id' part, and jumped right to pixels. Works quickly and neatly. Thanks very much. Walter On 7/20/01 6:35 PM, "Jonothan Farr" <[EMAIL PROTECTED]> wrote: > LAST_INSERT_ID is the value of the auto increment field in the table that was >

Re: Is last_insert_id reliable?

2001-07-21 Thread Walter Lee Davis
t;>> last_insert_id() has nothing to do with how many rows are in a table. >>> >>> If you are going to delete old rows one day, then you might want to do >>> this: >>> >>> SELECT MAX(id) as pixels FROM hits >>> >>> Hope tha

Re: [mysql.server stop fails under OpenBSD 2.9]

2001-07-23 Thread Walter Lee Davis
Could this be related to the problems which cause mysql to be almost un-killable on MacOS X? I have tried to use mysqladmin to stop the server, but the only thing that will do it is 'kill -9', and if I had started it with safe_mysqld, then it comes bouncing right back. I can't even find safe_mysql

Re: [mysql.server stop fails under OpenBSD 2.9]

2001-07-23 Thread Walter Lee Davis
listen to a kill. Only kill -9 released it. Mysql is still running. Walter On 7/23/01 8:39 AM, "Sinisa Milivojevic" <[EMAIL PROTECTED]> wrote: > Walter Lee Davis writes: >> Could this be related to the problems which cause mysql to be almost >> un-killable

Re: [mysql.server stop fails under OpenBSD 2.9]

2001-07-23 Thread Walter Lee Davis
gt; Geschäftsführer / CEO iConnect e-commerce solutions GmbH > # www.js-webShop.com www.iConnect.de > # Gustav-Meyer-Allee 25, 13355 Berlin > # Tel: +49-30-46307-382 Fax: +49-30-46307-388 > > - Original Message - > From: "Walter Lee Davis" <[EMAIL PROTEC

Re: error 127

2001-07-25 Thread Walter Lee Davis
in the mysql command line, try this: use databasename; repair table tablename; (repeat that last line for each of your tables) I haven't tried myisamchk at all. This is what I use. Walter At 12:13 PM -0400 7/25/01, Marko Andrus wrote: >Hi- > >I am getting error 127 and I cant seem to get the m

Re: Setting up "no password" users?

2001-07-25 Thread Walter Lee Davis
You probably want to GRANT ALL ON oneDatabase.* TO login@%. I can't image a situation where letting everyone see everything (including the mysql database with all the permissions) would ever be a good idea. Walter At 7:44 PM +0200 7/25/01, Stefan Hinz wrote: >Dear KJ, > >> How can >> I set up

[newbie] how do I force a numerical comparison of two md5 strings

2002-10-31 Thread Walter Lee Davis
Am I right in assuming that comparing two md5 strings would be faster if they were compared as two hexadecimal numbers than if they were compared as two strings? If so, is there any way to insist on this in a SQL query? I am using PHP, and would like to know from that perspective if it makes an

Re: Newbie question: Storing text

2002-11-02 Thread Walter Lee Davis
VARCHAR is limited to 256 characters. TEXT is much longer, like 6000 or 6 characters or so, don't actually know. I believe both TEXT and varchar both support full text searches. You can store HTML in the database, just be sure to addslashes and stripslashes going in and out. Your server may be

Re: auto_increment in multiple tables...

2002-11-02 Thread Walter Lee Davis
Are you using PHP? There is a useful function in there that would give you the last auto-number, like this: (do your first insert) $insert_key = mysql_insert_id(); (do your second insert, using $insert_key as the new foreign key that you are putting in your SQL) Now each table has its own auto-