Re: Query performance plain/text versus AES_DECRYPT(): LIKE %..%

2007-10-25 Thread John Kraal
Auch, thanks for pointing that out, what a terrible mistake. I am aware of the performance issue, and so is the customer. But with a table that's only going to hold maximally 60.000 records in 10 years, I'm not afraid it'll cause significant problems. If it gets out of hand we'll have to

Re: Query performance plain/text versus AES_DECRYPT(): LIKE %..%

2007-10-24 Thread John Kraal
I put it here: http://pro.datisstom.nl/tests/bench.tar.bz2 The encryption isn't really a *real* security measure, except for when somebody is stupid enough to install phpMyAdmin or anything equivalent and try to get personal data. The problem is the password needs to be anywhere on the

Re: Query performance plain/text versus AES_DECRYPT(): LIKE %..%

2007-10-24 Thread Jeremy Cole
Hi John, OK, no conspiracy here. Here is your problem: 25 $qry = sprintf(SELECT id, line FROM `encryptietest` WHERE AES_DECRYPT(`field`, '%') LIKE '%%%s%%', $enckey, $word); You are missing the s in %s for your first string argument, which causes the query to be syntactically

RE: Query performance plain/text versus AES_DECRYPT(): LIKE %..%

2007-10-23 Thread Jerry Schwartz
Have you tried reversing the order of your tests, to see if there is some influence from caching? Regards, Jerry Schwartz The Infoshop by Global Information Incorporated 195 Farmington Ave. Farmington, CT 06032 860.674.8796 / FAX: 860.674.8341 www.the-infoshop.com www.giiexpress.com

Re: Query performance plain/text versus AES_DECRYPT(): LIKE %..%

2007-10-23 Thread John Kraal
Yes, I did, and shutdowns between the tests and between reversing the tests. -- / Humanique / Webstrategie en ontwikkeling / http://www.humanique.com/ - Humanique zoekt een ervaren Web-ontwikkelaar (PHP). Bekijk de vacature op http://www.humanique.com/ - Jerry Schwartz wrote: Have you tried

Re: Query performance plain/text versus AES_DECRYPT(): LIKE %..%

2007-10-23 Thread Jeremy Cole
Hi John, Your attachment for the php code got stripped somewhere. Can you post it somewhere (http preferable)? In either case it's going to result in a full table scan, so they are actually both a bad strategy long term, but they should in theory perform as you would expect, with with

Re: Query performance.

2006-06-07 Thread Eugene Kosov
Thanks a lot!! :D You were right. There was a bug. Upgrading to mysql 4.1.20 solved my problem. Daniel da Veiga wrote: Check http://bugs.mysql.com/bug.php?id=12915 -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:

Re: Query performance.

2006-06-06 Thread Daniel da Veiga
On 6/6/06, Eugene Kosov [EMAIL PROTECTED] wrote: Hi, List! I'm a little bit confused with (IMHO) poor query performance. I have a table with 1'000'000 records. Table consists of 2 service fields and a number of data fields. Service fields are status and processor_id (added for concurrent

Re: Query performance...two table design options

2005-05-27 Thread Roger Baklund
James Tu wrote: Hi: Let's say I want to store the following information. Unique ID - INT(10) autoincrement First Name - VARCHAR (25) Last Name - VARCHAR (25) Age - INT(3) In general 'age' is a bad column, because you need to know what year the data was entered to calculate the current age.

RE: Query Performance

2005-04-14 Thread Mike Johnson
From: Fernando Henrique Giorgetti [mailto:[EMAIL PROTECTED] Hi Folks! Here, I have the following table: CREATE TABLE `accesses` ( `time` varchar(15) NOT NULL default '', `duration` int(10) default NULL, `user` varchar(25) NOT NULL default '', `ipaddr` varchar(15) NOT NULL

RE: Query Performance

2005-04-14 Thread Mike Johnson
From: Fernando Henrique Giorgetti [mailto:[EMAIL PROTECTED] Hi Folks! Here, I have the following table: CREATE TABLE `accesses` ( `time` varchar(15) NOT NULL default '', `duration` int(10) default NULL, `user` varchar(25) NOT NULL default '', `ipaddr` varchar(15) NOT NULL

Re: Query Performance

2005-04-14 Thread SGreen
Fernando Henrique Giorgetti [EMAIL PROTECTED] wrote on 04/14/2005 02:34:30 PM: Hi Folks! Here, I have the following table: CREATE TABLE `accesses` ( `time` varchar(15) NOT NULL default '', `duration` int(10) default NULL, `user` varchar(25) NOT NULL default '', `ipaddr`

Re: Query Performance

2005-04-14 Thread Andrew Braithwaite
You could probably save a bit of processing time by changing: concat(date_format(from_unixtime(time), %d/%m/%Y), - , time_format(from_unixtime(time), %H:%i)) to: date_format(from_unixtime(time), %d/%m/%Y - %H:%i) This would mean half the date conversions would be executed. Separating out the

Re: query performance

2005-02-17 Thread Coz Web
If you do I suggest you also include relevant table definitions and possibly a little sample data (plus an indication of total table sizes) and expected output, this will greatly assist anyone who my be able to help. Oh yes, and don't forget to state the version of MySQL you are running. Coz On

Re: query performance

2004-01-23 Thread mos
At 07:10 PM 1/23/2004, Larry Brown wrote: I have a db that had some 20,000 records or so in it. I have a query to find out how many jobs have been input during the current day. To add them I ran the following query... select count(idnumber) from maintable where inputdatetime '$date 00:00:00'

RE: Query performance

2003-09-19 Thread Jennifer Goodie
2 index on this table: - one unique index on user_id and att_id (pk) - one index on att_id and user_id. I need to have the following query: select value from user_att where att_id = ? and value like '?' (no wildcard) 1. when I do a explain, this query use the second index. But, if I