Re: Checking for good update

2006-03-13 Thread mysql
On Sun, 12 Mar 2006, Michael Stassen wrote: To: [EMAIL PROTECTED] From: Michael Stassen [EMAIL PROTECTED] Subject: Re: Checking for good update [EMAIL PROTECTED] wrote: looks a bit strange to me. $result = mysql_query($query) or die('Query couldn\'t executed:'.mysql_error());

Re: How to Log Warnings and Errors from queries

2006-03-13 Thread ryan lwf
Hi Rithish, Thank you all for your suggestion, I would definitely give it a shot. Regards, Ryan. On 3/13/06, Rithish Saralaya [EMAIL PROTECTED] wrote: Hello Ryan. I am more of a developer than a MySQL administrator. Hence, I would always favour applications logging query errors rather than

Re: Checking for good update

2006-03-13 Thread Michael Stassen
[EMAIL PROTECTED] wrote: On Sun, 12 Mar 2006, Michael Stassen wrote: [EMAIL PROTECTED] wrote: looks a bit strange to me. $result = mysql_query($query) or die('Query couldn\'t executed:'.mysql_error()); please try something like this: Why? There's nothing wrong with the above

Re: Rollback is not take effect on MySQL 5.0.18

2006-03-13 Thread Pooly
2006/3/11, Truong Tan Son [EMAIL PROTECTED]: Dear Sir, On RedHat Enterprise 4, and MySQL 5.0.18, I did : mysql set autocommit=0; mysql savepoint abc; mysql insert something mysql rollback to save point abc; Query OK, 0 rows affected, 1 warning (0.00 sec)

Re: InnoDB Commit question

2006-03-13 Thread Heikki Tuuri
Rob, - Original Message - From: Rob Brooks [EMAIL PROTECTED] Newsgroups: mailing.database.myodbc Sent: Sunday, March 12, 2006 6:02 PM Subject: InnoDB Commit question --=_NextPart_000_0033_01C645BC.03223720 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding:

Re: Checking for good update

2006-03-13 Thread mysql
Thankyou for that explanation Michael. I shall look into using that construct in my own code now! Apologies to fbsd_user for my previous comments on his coding style. Regards Keith Roberts In theory, theory and practice are the same; In practice they are not. On Mon, 13 Mar 2006, Michael

MySQLMigrationsToolkit ...

2006-03-13 Thread Rafal Kedziorski
Hallo, I'm using MySQL MigrationsToolkit 1.0.23rc and while transfering big Table (MySQL 4.0.x to MySQL 5.x, 4.000.000 entries) I get this message: The SQL create statements could not be created (error: 0). MigrationMysql.dataBulkTransfer :Java heap space Details: What can I do? Best

Re: MySQLMigrationsToolkit ...

2006-03-13 Thread Rafal Kedziorski
At 12:31 13.03.2006, Rafal Kedziorski wrote: Hallo, I'm using MySQL MigrationsToolkit 1.0.23rc and while transfering big Table (MySQL 4.0.x to MySQL 5.x, 4.000.000 entries) I get this message: The SQL create statements could not be created (error: 0). MigrationMysql.dataBulkTransfer :Java

Re: MySQLMigrationsToolkit ...

2006-03-13 Thread Mladen Adamovic
Rafal Kedziorski wrote: The SQL create statements could not be created (error: 0). MigrationMysql.dataBulkTransfer :Java heap space What can I do? That is Java memory related problem. Check out where it invoke the Java VM if possible and add memory parametars like -Xms256m -Xmx900m (it assume

updating federated table affects only one row per request, should update more rows ..

2006-03-13 Thread Sebastian Mork
I try to update multiple rows in a federated table with one query, where field a=x and field b=x.. There are 4 rows that match these criteria (selecting returns 4 rows) but trying to update using the following query updates only one record. calling the same query 4 times, updates only one record

simple query

2006-03-13 Thread Xiaobo Chen
Hi, all I have a table which has a column with time. It's format is like -00-00 00:00:00 (default value). I want to get the minimum and maximum values for this cloumn. Obviously, -00-00 00:00:00 isn't the minimum value I want. What I did for the minimum time, suppose the column name is

Re: simple query

2006-03-13 Thread Diego Ignacio Wald
Hope this helps: select min(ctime), max(ctime) from tbl_a where ctime != -00-00 00:00:00 Best regards, Diego - Original Message - From: Xiaobo Chen [EMAIL PROTECTED] To: mysql@lists.mysql.com Sent: Monday, March 13, 2006 11:17 AM Subject: simple query Hi, all I have a

Re: Compare lists Query?

2006-03-13 Thread Yesmin Patwary
Dear All, I had some issues in past with timestamp fields as a result I am unable to upgrade to mysql 4.1 version. I am sure below the query recommended by Josh works with 4.1 or above. Would it be possible to rewrite this query for 3.23 version? Again, thank you Josh and all others for

mysql5 options file location

2006-03-13 Thread Alex Moore
I am building mysql5 latest from source on Solaris. The location of the options file is very confusing and does not work according to the online documentation. For example, I have --basedir of /opt/csw/mysql5 and --datadir of /opt/csw/mysql5/var. If I put my.cnf in datadir or in basedir, the

Re: Query Optimization Question

2006-03-13 Thread SGreen
Robert DiFalco [EMAIL PROTECTED] wrote on 03/11/2006 12:43:43 PM: In a previous database engine I was using an IN was more optimal than a . So, for example: SELECT * FROM table WHERE table.type IN (1,2,3); Where the possible values of type are 0-3, was appreciably faster than:

Re: Compare lists Query?

2006-03-13 Thread Peter Brawley
Yesmin Patwary wrote: Dear All, I had some issues in past with timestamp fields as a result I am unable to upgrade to mysql 4.1 version. I am sure below the query recommended by Josh works with 4.1 or above. Would it be possible to rewrite this query for 3.23 version? Again, thank

RE: Checking for good update

2006-03-13 Thread fbsd_user
Thank you Michael. I learned a lot from your detailed explanation of how the update and select functions work in relation to checking for good execution. I used if (mysql_affected_rows() == 1) and got the results I was after. I am stilling having problem with users browser caching the screen,

Re: Compare lists Query?

2006-03-13 Thread Josh
You could rotate the output... basically get 1 row with 11 columns (CA01_count,CA02_count,...,CA12_count) (leaving out CA10) joining all 12 tables together... Or... perhaps we can help with the timestamp issues you are having and get you upgraded to later version of mysql that supports nested

Auto increment Primary Index fields in replicated db

2006-03-13 Thread Jeff
All, We are using circular replication now on db's that were originally stand alone. One problem we have is that all the primary index fields for most of the tables are auto increment fields. This prevents us from writing to both db servers because of confilicting INDEX entries. Is there some

Help regarding a simple query

2006-03-13 Thread VenuGopal Papasani
Hi, I am searching for a query where i can have pattern matching without considering the cases.You can consider the following example for detailed description of what i want exactly. Let my table X consists of following data Name --- venu venup venugopla VenugOpal VENU

MySQLMigrationsToolkit 1.0.23rc

2006-03-13 Thread Rafal Kedziorski
hi, after migration from MySQL 4.0.26 to MySQL 5.0.18 I'm missing auto_increment on MySQL 5 side in appropriates tables. Best Regards, Rafal -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]

RE: Help regarding a simple query

2006-03-13 Thread Jeff
-Original Message- From: VenuGopal Papasani [mailto:[EMAIL PROTECTED] Sent: Monday, March 13, 2006 10:33 To: mysql@lists.mysql.com Subject: Help regarding a simple query Hi, I am searching for a query where i can have pattern matching without considering the cases.You can

RE: Query Optimization Question

2006-03-13 Thread Robert DiFalco
Shawn, Any performance gains for specifying type 0 than type 0 ? R. From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Monday, March 13, 2006 6:37 AM To: Robert DiFalco Cc: mysql@lists.mysql.com Subject: Re: Query Optimization Question Robert

RE: Query Optimization Question

2006-03-13 Thread SGreen
Yes, a ranged query should respond faster than a negation. In some cases you can seriously improve query performance for a negation query if you split it into two range queries unioned together. Here is a pseudo example: This query should be slow due to the table scan it takes to test the

RE: Query Optimization Question

2006-03-13 Thread Robert DiFalco
Interesting, that seems like an optimization the query optimizer could do itself when it sees a operator on a indexed numeric. From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Monday, March 13, 2006 8:01 AM To: Robert DiFalco Cc: mysql@lists.mysql.com

Re: Help regarding a simple query

2006-03-13 Thread Peter Brawley
Now i need to get all the records which consists of the string venu(case should not be considered either case should be).i.e i should get 1,2,3,4,5,8 records A simple way is ... ... WHERE LOCATE('venu', col_name ) 0 ... or if the column is [VAR]BINARY, LOCATE('venu',CAST(col_name AS

Re: Auto increment Primary Index fields in replicated db

2006-03-13 Thread Kishore Jalleda
Please refer to these two links, they would give you a clear explaination. there is also an example in the second link which you can easily test . http://dev.mysql.com/doc/refman/5.0/en/replication-auto-increment.html http://dev.mysql.com/doc/refman/5.0/en/server-system-variables.html ( scroll

users browser caching the screen

2006-03-13 Thread fbsd_user
Now I know what I am going to talk about is not directly related to this mysql list, but I am in need of some concept ideas. To set the background. It’s a very common practice in the registration process of a new user to verify the users email address is valid by sending a email to the entered

Can i have query for this

2006-03-13 Thread VenuGopal Papasani
Hi, I am searching for a query where i can have pattern matching without considering the cases.You can consider the following example for detailed description of what i want exactly. Let my table X consists of following data Name --- venu venup venugopla

E/R Tool

2006-03-13 Thread Vinay
Hello , Is there a mysql or any other tool that generates a E/R diagram using an existing mysql database. Thank You Vinay

Problems with timestamp field after upgrading MySQL Server.

2006-03-13 Thread Yesmin Patwary
Dear All, First of all, I would like to thank to Josh and Peter Brawley for their kind help on previous issue. Here is another Issue: There are many tables that have timestamp field with 8 char (mmdd). I use this format all over our website and to create various reports.

Problems with timestamp field after upgrading MySQL Server.

2006-03-13 Thread Yesmin Patwary
Dear All, First of all, I would like to thank to Josh and Peter Brawley for their kind help on previous issue. Here is another Issue: There are many tables that have timestamp field with 8 char (mmdd). I use this format all over our website and to create various reports.

E/R Tool

2006-03-13 Thread Vinay
Hello , Is there a mysql or any other tool that generates a E/R diagram using an existing mysql database. Thank You Vinay

Re: mysql5 options file location

2006-03-13 Thread mysql
Hi Alex. It seems that mysqld and all the client programs insist on reading /etc/my.cnf first. To overide this behaviour for a particular instance of mysqld you need to pass the --defaults-file option as the FIRST parameter to mysqld_safe or mysqld if you are not using mysqld_safe.

RE: Help regarding a simple query

2006-03-13 Thread Jeff
-Original Message- From: VenuGopal Papasani [mailto:[EMAIL PROTECTED] Sent: Monday, March 13, 2006 11:48 To: Jeff Subject: Re: Help regarding a simple query Hi Jeff, This is venu again.Last mail i did not include a constraint that is what irritating me most.Actually if i got venu-kkk

Re: users browser caching the screen

2006-03-13 Thread gerald_clark
fbsd_user wrote: Now I know what I am going to talk about is not directly related to this mysql list, but I am in need of some concept ideas. To set the background. It’s a very common practice in the registration process of a new user to verify the users email address is valid by sending a

socket error

2006-03-13 Thread Jim Douglas
I can connect to mysql with mysql -u dbname -p When I start MySQL Administrator v 1.1.6 it says Could not connect to host 'localhost'. MySQL Error Nr. 2002 Can't connect to local MySQL server through socket '/tmp/mysql.sock' (111) ...then I Click on Details and enter,

Re: E/R Tool

2006-03-13 Thread mysql
http://www.thekompany.com/products/dataarchitect/ There are free evaluation copies to download, and it's not that dear to buy a copy, very good value actually. I'm not sure if there is a free Linux version that theKompany have released as well. Keith In theory, theory and practice are the

Re: socket error

2006-03-13 Thread SGreen
Jim Douglas [EMAIL PROTECTED] wrote on 03/13/2006 12:24:56 PM: I can connect to mysql with mysql -u dbname -p When I start MySQL Administrator v 1.1.6 it says Could not connect to host 'localhost'. MySQL Error Nr. 2002 Can't connect to local MySQL server through socket

DROP DATABASE doesn't actually drop the database?

2006-03-13 Thread Stephen Cook
I am scripting out the creation of a database so I can make changes and then run the script to generate a clean copy (by running it in MySQL Query Browser). The script DROPs all the tables, then CREATEs them again along with all the indices and whatnot. However, if I run the script after having

Re: Problems with timestamp field after upgrading MySQL Server.

2006-03-13 Thread Josh
Sure is... SELECT DATE_FORMAT(dateField,'%Y%m%d') as dateField Take a look at: http://dev.mysql.com/doc/refman/5.0/en/date-and-time-functions.html -Josh --- Yesmin Patwary [EMAIL PROTECTED] wrote: Dear All, First of all, I would like to thank to Josh and Peter Brawley for their kind

Re: Problems with timestamp field after upgrading MySQL Server.

2006-03-13 Thread SGreen
Alternatively, you might be able to re-render times and dates in their condensed format by auto-converting them to a numeric value. Try adding zero to your date columns in your select clauses. Once condensed, your substring code should begin working as before. SELECT datecol +0 as datecol

timestamp

2006-03-13 Thread fbsd_user
In my mysql 4.4 table definition the default attributes are (ON UPDATE CURRENT_TIMESTAMP). Reading the manual my understanding is this is saying that the auto timestamp update feature is active. The manual does not say what the trigger is to make the timestamp in the row to be bumped to the

Re: timestamp

2006-03-13 Thread SGreen
fbsd_user [EMAIL PROTECTED] wrote on 03/13/2006 01:10:17 PM: In my mysql 4.4 table definition the default attributes are (ON UPDATE CURRENT_TIMESTAMP). Reading the manual my understanding is this is saying that the auto timestamp update feature is active. The manual does not say what the

Re: E/R Tool

2006-03-13 Thread mysql
Excellent DB design tool Peter. Thanks for posting the information. http://www.fabforce.net/dbdesigner4/ I have bookmarked that, and will be checking that out soon! Regards Keith In theory, theory and practice are the same; In practice they are not. On Mon, 13 Mar 2006, Peter M. Groen

Re: E/R Tool

2006-03-13 Thread Peter M. Groen
On Monday 13 March 2006 17:37, Vinay wrote: Hello , Is there a mysql or any other tool that generates a E/R diagram using an existing mysql database. Thank You Vinay Try fabforce for DbDesigner4MySQL. Very good tool. -- Peter M. Groen Open Systems Development Klipperwerf 12 2317 DZ

mysql++1.7.1 vc++6 compile errors

2006-03-13 Thread Keith Lee
Hi I am using visual studio C++ 6, with SDK, my mysql database is 4.1.18, i downloaded mysql++ 1.7.1 as this is the compatiable version for vc++6. the example program compiles and runs. when i go to make my own project i use the wizard and create a basic dialog MFC app. at the top of the main

RE: mysql++1.7.1 vc++6 compile errors

2006-03-13 Thread Jason Teagle
the example program compiles and runs. when i go to make my own project i use the wizard and create a basic dialog MFC app. at the top of the main cpp file i add #include mysql++ and then in the program call Connection con(login,localhost,root,abc); in the mysql++ download there is many lib

Re: E/R Tool

2006-03-13 Thread Peter Brawley
[EMAIL PROTECTED] wrote: Excellent DB design tool Peter. Thanks for posting the information. http://www.fabforce.net/dbdesigner4/ It has become MySQL Workbench (http://forums.mysql.com/read.php?10,73820,73820#msg-73820), but it isn't production-ready yet. PB -- No virus found in this

mysql++1.7.1 vc++6 compile errors

2006-03-13 Thread Keith Lee
thanks for the reply Jason, i have now added mysql++.lib to the linker and also copyied the libmysql.dll to the system folder. the program complies now with a few performance warnings but no errors. there is one link error LINK : warning LNK4098: defaultlib LIBC conflicts with use of other

Re: mysql++1.7.1 vc++6 compile errors

2006-03-13 Thread Warren Young
Keith Lee wrote: there is one link error LINK : warning LNK4098: defaultlib LIBC conflicts with use of other libs; use /NODEFAULTLIB:library In the settings if i do as it says above, i get over 200 errors!! so i revert back. Visual C++ is very picky about the way programs are built when

Re: DROP DATABASE doesn't actually drop the database?

2006-03-13 Thread Stephen Cook
Thanks for your comments! I ran my entire script (DROP DATABASE and all) with the command-line client, and got no errors. Perhaps there is something with the Query Browser that is causing this problem. I added the IF EXISTS and IF NOT EXISTS in appropriate places (although I can see the

Re: mysql5 options file location

2006-03-13 Thread Alex Moore
On Mon, 13 Mar 2006 16:52:03 + (GMT) [EMAIL PROTECTED] wrote: Hi Alex. It seems that mysqld and all the client programs insist on reading /etc/my.cnf first. To overide this behaviour for a particular instance of mysqld you need to pass the --defaults-file option as the FIRST

update using 'set' keyword

2006-03-13 Thread fbsd_user
Trying to bump the count_of_logons by 1 using this update. Phpmyadmin shows the count staying at zero. I think that this SET count_of_logons = 'count_of_logons + 1' is not coded correctly, but I get no errors so can not tell. Anybody have any ideas? The table def has count_of_logons

Re: Importing CSV file into MySQL DB - Newbie Question

2006-03-13 Thread sheeri kritzer
Hi Derek, You never gave us a SHOW CREATE TABLE simple1, which would have helped. To replicate your problem, I did the following, on a linux box (it looks like you're using Windows), using mysql 5.0.18-standard-log: CREATE DATABASE cars; use cars; CREATE TABLE `simple1` ( `one` char(10)

Re: E/R Tool

2006-03-13 Thread mysql
OK TY Peter. I have downloaded both DBDesigner and MySQL Workbench. Looking forward to workbench reaching GA status. Regards Keith In theory, theory and practice are the same; In practice they are not. On Mon, 13 Mar 2006, Peter Brawley wrote: To: [EMAIL PROTECTED] From: Peter Brawley

Re: Problem mysql 4.1 to mysql5 -

2006-03-13 Thread sheeri kritzer
Which binary did you use, and where did you download it from? what is the result of uname -a ? are they both 64 bit machines? 32-bit machines? where is libstdc++ on both machines? It's possible one machine has a library linked to another location, or they have them in different locations.

Re: update using 'set' keyword

2006-03-13 Thread Michael Stassen
fbsd_user wrote: Trying to bump the count_of_logons by 1 using this update. Phpmyadmin shows the count staying at zero. I think that this SET count_of_logons = 'count_of_logons + 1' is not coded correctly, but I get no errors so can not tell. Anybody have any ideas? The table def has

Re: Strange problem: Increasing Memory / HEAP Table

2006-03-13 Thread sheeri kritzer
What does SHOW CREATE TABLE give you? -Sheeri On 3/11/06, Holger Sunke [EMAIL PROTECTED] wrote: Hallo, is there a way of maintaining Memory tables or rebuilding indexes? I have a big memory table with about 300k rows, 12 Attributes, 7 BTREE-Indexes and a PRIMARY KEY (Hash index). Now

Re: mysql5 options file location

2006-03-13 Thread mysql
In your global /etc/my.cnf fle, you should be able to split that into sections for each client program that you want to set specific options for. Eg. # /etc/my.cnf # MySQL client program configuration file # last updated 2006-03-05 # mysqld server configuration file lives in #

Re: mysqldump backup on filters

2006-03-13 Thread sheeri kritzer
Replicate your databases to another server, and take your dumps from that, so you can lock your replication slave and take your dumps while your site is still running. As an added bonus, you get a server suitable for manual failover should anything happen to your master database. -Sheeri On

Re: mysql5 options file location

2006-03-13 Thread Alex Moore
On Mon, 13 Mar 2006 23:05:30 + (GMT) [EMAIL PROTECTED] wrote: Exactly what are the problems you are having with the server specific my.cnf file? Sorry, I thought that I had described the problem. A quick example was 'my_print_defaults mysqld' returning only the options defined in the

Re: Rollback is not take effect on MySQL 5.0.18

2006-03-13 Thread Truong Tan Son
Dear Sir, I could not find table of innoDB in mysql. mysql show tables; +--+ | Tables_in_mysql | +---+ | columns_priv | | db | | func | | host | | tables_priv | | user

RE: users browser caching the screen

2006-03-13 Thread fbsd_user
I guess you are saying that trying to have my php script send the users browser html headers to stop caching is not really going to solve my problem. I did put a block rule in my firewall for the attackers ip address and that stopped the attach from recurring. But to make sure it don't happen

Re: Query Optimization Question

2006-03-13 Thread Michael Stassen
Robert DiFalco wrote: In a previous database engine I was using an IN was more optimal than a . So, for example: SELECT * FROM table WHERE table.type IN (1,2,3); Where the possible values of type are 0-3, was appreciably faster than: SELECT * FROM table WHERE table.type 0; I've

Re: mysql5 options file location

2006-03-13 Thread mysql
I get the same results as you do using this: karsites:/usr/local/mysql-5.0.18/bin # ./my_print_defaults mysqld karsites:/usr/local/mysql-5.0.18/bin # ./my_print_defaults client --socket=/var/lib/mysql/mysql.sock --port= karsites:/usr/local/mysql-5.0.18/bin # It seems like the last parameter

Re: Rollback is not take effect on MySQL 5.0.18

2006-03-13 Thread Pooly
2006/3/14, Truong Tan Son [EMAIL PROTECTED]: Dear Sir, I could not find table of innoDB in mysql. Tables in the mysql are MyISAM and should stay that way. Odds are that there is a skip-innodb in your my.cnf on your RHE, and not you XP. what produces a show status ? mysql show tables;