Re: RE - Order By Problem

2004-06-08 Thread Vadim P.
If surname is a field, then use it without the single quotes ('), otherwise it is treated as a literal string and 0 is the correct result: select locate(' ',surname,1) from advisers andy thomas wrote: Yes, this is the approach I was thinking of using but: select locate('

Re: User variables + SUM + GROUP BY = strange behavior

2004-04-16 Thread Vadim P.
/doc/mysql/en/Variables.html A little ways down the page... The general rule is to never assign and use the same variable in the same statement. -- Tripp --- Vadim P. [EMAIL PROTECTED] wrote: Sorry, the message got garbled, here is a more digestible look: -Original Message- Hello all

User variables + SUM + GROUP BY = strange behavior

2004-04-13 Thread Vadim P.
Hello all, Could anyone comment on User Variable behavior in the example below? Thanks, Vadim. = mysql SELECT - LEFT(CallTime,10) AS CallDate, - @a := SUM(Charge), - @b := SUM(Cost), -

User variables + SUM + GROUP BY = strange behavior

2004-04-13 Thread Vadim P.
Sorry, the message got garbled, here is a more digestible look: -Original Message- Hello all, Could anyone comment on User Variable behavior in the example below? Thanks, Vadim. = mysql SELECT -

Re: Killing overactive mysql selects

2004-04-09 Thread Vadim P.
Start another Mysql shell session; then do show processlist; identify the thread ID of the offending process, then do kill ID. Not sure how graceful this method is, though. I use it to kill overlooked hanging connections from time to time. Cheers, Vadim. Scott Haneda wrote: Every now and

Re: SELECT DISTINCT.. ORDER BY.. DESC - bug??

2004-03-31 Thread Vadim P.
improves SELECT .. ORDER BY .. ASC, but slows down SELECT.. ORDER BY .. DESC at least by a factor of 10. If this is not a bug, what is it? Vadim P. wrote: Hi all, Sorry to be so persistent, but I am bringing this up again since noone from the MySQL development

SELECT DISTINCT.. ORDER BY.. DESC - bug??

2004-03-30 Thread Vadim P.
Hi all, Sorry to be so persistent, but I am bringing this up again since noone from the MySQL development team commented on my previous post, and the issue seems very serious, to the point I may start looking to switching away from MySQL, so - please, please, shed some light on this issue!!!

ORDER DESC vs. ORDER ASC exec time

2004-03-29 Thread Vadim P.
Hi all, Just noticed that a simple query that returns only 14 rows is 10X slower when ORDER .. DESC is used compared to ORDER .. ASC. The table has about 700,000 records, indexed on the field the table is being ordered by. Is this expected behavior? MySQL 4.0.18 running under OpenBSD 3.4

Re: ORDER DESC vs. ORDER ASC exec time

2004-03-29 Thread Vadim P.
- From: Donny Simonton To: 'Vadim P.' ; [EMAIL PROTECTED] Sent: Monday, March 29, 2004 9:34 PM Subject: RE: ORDER DESC vs. ORDER ASC exec time Personally, it's an unexpected flaw that I hope one day will be fixed. But I'm not holding my breath, even though they seem to be planning

Re: High load with a few queries

2004-03-29 Thread Vadim P.
Chris, I would consider loading this script only once and establishing a single connection to the DB server and then making it loop with a time delay waiting for data to be inserted into the DB - that's pretty much what it does, right? The thing is that if you invoke the script every time you

Re: ORDER DESC vs. ORDER ASC exec time

2004-03-29 Thread Vadim P.
tried. So maybe something is making DISTINCT + reverse index scan slow even if it's not packed... Matt - Original Message - From: Vadim P. Sent: Monday, March 29, 2004 8:15 PM Subject: ORDER DESC vs. ORDER ASC exec time Hi all, Just noticed that a simple query that returns only 14 rows

Re: strange fulltext behavior

2002-05-22 Thread Vadim P.
| | 2515123714 | | 1988112201 | | 1988112201 | ++ 5 rows in set (0.08 sec) Regards, Vadim P. Victoria Reznichenko wrote: Przemyslaw, Wednesday, May 22, 2002, 2:02:52 AM, you wrote: PP SELECT ISBN,TITLE FROM tBooks PP WHERE tBooks.ISBN=1876340436 PP AND MATCH

Re: Bug in fulltext search in latest mysql-4.0.2 source

2002-05-16 Thread Vadim P.
Sergei Golubchik wrote: rebuild your indexes (the proper way to do it is to issue REPAIR table_name USE_FRM Sergei, would ALTER TABLE.. DROP INDEX.. ADD FULLTEXT... do the same trick? TIA, Vadim. /* sql, mysql to satisfy the spam police */

Re: MySQL load problems - gcc-2.96?

2002-05-13 Thread Vadim P.
Mike, what kind of problem? What exactly goes wrong with PHP4? Thanks, Vadim Mike Robinson wrote: I am able to reproduce this problem very easily, including on Redhat-7.2. Basically, any app using the libmysqlclient.so compiled with gcc-2.96 connecting to a server compiled with gcc-2.96

Re: MySQL load problems - gcc-2.96?

2002-05-13 Thread Vadim P.
Mike, BTW, have you been able to build Mysql 4.0 under RH7.x from the development tree lately? I keep getting some missing definitions messages as of last week, when I performed a regular 'bk resync'. Prior to that, all had been just fine. TIA, Vadim P. Mike Robinson wrote: Hello to all

Re: Help! Error building 4.0.2 under RH Linux 7.2

2002-05-10 Thread Vadim P.
/60.25.75 http://www.scnoorderwijk.be http://crashke.no-ip.biz -Oorspronkelijk bericht- Van: Vadim P. [mailto:[EMAIL PROTECTED]] Verzonden: donderdag 9 mei 2002 23:07 Aan: [EMAIL PROTECTED] Onderwerp: Re: Help! Error building 4.0.2 under RH Linux 7.2 Just tried building Mysql-3.x.x

Help! Error building 4.0.2 under RH Linux 7.2

2002-05-09 Thread Vadim P.
The Dev. Tree Source MySQL 4.0 no longer builds on this machine, giving lots of errors. Had been able to build from the same source w/o any problems up until a few days ago, when I 'bk resync'ed the source. Any ideas? Thanks for your help!

Re: Help! Error building 4.0.2 under RH Linux 7.2

2002-05-09 Thread Vadim P.
Just tried building Mysql-3.x.x cloned from the Development Tree on the same machine - works like a charm. Still no luck with 4.0.2 Is there any known issue regarding building 4.0.2 under RedHat7.2? Thanks, Vadim. Vadim P. wrote: The Dev. Tree Source MySQL 4.0 no longer builds

FULLTEXT search pattern syntax

2002-05-06 Thread Vadim P.
Hi, It's not quite clear from the manual, but it appears that queries with FULLTEXT search patterns like this: MATCH (some_text_field) AGAINST ('(red pepper) (green bean)') don't produce the result desired, that is, multiple .. elements are not allowed, with or without parentheses... Could

Re: FULLTEXT search pattern syntax

2002-05-06 Thread Vadim P.
Of course, I forgot to mention 'IN BOOLEAN MODE'. ... MATCH (some_text_field) AGAINST ('(red pepper) (green bean)' IN BOOLEAN MODE) ... Vadim P. wrote: Hi, It's not quite clear from the manual, but it appears that queries with FULLTEXT search patterns like this: MATCH

Re: FULLTEXT search pattern syntax

2002-05-06 Thread Vadim P.
! On May 06, Vadim P. wrote: Hi, It's not quite clear from the manual, but it appears that queries with FULLTEXT search patterns like this: MATCH (some_text_field) AGAINST ('(red pepper) (green bean)') don't produce the result desired, that is, multiple .. elements are not allowed

Re: FULLTEXT search with hyphens in data

2001-09-04 Thread Vadim P.
Just a thought - if your serial numbers have fixed format, then programmatically remove the hyphen and store the number without it. Add it back when displaying data on the screen. That way FULLTEXT will work on the whole number without splitting it into two parts. Vadim. Marty McCoy wrote:

Re: Looks like any user can read the mysql db!

2001-08-15 Thread Vadim P.
Jose-- Are you running mysqld as 'root'? Run it as 'mysql' and change the group membership of the data directory and its contents to 'mysql'. Vadim. Jose de Leon wrote: Here are the perms on the mysql db files /var/lib/mysql/mysql Also, I was logged into mysql with a plain user 'jose'

Re: WHERE OR Syntax

2001-05-16 Thread Vadim P.
Put parentheses around the ..OR.. part (between WHERE and AND) - AND precedes OR so Also, use 'IN' instead of a series of 'OR' - this will make the query a lot faster. e.g. listings.Area IN ('19','24','25',...) Vadim. JD Daniels wrote: I have this query built from a web form. The form

Re: Help with MATCH AGAINST

2001-05-11 Thread Vadim P.
$SQL = SELECT * FROM cvtemplate WHERE employment_type = '$employment_type' AND location = '$location' AND related_discipline = '$related_discipline', MATCH specific_work_profile, wxcdone, wxcdtwo, wxcdthree, wxcdfour AGAINST ('$keywords') AS score FROM cvtemplate HAVING score!=0 ORDER BY

Re: How long should sql-bench/run-all-tests take?

2001-05-10 Thread Vadim P.
Patrick-- yes, it might take hours, nothing wrong with your setup. Vadim. Patrick Goetz wrote: I recently installed MySQL 2.23.37 from the unstable Debian package on a dual-processor PII 350 w/ 128MB SDRAM running linux 2.4.2 For fun (since I've never tried running any of the

Re: max FULLTEXT index size?

2001-05-03 Thread Vadim P.
Sergei, I also have the same problem, but in my case the table size exceeds 2Gb, average record size being around 50Kb. I'm running 3.23.37 (i686) on a dual PIII 866/ 1Gb RAM / 36Mb SCSI RAID5 w/ RedHat 7.1 (kernel 2.4). As I type this message, MySQL is still [fulltext-] indexing one of the

Re: Database size

2001-05-03 Thread Vadim P.
Erik, You mentioned 40Gig files on Intel platform - what OS/DBMS did you use then? How about the performance? Thanks, Vadim. Terry Katz wrote: Erik, If your running Linux on an Intel machine (which I assume it is), then you've hit Linux's limit for IA32 and 2.2.x kernels .. If you want