RE: innodb monitor
Hi, you can see the monitor's output in the logfile. In my case (mandrake linux), it is in /var/lib/mysql and I do: tail -f /var/lib/mysql/SERVERNAME.err Also, where do I designate autocommit = 0; Use SET AUTOCOMMIT = 0 as a SQL query. Just issue it where you do your SELECT, UPDATE etc. queries, and don't forget to SET AUTOCOMMIT = 1 afterwards. - 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
BETWEEN function
Hello everybody, I could not find any documentation about the BETWEEN function. Am I just blind? Please point me to it. Or is it not stable yet? How does it perform in comparison to field1 = x AND field1 = y? Thanks, Felix sql, query - 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
BETWEEN: So, what happens here?
Hello everybody, there is a table containing a date field named datum. I want to find out the rows containing a date BETWEEN two given dates. And I do: SELECT * FROM table1 WHERE datum BETWEEN '-00-00' AND '2002-03-10'; This one does what it's supposed to do. But now I need to add one day to the start date on SQL level. So I do: SELECT * FROM table1 WHERE datum BETWEEN ('-00-00' + INTERVAL 1 DAY) AND '2002-03-10'; MySQL returns an empty result set, but it shouldn't (the table contains dates year 2000 and up. EXPLAIN SELECT * FROM table1 WHERE datum BETWEEN ('-00-00' + INTERVAL 1 DAY) AND '2002-03-10'; - +-+ | Comment | +-+ | Impossible WHERE noticed after reading const tables | +-+ ?? Thanks for any advice, Felix - 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: **Backing Up A Database**
You may simply copy or move logrotate from /etc/cron.daily in /etc/cron.hourly. Logrotate will then be executed hourly, have a look into /etc/logrotate.conf, /etc/logrotate.d and determine which files are due to be rotated. But as you cannot set other delays but daily,weekly,monthly (see man logrotate), I suggest some tricking: add size 10k in the /etc/logrotate.d/-file you created, so that logrotate will find it due every day or when its size grew bigger than 10k (i.e. very soon, more often than daily...). For testing purposes, you may also just call /etc/cron.daily/logrotate by hand from the commandline. Felix -Ursprüngliche Nachricht- Von: Alexander Shaw [mailto:[EMAIL PROTECTED]] Gesendet: Mittwoch, 20. Februar 2002 01:15 An: MySQL List; Felix Richter Betreff: RE: **Backing Up A Database** Hi Felix (or anyone), I'm giving this a go but as a Linux newbie running Red hat 7.2 I have a question to ask Do I need to alter anything in Cron for it to run the logrotate script? What would I need to put into the hourly cron folder to make things happen more often to check they are working correctly? Alex - 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
SELECT and UPDATE in one query?
Hi! I need to SELECT some rows using a lengthy WHERE-clause and then to UPDATE these rows just to set a flag. What is the best way to do this (performance-wise)? Being able to do that in one single query would be great because otherwise I had to use transactions to be sure to match _exactly_ the selected rows. Felix - 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
BDB Transaction Timeout?
Hello, how do I close a stale transaction? The problem is a PHP script opening a transaction, doing some inserts and then possibly terminating the connection on error without doing a COMMIT or ROLLBACK, so everything stays blocked. I found no other way out but to restart the server... I read about MySQL doing a ROLLBACK automatically after some time with InnoDB tables. What about BDB? (MySQL ver 3.23.41) Thanks, Felix. - 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: **Backing Up A Database**
Please see http://www.mysql.com/doc/B/a/Backup.html I personally issue mysqldumps via cron and maintain the files using logrotate (Redhat Linux), which automatically zips and rotates them. - 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: **Backing Up A Database**
- create a file in /etc/logrotate.d, filename does not matter, take this as a template, fill in connection parameters in mysqldump call (): /home/backup/sqlback/mybackup.sql { daily nomissingok nocreate compress rotate 14 errors [EMAIL PROTECTED] prerotate mysqldump --opt --full /home/backup/sqlback/mybackup.sql endscript } - check syntax and options of this file: man logrotate - you're set: cron will call logrotate each night. logrotate processes each file in the dir, executes the prerotate script and then compresses the logfile (i.e. SQL-Dump), renames older ones and keeps at max 14 of them (rotate 14). nomissingok will let you know if the mysqldump failed Felix - 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