SQL and PHP: Incorrect errorcode
Hello folks, I was playing around with my PHP code that shall report any SQL error. To test this code I made an error in a SQL query by changing the table name in the field list to a table that did not exist. This triggered the following error: Error message: 'Unknown table 'q' in field list' Error code: 1109 The error message is correct, but the problem is that the error code (returned by mysql_errno) is not correct. A 'perror 1109' say Illegal error code: 1109. It seems like the error number returned by mysql_errno is not to be trusted, or? Any comments? -- Jørn Dahl-Stamnes homepage: http://www.dahl-stamnes.net/dahls/ -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: MySQL Daylight Savings Time Patch - easy check
- Original Message - *From:* Ryan Stille [EMAIL PROTECTED] *To:* mysql@lists.mysql.com *Date:* Sat, 24 Feb 2007 15:28:25 -0600 Ryan Stille wrote: Paul DuBois wrote: At 4:40 PM -0600 2/20/07, Ryan Stille wrote: Is there an easy way to test to see if MySQL already has the proper tables loaded? -Ryan Yes, reload them. :-) After that, they're current! ... After digging around on the net for a while I found an easy way to tell if your MySQL installation is ready for the new daylight savings time. SELECT UNIX_TIMESTAMP('2007-03-11 02:00:00'), UNIX_TIMESTAMP('2007-03-11 03:00:00'); This should return the same value, even though you are feeding it different times, because this is when the 1 hr change occurs. I get the correct result on both of my machines. On one of them I've run the suggested |mysql_tzinfo_to_sql command, on the other, the time zone tables are completely empty! Any wisdom on these time zone tables - are they ever used, should I populate them or not? -Ryan This may depend on where you live? I tried your select above and got two different answers. Trying: SELECT UNIX_TIMESTAMP('2007-03-25 01:00:00'), UNIX_TIMESTAMP('2007-03-25 02:00:00'); which is when BST sets in in the UK (where I am), gave me identical answers. My 2 cents-worth Terry www.confexdb.co.uk | -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED] -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Qustion
Bonjour ; Je suis un étudiant en fin de cycle. Dans le cadre de mon projet de fin détude, je devais transférer une base de données sous Access à MySQL. Jai effectué le transfère par Excel Mais jai trouvé un problème ; les tables de MySQL ont une taille Limitée à 2048 KO et celles que je désire transférer dépassent cette dernière. Veuillez m'informer s'il y a possibilité de modifier cette taille et dans le cadre de possible, me proposer une méthode de transfère. Merci. - Découvrez une nouvelle façon d'obtenir des réponses à toutes vos questions ! Profitez des connaissances, des opinions et des expériences des internautes sur Yahoo! Questions/Réponses.
How to compile mysql with ut8?
Hello everyone, I'm new to this list, so I hope that this is the right one for this question. My system runs on Debian sarge with Apache2 and mysql-server-5.0 installed with apt-get, the mysql package comming from the dotdeb backdoor. My server is going to host a forum that is actually on a server with mysql set to utf8. On my server all was left to default settings, which is latin1 in my case. On the server where the forum is at the moment I have only got access with phpmyadmin and if I ask phpmyadmin to convert (with iconv) it gives off errors about illegal characters. So the only solution was to change mysql to utf8 which I did and the restauration of the phpmyadmin dump of the forum's database was a success. To change mysql to utf8 I added the following lines to my.cnf : under [mysqld] default-character-set=utf8 and under [client] default-character-set=utf8 However I have got proftpd and postfix which both need to be able to connect to mysql and in my syslog I get this : Character set 'utf8' is not a compiled character set and is not specified in the '/usr/share/mysql/charsets/Index' file It's true that I do not have a utf8 file in /usr/share/mysql/charsets/ So now I have to somehow compile mysql with UTF8. I have set my system locales to utf8 and tried reinstalling mysql : apt-get install mysql-server-5.0 but this does not help. With mysql set to latin1 all works fine as latin1 is included in /usr/share/mysql/charsets/ So my question is how can I do this ? Thanks in advance ! -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Qustion
What a fu...? On 2/24/07, nessah arezki [EMAIL PROTECTED] wrote: Bonjour ; Je suis un étudiant en fin de cycle. Dans le cadre de mon projet de fin d'étude, je devais transférer une base de données sous Access à MySQL. J'ai effectué le transfère par Excel Mais j'ai trouvé un problème ; les tables de MySQL ont une taille Limitée à 2048 KO et celles que je désire transférer dépassent cette dernière. Veuillez m'informer s'il y a possibilité de modifier cette taille et dans le cadre de possible, me proposer une méthode de transfère. Merci. - Découvrez une nouvelle façon d'obtenir des réponses à toutes vos questions ! Profitez des connaissances, des opinions et des expériences des internautes sur Yahoo! Questions/Réponses.
Re: Qustion
S/he is asking how to transcend a 2G table size limit. Nessah, file size limits are usually due to the operating system. I think Windows FAT32 systems impose a 2G limit. PB - Juan Eduardo Moreno wrote: What a fu...? On 2/24/07, nessah arezki [EMAIL PROTECTED] wrote: Bonjour ; Je suis un étudiant en fin de cycle. Dans le cadre de mon projet de fin d'étude, je devais transférer une base de données sous Access à MySQL. J'ai effectué le transfère par Excel Mais j'ai trouvé un problème ; les tables de MySQL ont une taille Limitée à 2048 KO et celles que je désire transférer dépassent cette dernière. Veuillez m'informer s'il y a possibilité de modifier cette taille et dans le cadre de possible, me proposer une méthode de transfère. Merci. - Découvrez une nouvelle façon d'obtenir des réponses à toutes vos questions ! Profitez des connaissances, des opinions et des expériences des internautes sur Yahoo! Questions/Réponses. No virus found in this incoming message. Checked by AVG Free Edition. Version: 7.1.412 / Virus Database: 268.18.4/702 - Release Date: 2/25/2007 No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.412 / Virus Database: 268.18.4/702 - Release Date: 2/25/2007 -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Qustion (translated)
Juan Eduardo Moreno a écrit : What a fu...? On 2/24/07, nessah arezki [EMAIL PROTECTED] wrote: Bonjour ; Je suis un étudiant en fin de cycle. Dans le cadre de mon projet de fin d'étude, je devais transférer une base de données sous Access à MySQL. J'ai effectué le transfère par Excel Mais j'ai trouvé un problème ; les tables de MySQL ont une taille Limitée à 2048 KO et celles que je désire transférer dépassent cette dernière. Veuillez m'informer s'il y a possibilité de modifier cette taille et dans le cadre de possible, me proposer une méthode de transfère. Merci. - Découvrez une nouvelle façon d'obtenir des réponses à toutes vos questions ! Profitez des connaissances, des opinions et des expériences des internautes sur Yahoo! Questions/Réponses. hi I'll translate this for you :) (just keeping to the essential though ... as this question has nothind to do with me ;) ) Translation is : I need to transfer a database from Access to Mysql. I did this but had a problem, the mysql tables are limited to 2048kb, and the ones that I need to transfer are bigger than this. How can I set mysql to accept bigger tables than 2048kb if this is possible of course. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Qustion
Peter Brawley a écrit : S/he is asking how to transcend a 2G table size limit. Nessah, file size limits are usually due to the operating system. I think Windows FAT32 systems impose a 2G limit. PB - Juan Eduardo Moreno wrote: What a fu...? On 2/24/07, nessah arezki [EMAIL PROTECTED] wrote: Bonjour ; Je suis un étudiant en fin de cycle. Dans le cadre de mon projet de fin d'étude, je devais transférer une base de données sous Access à MySQL. J'ai effectué le transfère par Excel Mais j'ai trouvé un problème ; les tables de MySQL ont une taille Limitée à 2048 KO et celles que je désire transférer dépassent cette dernière. Veuillez m'informer s'il y a possibilité de modifier cette taille et dans le cadre de possible, me proposer une méthode de transfère. Merci. - Découvrez une nouvelle façon d'obtenir des réponses à toutes vos questions ! Profitez des connaissances, des opinions et des expériences des internautes sur Yahoo! Questions/Réponses. No virus found in this incoming message. Checked by AVG Free Edition. Version: 7.1.412 / Virus Database: 268.18.4/702 - Release Date: 2/25/2007 No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.412 / Virus Database: 268.18.4/702 - Release Date: 2/25/2007 Hi 2048 KO = 2048Kb = 2Mb not 2 Gb ! -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: SQL and PHP: Incorrect errorcode
Joern, is the client version of mysql in PHP the same as your client libs on the server (where you run perror)? PHP is often times compiled with its own mysql libs and you have to specifically tell PHP to build with the system mysql libs if you want to. Just a thought. Atle On Sun, 25 Feb 2007, Jørn Dahl-Stamnes wrote: Hello folks, I was playing around with my PHP code that shall report any SQL error. To test this code I made an error in a SQL query by changing the table name in the field list to a table that did not exist. This triggered the following error: Error message: 'Unknown table 'q' in field list' Error code: 1109 The error message is correct, but the problem is that the error code (returned by mysql_errno) is not correct. A 'perror 1109' say Illegal error code: 1109. It seems like the error number returned by mysql_errno is not to be trusted, or? Any comments? -- Jørn Dahl-Stamnes homepage: http://www.dahl-stamnes.net/dahls/ -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Mysql on linux - choosing the right filesystem
On 2/24/07, Jean-Sebastien Pilon [EMAIL PROTECTED] wrote: Hello, I would like to get some of your input on file systems to use with mysql. Should I use a journaling filesystem ? Should I choose a different one based on what I store (log files, myisam dbs, innodb datafiles, etc ) ? Is there any file system tweaks you recommend ? TIA NOTICE: This email contains privileged and confidential information and is intended only for the individual to whom it is addressed. If you are not the named addressee, you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately by e-mail if you have received this transmission by mistake and delete this communication from your system. E-mail transmission cannot be guaranteed to be secured or error-free as information could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or contain viruses. AVIS: Le présent courriel contient des renseignements de nature privilégiée et confidentielle et n'est destiné qu'à la personne à qui il est adressé. Si vous n'êtes pas le destinataire prévu, vous êtes par les présentes avisés que toute diffusion, distribution ou reproduction de cette communication est strictement interdite. Si vous avez reçu ce courriel par erreur, veuillez en aviser immédiatement l'expéditeur et le supprimer de votre système. Notez que la transmission de courriel ne peut en aucun cas être considéré comme inviolable ou exempt d'erreur puisque les informations qu'il contient pourraient être interceptés, corrompues, perdues, détruites, arrivées en retard ou incomplètes ou contenir un virus. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED] -- Founder/CEO Tailrank.com Location: San Francisco, CA AIM/YIM: sfburtonator Skype: burtonator Blog: feedblog.org Cell: 415-637-8078
Really worried about DELETE statement
Would someone please check this delete query? This should delete all rows from the geodesic_user_data that have no match in the subscriber table, but another set of eyes would be appreciated. DELETE geodesic_user_data FROM geodesic_user_data LEFT JOIN subscriber ON geodesic_classifieds_userdata.id=subscriber.GeoClassID WHERE subscriber.GeoClassID IS NULL; Our hosting company uses MySQL 4.0.17 so the subquery approach is not possible. Thanks in advance - Miles -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.412 / Virus Database: 268.18.3/700 - Release Date: 2/24/2007 -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Really worried about DELETE statement
At 06:13 PM 2/25/2007, Miles Thompson wrote: Would someone please check this delete query? This should delete all rows from the geodesic_user_data that have no match in the subscriber table, but another set of eyes would be appreciated. DELETE geodesic_user_data FROM geodesic_user_data LEFT JOIN subscriber ON geodesic_classifieds_userdata.id=subscriber.GeoClassID WHERE subscriber.GeoClassID IS NULL; Our hosting company uses MySQL 4.0.17 so the subquery approach is not possible. Thanks in advance - Miles Miles, It looks fine but you could have checked it yourself using: select * FROM geodesic_user_data LEFT JOIN subscriber ON geodesic_classifieds_userdata.id=subscriber.GeoClassID WHERE subscriber.GeoClassID IS NULL; -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
using contraints on Mysql
Hi. I'm looking for using FIELD CONSTRAINTS on Mysql but I can´t find it ... Doesn´t Mysql implement it?? For example: age int 0 Thanks, RAUL DUQUE Bogotá, Colombia - Do You Yahoo!? La mejor conexión a Internet y 2GB extra a tu correo por $100 al mes. http://net.yahoo.com.mx
Re: using contraints on Mysql
In the last episode (Feb 25), Raúl Andrés Duque Murillo said: I'm looking for using FIELD CONSTRAINTS on Mysql but I can't find it ... Doesn't Mysql implement it?? For example: age int 0 You can do those checks with triggers: http://dev.mysql.com/doc/refman/5.0/en/triggers.html # If a BEFORE trigger fails, the operation on the corresponding row is not performed. -- Dan Nelson [EMAIL PROTECTED] -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
RE: SELECT single row from 2 tables with WHERE clause
Many thanks Peter. That's the definition I was after. Kerry -Original Message- From: Peter K AGANYO [mailto:[EMAIL PROTECTED] Behalf Of Peter K AGANYO Sent: 19 February 2007 00:35 To: [EMAIL PROTECTED] Cc: mysql@lists.mysql.com Subject: Re: SELECT single row from 2 tables with WHERE clause Hi Kerry, Try this: SELECT t1.*,t2.thedescription AS t2desc FROM table1 AS t1 LEFT JOIN table2 AS t2 ON t1.linkfield=t2.linkfield WHERE t1.lookup='Z' Without the WHERE condition this would return all 1000 rows of table 1 since A Left join returns all rows of the left of the conditional even if there is no right column to match. but t1.lookup='Z' constrains this to only the one row of table one with lookup equal to 'Z'. Enjoy Peter On 2/17/07, Kerry Frater [EMAIL PROTECTED] wrote: I am trying to select a particular row from a table and include a column for aq second table but I cannot get the result I am after. I have table1 with 1000 rows and table2 with 12 rows. The relationship between the tables is a column linkedfield. Table1 has a unique key called lookup If I use the code SELECT t1.*,t2.thedescription AS t2desc FROM table1 AS t1, table2 AS t2 where (t1.lookup='Z') I get a result of 12 rows (as expected) SELECT t1.*,t2.thedescription AS t2desc FROM table1 AS t1, table2 AS t2 where (t1.linkfield=t2.linkfield) I get 1000 rows as expected SELECT t1.*,t2.thedescription AS t2desc FROM table1 AS t1, table2 AS t2 where (t1.lookup='Z') and (t1.linkfield=t2.linkfield) returns 1 row if there is an active link between the two tables and returns 0 rows if there isn't. This is where I am stuck. In the last example I would like the 1 row whether there is an active link or not. The difference will be simply that the t2desc rsulting column will be blank or contain a value. Can anyone help me with the logic? Kerry