Disappearing records?

2002-11-18 Thread Greg Macek
Hello,

I have a problem that I could use some help with. We're running a
mysql/php intranet site for time sheets (home grown solution). However
from time to time a user will tell me hours from the previous week are
just gone. I go to look and sure enough, no hours have been entered. I
have not been bitten by this bug (yet), but I have never encountered
this problem with any other databases that exist on this very same box.
I have mysql logging enabled and cannot even find existence of these
records being inserted into the database at all. 

Where should I start looking for clues? I am at a loss. Any direction is
appreciated.

Running Mysql 3.23.49-log on a SuSE 7.3 box running on Dell PowerEdge
2550. Lots of RAM and hard drive space. It's a MyISAM table at the
moment. The machine has been running since late July w/o reboot (server
and mysql itself).

- Greg



-
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




Re: Disappearing records?

2002-11-18 Thread Dan Nelson
In the last episode (Nov 18), Greg Macek said:
 Hello,
 
 I have a problem that I could use some help with. We're running a
 mysql/php intranet site for time sheets (home grown solution). However
 from time to time a user will tell me hours from the previous week are
 just gone. I go to look and sure enough, no hours have been entered. I
 have not been bitten by this bug (yet), but I have never encountered
 this problem with any other databases that exist on this very same box.
 I have mysql logging enabled and cannot even find existence of these
 records being inserted into the database at all. 

If you have no record of the records having been entered, maybe the
user never entered them?  Or could there have been a problem with the
frontend program that kept it from submitting the data?

-- 
Dan Nelson
[EMAIL PROTECTED]

-
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




Re: Disappearing records?

2002-11-18 Thread Greg Macek
That's the weird part of it. Last week in reviewing the system, making
sure reports were working I can personally verify his stuff was in there
(not even logged on as him). This week: nothing. Is there any record of
3.23.49 ever having random data loss issues? Related to something else
on the system?

On Mon, 2002-11-18 at 10:37, Dan Nelson wrote:
 In the last episode (Nov 18), Greg Macek said:
  Hello,
  
  I have a problem that I could use some help with. We're running a
  mysql/php intranet site for time sheets (home grown solution). However
  from time to time a user will tell me hours from the previous week are
  just gone. I go to look and sure enough, no hours have been entered. I
  have not been bitten by this bug (yet), but I have never encountered
  this problem with any other databases that exist on this very same box.
  I have mysql logging enabled and cannot even find existence of these
  records being inserted into the database at all. 
 
 If you have no record of the records having been entered, maybe the
 user never entered them?  Or could there have been a problem with the
 frontend program that kept it from submitting the data?
 
 -- 
   Dan Nelson
   [EMAIL PROTECTED]



-
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




Re: Disappearing records?

2002-11-18 Thread Dan Nelson
In the last episode (Nov 18), Greg Macek said:
 That's the weird part of it. Last week in reviewing the system,
 making sure reports were working I can personally verify his stuff
 was in there (not even logged on as him). This week: nothing. Is
 there any record of 3.23.49 ever having random data loss issues?
 Related to something else on the system?

Even if there was dataloss, how could you explain not seeing the
entries in the mysql log?  I think in this case the query never made it
to mysql.  You can always try doing a repair table in case the index
got damaged.  Also check your log to see if the record was manually
deleted.

-- 
Dan Nelson
[EMAIL PROTECTED]

-
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




Re: Disappearing records?

2002-11-18 Thread Greg Macek
I'll look into the code on the PHP side (since I wrote that too). Maybe
it is something I did. :)

I may avoid repairing the tables for now, since the missing records have
already been re-entered and I don't want to risk anything being
duplicated at this point. Perhaps I'll drop all the indexes for now and
keep a watch on things. The table is still small ( 5000 records) so
reporting speed isn't too much of a problem right now. 



On Mon, 2002-11-18 at 10:52, Dan Nelson wrote:
 In the last episode (Nov 18), Greg Macek said:
  That's the weird part of it. Last week in reviewing the system,
  making sure reports were working I can personally verify his stuff
  was in there (not even logged on as him). This week: nothing. Is
  there any record of 3.23.49 ever having random data loss issues?
  Related to something else on the system?
 
 Even if there was dataloss, how could you explain not seeing the
 entries in the mysql log?  I think in this case the query never made it
 to mysql.  You can always try doing a repair table in case the index
 got damaged.  Also check your log to see if the record was manually
 deleted.
 
 -- 
   Dan Nelson
   [EMAIL PROTECTED]



-
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




RE: Disappearing records?

2002-11-18 Thread Andrew Braithwaite
Greg Macek said..
---
I have a problem that I could use some help with. We're running a
mysql/php intranet site for time sheets (home grown solution). However from
time to time a user will tell me hours from the previous week are just
gone. I go to look and sure enough, no hours have been entered. I have not
been bitten by this bug (yet), but I have never encountered this problem
with any other databases that exist on this very same box. I have mysql
logging enabled and cannot even find existence of these records being
inserted into the database at all. 

Where should I start looking for clues? I am at a loss. Any direction is
appreciated.
--

Greg,

In my experience, it will be something simple like not escaping ticks...

Are you escaping mysql unfriendly characters from text?  i.e. ' vs \'

I use a simple logfile to to track these kinds of things.  In your case, I
would put a line of code in your script, right before the line that executes
the insert into MySql that writes the query into a plaintext log somewhere.

Sequence in code..
1. Build the sql statement  store in a variable.
2. Using that variable and a unix date, write a line in the logfile.
3. Execute the sql in the variable.

When the user says that records are missing, you can look back in the log
and find out whether the query was ever sent to mysql in the first place and
what that query was.

If I had to guess, I would say the problem would be in the app or mysql
syntax error rather than a mysql itself problem.

Hope this helps,

Andrew
Sql,mysql

-
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




Re: Disappearing records?

2002-11-18 Thread Michael T. Babcock
Greg Macek wrote:


That's the weird part of it. Last week in reviewing the system, making
sure reports were working I can personally verify his stuff was in there
(not even logged on as him). This week: nothing. Is there any record of
3.23.49 ever having random data loss issues? Related to something else
on the system?
 


Big rollback?  Drive corruption?  User deleing records?  Renaming files 
/ directories?

QUERY, SQL

--
Michael T. Babcock
C.T.O., FibreSpeed Ltd.
http://www.fibrespeed.net/~mbabcock



-
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