RE: How to get previous and next result

2003-09-09 Thread Christopher Knight
next: select cols from table where id > YOUROLDID and forums = CURRENT_FORUM order by id limit 1 previous: select cols from table where id < YOUROLDID and forums = CURRENT_FORUM order by id desc limit 1 however, this may not be as fast or efficient enough ou might want to create another id field

RE: Huge Server configuration

2003-07-24 Thread Christopher Knight
BEGIN my.cnf [mysqld] port = 3306 socket= /tmp/mysql.sock basedir = /usr/local/mysql log = /var/log/mysql/mysql.log log-slow-queries = /var/log/mysql/mysql-slow.log log-err = /var/log/mysql/mysql.err log-bi

RE: Huge Server configuration

2003-07-24 Thread Christopher Knight
what table types? Innodb.etc... about how many tables? do you do alot of sorting? are the exact same queries repeated alot? is the machine doing anything else or is mainly a DB server? can I borrow the machine for awhile? what version of mysql are you running? chris -Original Message- Fr

RE: What is a good benchmark?

2003-07-23 Thread Christopher Knight
>Is it me or do these dual athlons seem rather responsive! Yay!! I win (so far... heh)! I ran it on one of our servers (not idle... running apache w/ CGIs and db calls ~ 140,000 scripts/day ) We are using as many tricks as we can. 0. mysql 4.0 binary from mysql.com 1. we set the n

RE: What is a good benchmark?

2003-07-23 Thread Christopher Knight
1 row in set (0.54 sec) 2x Athlon2100 2GB Ram Linux 2.4.20 -Original Message- From: Jake Johnson [mailto:[EMAIL PROTECTED] Sent: Wednesday, July 23, 2003 9:34 AM To: Mysql Subject: What is a good benchmark? I ran this benchmark on my pIII 500 and was wondering what everyone else was ge

RE: grouping / sorting etc..

2003-07-14 Thread Christopher Knight
Thanks for everybody's help!! This way worked for me. Clever! Chris ... and yes... even my example was messed up :-P -Original Message- From: Rudy Metzger [mailto:[EMAIL PROTECTED] Sent: Monday, July 14, 2003 4:15 AM To: Christopher Knight; MySQL List Subject: RE: grouping / so

grouping / sorting etc..

2003-07-11 Thread Christopher Knight
Im having troubles getting the results I want... can someone suggest which way to go.. mysql 4.0 A | 1 | | | 1 | BAD | | 2 | | | 3 | BAD | | 3 | | | 4 | BAD | | 5 | | | 5 | BAD | | 5 | BAD | what I want is 5 results. If there is a NULL, then ret

RE: mysqld question

2003-06-24 Thread Christopher Knight
/Tips.html -Original Message- From: Henrik Leghissa [mailto:[EMAIL PROTECTED] Sent: Tuesday, June 24, 2003 9:42 AM To: Christopher Knight Subject: RE: mysqld question At 16:39 2003-06-24, Christopher Knight wrote: >it really depends on > how big your database is > what else is ru

RE: mysqld question

2003-06-24 Thread Christopher Knight
it really depends on how big your database is what else is running on the server (apache..) how many connections at once percentage of selects to updates/inserts do you have indexes what version are you running what is your mom's maiden name if you look at the sun, how long to you blink :

RE: Textfile to a 2 column mysql database

2003-06-23 Thread Christopher Knight
OR, if you are good at vi, you can insert a ' at the begining and end of every line (if you dont have any 's in the file) then put a , at the end of every odd line then join every other line the put a "insert into blah (question, answer) values ( " at the begin of every line and then

How to UNSUBSCRIBE

2003-06-19 Thread Christopher Knight
I swear we went over this today... for anybody still unsure... give a look at the bottom of any email you recieve from the list and it will say 'To unsubscribe' on the last line... just click the link It will probably be at the end of this message even.. -- MySQL General Mailing List For list a

RE: RAID hardware suggestions/experience

2003-06-17 Thread Christopher Knight
Optimally, Yes, you should replace with exact same brand/model etc... but you CAN replace with a different brand/ model drive of the same amount of disk space or more. It isn't recomended (because of different seek times, cache .. etc..) but if you are carefull and do your research, you can get a

RE: RAID hardware suggestions/experience

2003-06-17 Thread Christopher Knight
Im using a 3ware (which has great linux support) Escalade 7800 with 8 120GB/8MB cache ide drives in RAID 10 under Debian with 2.4.20 kernel. I guess what we need to know is what platform and how much $$ you wanna spend -Original Message- From: Bernd Jagla [mailto:[EMAIL PROTECTED] Sent: T

RE: delete record

2003-06-12 Thread Christopher Knight
hehe... been there... if there isnt a way if you have logging turned on, you might be able to find the insert and following updates statements in the log to rebuild the row. good luck chris -Original Message- From: Arcangelo [mailto:[EMAIL PROTECTED] Sent: Thursday, June 12, 2003 10:2

sum on counts

2003-06-12 Thread Christopher Knight
Can you sum on counts? What I want is the # of objects with a freq of 1, freq of 2, freq of 3... and then total # of objects. >>select object_id from object_hist where type_id=5879; +---+ | object_id | +---+ | 2121 | | 3234 | | 2121 | | 4876 | | 4876 | |

subselects in 4.1 and indexes

2003-06-09 Thread Christopher Knight
Im have a problem / misunderstanding with the 4.1 release. Im having issues with indexes related to 'IN' vs '=' in subselects. assume the subselect returns 1 value select SQL_NO_CACHE user_id from table_a where user_id in (select SQL_NO_CACHE user_id from table_b where ... blah) 9.5 seconds... s