Re: Help with query using IN()

2005-10-05 Thread Felix Geerinckx
On 04/10/2005, Jasper Bryant-Greene wrote: Kishore Jalleda wrote: Could you kindly advice if this query can be made to run faster SELECT title, template FROM template WHERE templateid IN (608,2072,2073,1888,1898,1895,1897,1894,1896,1901,1903,1889,1900,189

Re: deleting unwanted rows

2005-10-05 Thread Merlin
[EMAIL PROTECTED] wrote: Merlin [EMAIL PROTECTED] wrote on 10/04/2005 10:58:21 AM: [EMAIL PROTECTED] wrote: Merlin [EMAIL PROTECTED] wrote on 10/04/2005 10:21:00 AM: Hi there, I just discovered, that I do have some old rows I do not need anymore. A result from

Cursors in 5.0.13

2005-10-05 Thread Rob Hall
Having a few problems using cursors in 5.0.13 and I don't know wether it's an 'operator error' :) Should this work? DECLARE cur1 CURSOR FOR SELECT DISTINCT name,addr1,addr2,addr3,addr4,addr5,town,county,postcode,telephone FROM extended WHERE centre_name != ; The DISTINCT in the SELECT

Re: Slow Query Performance

2005-10-05 Thread Harini Raghavan
Hi Green, Scrubbing out the data is a great suggestion, I will definitely try that out. I did try out the other option using REGEXP instead of matching individual conditions. It definitely cleaned up the implementation, but did not really improve the performance. -Harini [EMAIL PROTECTED]

Re: Slow Query Performance

2005-10-05 Thread Harini Raghavan
Hi Brent, Using REGEXP did not really help with the performance. I need to do whole word matching sowould prefer not to do LIKE '%Vice President%' as it may return ome negative results. I separated out some of the text based columns in to a different table using MYISAM storage engine. Using

variable table names in queries ...

2005-10-05 Thread C.R. Vegelin
Hi, I am looking for a method to use variable table names. I have various download-tables, all having the same structure. All I want is to run a series of queries on each of these tables. I tried SET @mytable = 'Download200501'; SELECT count(*) FROM @mytable; but this doen't work. Is there any

Re: 2 Bugs

2005-10-05 Thread Remo Tex
1) that's common problem when doing custom install on PATH containing spaces like C:\Program Files. Solution - try custom location with short(er) path and without spaces like C:\mysql5013\. Probably that will solve problem 2. if not then.. 2. Edit my.ini looking for skip-innodb or related

Re: variable table names in queries ...

2005-10-05 Thread Jigal van Hemert
C.R. Vegelin wrote: Hi, I am looking for a method to use variable table names. I have various download-tables, all having the same structure. All I want is to run a series of queries on each of these tables. I tried SET @mytable = 'Download200501'; SELECT count(*) FROM @mytable; but this

Re: 2 Bugs

2005-10-05 Thread Remo Tex
...and 3. Are you running another instance of mysql? Then perhaps both compete for same resource(s) like: port 3306 ;-) Remo Tex wrote: 1) that's common problem when doing custom install on PATH containing spaces like C:\Program Files. Solution - try custom location with short(er) path and

Re: 2 Bugs

2005-10-05 Thread Jigal van Hemert
Remo Tex wrote: 1) that's common problem when doing custom install on PATH containing spaces like C:\Program Files. Solution - try custom location with short(er) path and without spaces like C:\mysql5013\. Probably that will solve problem 2. if not then.. Remo Tex, That is not a good excuse

RE: JBoss queries aren't cached by MySQL

2005-10-05 Thread Al Caponi
Hi All, I didn't see any follow-up on this thread. Hope I can get some hint :) How to get the query cache to work with Jboss? I've got my app running on the following JBoss 3.2.2. (Unable to upgrade right now) MySQL 4.0.20d mysql-connector-java-3.1.10-bin.jar I have switched on the query_cache

RE: JBoss queries aren't cached by MySQL

2005-10-05 Thread Al Caponi
Hi again, It seems that the problem is solved with MySQL 4.1 (and later?). See a posting from the Jboss forum: http://www.jboss.org/index.html?module=bbop=viewtopicp=3830750#3830750 Cheers, Al -Original Message- From: Al Caponi [mailto:[EMAIL PROTECTED] Sent: Wednesday, October 05,

Re: 2 Bugs

2005-10-05 Thread Remo Tex
Philippe HAMEAU wrote: Hi, I noticed 1 bug with 5.0.13rc (win32 msi) : when installing mysql in a custom location (eg c:\program files\easyphp\mysql), 1) the service will not get installed properly 2) mysqld will complain about InnoDB engine not present. Hope this helps. Phil Have you

Find username password on tables

2005-10-05 Thread Scott Purcell
Hello, A while back, I created a database, and performed the following: GRANT ALL ON util_db.* to XXX identified by XXX; Problem is, a year later, I need to find the username and password, so I can write to these tables. Can this be accomplished, I am the root user. Thanks, Scott -- MySQL

Re: Find username password on tables

2005-10-05 Thread Arno Coetzee
Scott Purcell wrote: Hello, A while back, I created a database, and performed the following: GRANT ALL ON util_db.* to XXX identified by XXX; Problem is, a year later, I need to find the username and password, so I can write to these tables. Can this be accomplished, I am the root user.

RE: Find username password on tables

2005-10-05 Thread Sujay Koduri
Username you can get it from the user table in Mysql. But I don't think atleast after MySQL 4.1 there is a way to retrieve paswords in MySQL as it uses its own encryption algo to encrypt passwords. You have to reset(make that passwd field to null in the mysql.user table) and add a new

RE: Find username password on tables

2005-10-05 Thread Jay Paulson
Or if you have any applications that are accessing this database you could look at the config files for it and most likely the password will be there. jay Username you can get it from the user table in Mysql. But I don't think atleast after MySQL 4.1 there is a way to retrieve paswords in

innodb locking

2005-10-05 Thread Tony Leake
Hi, I have a query: UPDATE dbseXyzOrders.tblOrder SET intPoUid = 98 WHERE intOrderUid = 10798 intOrderUid is the primary key There are 25 columns in the table and a further 8 of these have indexes on them. The table is innodb I have just tried to run the above query 3 times and i got the

RE: innodb locking

2005-10-05 Thread Sujay Koduri
Is this happening every time you try this, or it happened first time? Yes you right that INNODB uses row level locks, and the only reason for that error should be that someone else is trying to update the same row. As we can see from the o/p of the show procee list, someone else is also trying to

RE: InnoDB error unable to create temporary file

2005-10-05 Thread Martijn van den Burg
Hi Joerg et all, [snip] You said this is Solaris. AFAIK, Solaris uses the same disk area for /tmp and paging, so the available space for files in /tmp may vary even without files being manipulated. I propose you set TMPDIR to point to some other disk area. We're on Solaris, yes. I

crashes in InnoDB with MySQL 4.1.14

2005-10-05 Thread Devananda
One of our servers which is configured primarily for InnoDB has crashed in the same fashion three times in the past 48 hours. I've been going over the error log, and I would like to know if anyone else has seen similar errors, or can give me some pointers to work out this problem. Here are

RE: innodb locking

2005-10-05 Thread Tony Leake
On Wed, 2005-10-05 at 07:12 -0700, Sujay Koduri wrote: Is this happening every time you try this, or it happened first time? It's not every time but this is not the first. Mostly the query is ok, but I would like to find out why it's happening. Also can you please tell what isolation level are

Re: innodb locking

2005-10-05 Thread Ady Wicaksono
I have ever meet this problem, however i never found best solutions. Make sure that there're no other session that update the data with AUTOCOMMIT=0 If there's another session with autocommi=0 and update the data, kill it first so your session will not timeout lock use SHOW INNODB STATUS to

Re: Cursors in 5.0.13

2005-10-05 Thread Jeff Smelser
On Wednesday 05 October 2005 04:05 am, Rob Hall wrote: Having a few problems using cursors in 5.0.13 and I don't know wether it's an 'operator error' :) Should this work? when loading a procedure, do show warnings after it.. It tells you what problems its running into.. So what error are

Re: innodb locking

2005-10-05 Thread Ian Sales (DBA)
Tony Leake wrote: Hi, I have a query: UPDATE dbseXyzOrders.tblOrder SET intPoUid = 98 WHERE intOrderUid = 10798 intOrderUid is the primary key There are 25 columns in the table and a further 8 of these have indexes on them. The table is innodb I have just tried to run the above query

RE: innodb locking

2005-10-05 Thread Sujay Koduri
Since you are using repeatable read, this should not be a problem. And regarding autocommit=0, I don't think it is playing any role here. From the show processlist, if at all, at the max there were only two processes acting on the row. But still this should not happen as your query should be kept

content of the table deleted. can I recover it?

2005-10-05 Thread afan
Accidentally I deleted a whole content of the table. Since it happened while I was in a testing area (I didn#8217;t do a back up) #8211; no harm done. But, I would like to know is there any chance to recover lost data? Something like Trash can and you can put it back? -afan -- MySQL General

No of records

2005-10-05 Thread Harini Raghavan
Hi, I have implemented pagination for the search functionality in my application. Since I have a lot of data, I thought in memory paging would not be a good option and opted for paging at the database layer. To do this I am retrieving the no of records using the following query and then again

Re: No of records

2005-10-05 Thread Dan Nelson
In the last episode (Oct 05), Harini Raghavan said: I have implemented pagination for the search functionality in my application. Since I have a lot of data, I thought in memory paging would not be a good option and opted for paging at the database layer. To do this I am retrieving the no of

Re: No of records

2005-10-05 Thread SGreen
Harini Raghavan [EMAIL PROTECTED] wrote on 10/05/2005 11:21:26 AM: Hi, I have implemented pagination for the search functionality in my application. Since I have a lot of data, I thought in memory paging would not be a good option and opted for paging at the database layer. To do this I

Re: How to avoid redundancy between PK and indices ?

2005-10-05 Thread Hank
It depends.. if this is your create table statement: CREATE TABLE foo ( a smallint NOT NULL, b smallint NOT NULL, c smallint NOT NULL, d smallint NOT NULL, e smallint NOT NULL, f smallint NOT NULL, PRIMARY KEY (a,b,c,d,e,f) ); Then only one unique index is being created on the

Re: crashes in InnoDB with MySQL 4.1.14 (semaphore wait timeout)

2005-10-05 Thread Devananda
Devananda wrote: One of our servers which is configured primarily for InnoDB has crashed in the same fashion three times in the past 48 hours. I've been going over the error log, and I would like to know if anyone else has seen similar errors, or can give me some pointers to work out this

Re: Running MySQL tests

2005-10-05 Thread Manish Marathe
Hello, Any inputs or information on running MySQL tests under Valgrind, http://valgrind.org . Thanks -Manish On Tue, 2005-10-04 at 14:25 -0700, Manish Marathe wrote: Hello All, I was building mysql after checking out from the bk repository. In that process, while executing mysql tests I

Financial return calculations help please

2005-10-05 Thread Jim Seymour
I have researched repeatedly and cannot find an answer to the following. I need to do something like the following (There is probably an easier way). end_date - start_date = diff / start_date = return for period The table contains 401k investment values. Ideas, pointers, etc.? I am using mysql

Re: No of records

2005-10-05 Thread Harini Raghavan
Hi Green, I tried using SQL_CALC_FOUND_ROWS as suggested by you. I am executing some other queries following the query that has the clause SQL_CALC_FOUND_ROWS. The documentation says in such a case we can save the row count using *|SET @rows = FOUND_ROWS(); |*How can I retrieve this row count

Re: Financial return calculations help please

2005-10-05 Thread Mike Wexler
Jim Seymour wrote: I have researched repeatedly and cannot find an answer to the following. I need to do something like the following (There is probably an easier way). end_date - start_date = diff / start_date = return for period The table contains 401k investment values. Ideas, pointers,

how to list foreign keys

2005-10-05 Thread Operator
HI everybody I'm tryng to find a way to know if a field is a foreign key, by example if I run this describe tablename; in the Key colum I got PRI for the primary key field, somebody know a way to get the foreign keys ? Regards Daniel

RE: how to list foreign keys

2005-10-05 Thread Gordon Bruce
IF you are on 5.0.x you can use INFORMATION_SCHEMA 21.1.13. The INFORMATION_SCHEMA KEY_COLUMN_USAGE Table http://dev.mysql.com/doc/mysql/en/key-column-usage-table.html -Original Message- From: Operator [mailto:[EMAIL PROTECTED] Sent: Wednesday, October 05, 2005 3:02 PM To:

Re: bug report

2005-10-05 Thread Gleb Paharenko
Hello. Please, could you send a more detailed report. Include information about MySQL and operating system versions. See: http://dev.mysql.com/doc/mysql/en/Bug_reports.html You may want to force a recovery. See: http://dev.mysql.com/doc/mysql/en/forcing-recovery.html Pierre-Henry

Re: JBoss queries aren't cached by MySQL

2005-10-05 Thread Gleb Paharenko
Hello. If you can just check your application with the latest release of MySQL (4.1.14 now). Turn on the general log to be sure that MySQL receives unchanged queries and no session variables has been changed. Al Caponi [EMAIL PROTECTED] wrote: Hi All, I didn't see any follow-up on

Re: Slow Query Performance

2005-10-05 Thread Brent Baisley
You're still doing a full table scan with REGEX, so you'll never get it really fast. I was thinking it would be slightly faster because of less comparisons. It's the full table scan and no use of indexes that you want to get away from. Without doing that, the only way to get things faster

compare tables from two systems

2005-10-05 Thread Claire Lee
We have two clusters running the same data independently and saving output to databases on two systems (two hosts) respectively. We need to compare the output each day. Is there an easy way to compare tables from two systems? We are sure the structure of the tables are all the same and we need to

MySQL Administrator on 10.3 Server -HELP

2005-10-05 Thread Andrew stolarz
Hello List, I have installed the mysql database on the osx 10.3 server machine. along with the myodbc connector. I also installed the administrator module, by simply draging it over to the application folder like it says. When I go to launce the application, it does nothing. I tried restarting

Re: compare tables from two systems

2005-10-05 Thread Greg Donald
On 10/5/05, Claire Lee [EMAIL PROTECTED] wrote: We have two clusters running the same data independently and saving output to databases on two systems (two hosts) respectively. We need to compare the output each day. Is there an easy way to compare tables from two systems? We are sure the

Re: compare tables from two systems

2005-10-05 Thread Rhino
- Original Message - From: Claire Lee [EMAIL PROTECTED] To: mysql@lists.mysql.com Sent: Wednesday, October 05, 2005 5:58 PM Subject: compare tables from two systems We have two clusters running the same data independently and saving output to databases on two systems (two hosts)

Re: alter table

2005-10-05 Thread s. keeling
Incoming from Pooly: 2005/10/3, s. keeling [EMAIL PROTECTED]: I'd like to add a bit of history data to a table (who changed a record last, and when it was last changed). Is this the way to do it? [snip] alter table MEMBERS alter CHG_DATE set default CURRENT_DATE btw, you

Easy or not so easy GROUP BY

2005-10-05 Thread Ed Reed
I'm trying to group some sub categories with a concatenated result. I'm trying to get the max sub for each item per month. I think it should be fairly easy but it is kicking my butt. My data looks like this, +++--+ | month | item | sub | +++--+ |

Error Running MySQL tests

2005-10-05 Thread Manish Marathe
Hello all, I checked out the MySQL code and was running tests using mysql-test- run.sh. I keep getting this error: ERROR: /tmp/mysql/mysql-test/var/run/master.pid was not created in 400 seconds; Aborting Any insights, suggestions ? Thank You -Manish -- MySQL General Mailing List For

Re: Encryption for mySQL 3.23

2005-10-05 Thread Jeffrey Goldberg
On Oct 4, 2005, at 4:34 PM, Jeff Pflueger wrote: Where might I find the key so that I can send it along to them? any suggestions on this? The password is what you need to send. The encryption and decryption functions generate a key from the password. Internally, the key that the

RE: Lock wait timeout exceeded

2005-10-05 Thread Jonathan Stockley
Thanks for the help. I finally got to the bottom of the problem. It seems that on Windows, by default, if the network cable is momentarily disconnected, Windows shuts down all TCP connection within the box and basically disables the the network interface. However the MySQL server running on

Re: How to avoid redundancy between PK and indices ?

2005-10-05 Thread C.R. Vegelin
Hi Hank, You are quite right. I need separate non-unique indices on a, b, c, d, e and f to avoid table scans. And when each combi must be unique I need a Primary Key (a,b,c,d,e,f). And only Key a (a) seems to be redundant with the primary key ... Suppose there would be a PK (a,b,c,d,e,f)

RE: JBoss queries aren't cached by MySQL

2005-10-05 Thread Al Caponi
Hi Gleb All, Thanks for replying. I saw a posting on Jboss forum that suggested upgrading MySQL to 4.1 and above (See my previous posting - http://lists.mysql.com/mysql/189988) I tried both MySQL 4.1.14 and 5.0.13-rc but it didn't work for me :( Still diggin... :) Thanks, Alain -Original

Re: MySQL Administrator on 10.3 Server -HELP

2005-10-05 Thread Adam Randall
Did you drag it from a network drive, or copy in some other way? If so, that may be the problem. I haven't used the MySQL Administrator, but am pretty well versed in application troubleshooting. Send me an email privately if you need some direct help. Adam. -- Adam Randall [EMAIL

Help !!!!

2005-10-05 Thread System administrator
Please help to compile !!! My system is Solaris 5.9 i`m instal OpenSSl and now i wish compile MySQL with him : ./configure --prefix=/opt/mysql --with-mysqld-user=mysql --with-openssl --with-openssl-includes=/usr/local/ssl/include --with-openssl-libs=/usr/local/ssl/lib --with-extra-charsets=complex

Re: crashes in InnoDB with MySQL 4.1.14 (semaphore wait timeout)

2005-10-05 Thread Heikki Tuuri
Deva, please post the complete output except the transaction data. Regards, Heikki - Original Message - From: Devananda [EMAIL PROTECTED] Newsgroups: mailing.database.myodbc Sent: Wednesday, October 05, 2005 7:05 PM Subject: Re: crashes in InnoDB with MySQL 4.1.14 (semaphore wait