Re: [PHP-DB] mySQL SELECT query

2008-08-29 Thread Evert Lammerts
In the SQL standard this would be AND NOT ministry_directory.listing_approved=0 AND NOT ministry_directory.listing_approved=4 MySQL supports (and there are probably more RDBs that do): AND ministry_directory.listing_approved!=0 AND ministry_directory.listing_approved!=4 On Fri, Aug 29, 2008 at

Re: [PHP-DB] mySQL SELECT query

2008-08-29 Thread Matt Anderton
or NOT IN (0,4) -- matt On Fri, Aug 29, 2008 at 12:19 PM, Evert Lammerts [EMAIL PROTECTED]wrote: In the SQL standard this would be AND NOT ministry_directory.listing_approved=0 AND NOT ministry_directory.listing_approved=4 MySQL supports (and there are probably more RDBs that do): AND

[PHP-DB] Mysql logs

2008-07-23 Thread Manoj Singh
Hi All, Please help me to set the logging on in mysql. I am using the following command when starting mysql: service mysqld start --log=/usr/local/ But logging is not maintained through this command. Best Regards, Manoj Kumar Singh

Re: [PHP-DB] Mysql logs

2008-07-23 Thread Micah Gersten
You have to edit your my.cnf file. Here's a link to the docs: http://dev.mysql.com/doc/refman/5.0/en/log-files.html Thank you, Micah Gersten onShore Networks Internal Developer http://www.onshore.com Manoj Singh wrote: Hi All, Please help me to set the logging on in mysql. I am using the

Re: [PHP-DB] Mysql logs

2008-07-23 Thread Manoj Singh
Hi Micah, Thanks for help. Best Regards, Manoj Kumar Singh On Thu, Jul 24, 2008 at 11:02 AM, Micah Gersten [EMAIL PROTECTED] wrote: You have to edit your my.cnf file. Here's a link to the docs: http://dev.mysql.com/doc/refman/5.0/en/log-files.html Thank you, Micah Gersten onShore

Re: [PHP-DB] MySQL circular buffer

2008-06-21 Thread OKi98
(i.e. stack_id 500 stack_id 601 vs where stack_id = 500 limit 100) stack_id between 501 and 600 (stack_id 500 stack_id 601) is much better What I would like to know is if anybody has experience implementing this sort of data structure in MySQL (linked list?) or any advice. tables:

[PHP-DB] MySQL circular buffer

2008-06-20 Thread Andrew Martin
Hello, I'm looking at implementing a database-level stack for a (multi stack) mail merge queue (able to queue up to 1 million messages per stack). Current workflow: server 1 (containing main db) transmits data sets (used to populate mail merge template) to server 2 server 2 web-facing script

[PHP-DB] MySQL replication delaying issue

2008-02-26 Thread Lasitha Alawatta
Hello Everybody, We have 6 multi-master MySql instances within a LAN , that are replicating is a sequential manner. Server Environment : Six identical Linux Enterprise version 4 running, servers with having MySQL version 6. we are using MySQL multi-master replication method for database

Re: [PHP-DB] MySQL replication delaying issue

2008-02-26 Thread Daniel Brown
On Tue, Feb 26, 2008 at 10:49 AM, Lasitha Alawatta [EMAIL PROTECTED] wrote: Hello Everybody, We have 6 multi-master MySql instances within a LAN , that are replicating is a sequential manner. Server Environment : Six identical Linux Enterprise version 4 running, servers with having MySQL

RES: [PHP-DB] MySQL replication delaying issue

2008-02-26 Thread Thiago Pojda
I did not say: do not ask on this list. I said: you would get BETTER answers if you asked on a MySQL list. _ De: Lasitha Alawatta [mailto:[EMAIL PROTECTED] Enviada em: terça-feira, 26 de fevereiro de 2008 13:47 Para: Thiago Pojda Assunto: RE: [PHP-DB] MySQL replication delaying issue

RES: [PHP-DB] MySQL replication delaying issue

2008-02-26 Thread Thiago Pojda
; [EMAIL PROTECTED]; [EMAIL PROTECTED] Assunto: [PHP-DB] MySQL replication delaying issue Prioridade: Alta Hello Everybody, We have 6 multi-master MySql instances within a LAN , that are replicating is a sequential manner. Server Environment : Six identical Linux Enterprise version 4 running

RE: [PHP-DB] MySQL replication delaying issue

2008-02-26 Thread Lasitha Alawatta
Oky, Sorry for that.. J From: Thiago Pojda [mailto:[EMAIL PROTECTED] Sent: Tuesday, February 26, 2008 8:49 PM To: Lasitha Alawatta Cc: php-db@lists.php.net Subject: RES: [PHP-DB] MySQL replication delaying issue I did not say: do not ask on this list. I said: you would get

RE: [PHP-DB] MySQL replication delaying issue

2008-02-26 Thread Lasitha Alawatta
Hello, Thanks a LOT... Best Regards, Lasitha From: Thiago Pojda [mailto:[EMAIL PROTECTED] Sent: Tuesday, February 26, 2008 9:51 PM To: Lasitha Alawatta Cc: php-db@lists.php.net Subject: RES: [PHP-DB] MySQL replication delaying issue That's ok, good luck with your problem

RES: [PHP-DB] MySQL replication delaying issue

2008-02-26 Thread Thiago Pojda
Assunto: RE: [PHP-DB] MySQL replication delaying issue Oky, Sorry for that.. J From: Thiago Pojda [mailto:[EMAIL PROTECTED] Sent: Tuesday, February 26, 2008 8:49 PM To: Lasitha Alawatta Cc: php-db@lists.php.net Subject: RES: [PHP-DB] MySQL replication delaying issue I did not say: do

RE: [PHP-DB] mysql data truncation does not cause an error to be thrown

2007-11-08 Thread Vandegrift, Ken
Web Developer/Administrator (Direct) 503-605-4132 [EMAIL PROTECTED] -Original Message- From: Andrew Blake [mailto:[EMAIL PROTECTED] Sent: Thursday, November 08, 2007 7:51 AM To: Instruct ICC Cc: php-db@lists.php.net Subject: Re: [PHP-DB] mysql data truncation does not cause an error

RE: [PHP-DB] mysql data truncation does not cause an error to be thrown

2007-11-08 Thread Instruct ICC
sidestepped. Date: Thu, 8 Nov 2007 15:50:38 + From: [EMAIL PROTECTED] To: [EMAIL PROTECTED] CC: php-db@lists.php.net Subject: Re: [PHP-DB] mysql data truncation does not cause an error to be thrown Hiya I could check the length of the field against the entry data and javascript myself

RE: [PHP-DB] mysql data truncation does not cause an error to be thrown

2007-11-08 Thread Instruct ICC
Using mysql_query if i try to force more data than a field can have the data is truncated yet no error is throw at all. Is there a way round this ? Cheers Andy This isn't exactly what you want to hear, but how about validating your input before submitting a query?

[PHP-DB] mysql data truncation does not cause an error to be thrown

2007-11-08 Thread Andrew Blake
Using mysql_query if i try to force more data than a field can have the data is truncated yet no error is throw at all. Is there a way round this ? Cheers Andy -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP-DB] mysql data truncation does not cause an error to be thrown

2007-11-08 Thread Andrew Blake
To: Instruct ICC Cc: php-db@lists.php.net Subject: Re: [PHP-DB] mysql data truncation does not cause an error to be thrown Hiya I could check the length of the field against the entry data and javascript myself out of trouble but i was more worried that there is no error or message when mysql

Re: [PHP-DB] mysql data truncation does not cause an error to be thrown

2007-11-08 Thread Andrew Blake
Hiya I could check the length of the field against the entry data and javascript myself out of trouble but i was more worried that there is no error or message when mysql clearly returns one saying i've truncated this yet php ignores it completely. It should fail or know about the truncation

RE: [PHP-DB] mysql data truncation does not cause an error to be thrown

2007-11-08 Thread Instruct ICC
Maybe tell the list the exact solution? File/variable/setting? Cheers. I figured it out it was the mysql install not php :-) cheers for your help though :-) Vandegrift, Ken wrote: You may want to check the my.ini setting for the table type you are using and see if there is a

[PHP-DB] MySQL Identifying worst-performing codes

2007-10-04 Thread Lasitha Alawatta
Hello friends, There is a tool call idera (SQL diagnostic manager). Basically it is a performance monitoring and diagnostics tool. It has a feature; Identifying of worst-performing codes - Identifies performance bottlenecks such as the worst-performing stored procedures,

[PHP-DB] mysql statement

2007-09-26 Thread Jas
I am looking for some advice on how to achieve something and so far have been unable to do what I am looking to do. Here is the query I am using: mysql SELECT * - FROM `orders` - WHERE `ordernum` LIKE 35132 - OR `price` LIKE 35132 - OR `partnum` LIKE 35132 - OR `vendor` LIKE

[PHP-DB] mysql error...

2007-08-28 Thread John Pillion
this is bugging me to no end (no pun intended)... I am getting the error: invalid query: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'Condition, ConstructType, BldgDimensions, Stories, CurrentParking,

RE: [PHP-DB] mysql error...

2007-08-28 Thread Bastien Koert
Condition is a reserved word in mysql...you will need to change the field name bastien Date: Tue, 28 Aug 2007 18:11:20 -0700 From: [EMAIL PROTECTED] To: php-db@lists.php.net Subject: [PHP-DB] mysql error... this is bugging me to no end (no pun intended)... I am getting the error: invalid

Re: [PHP-DB] mysql error...

2007-08-28 Thread Chris
John Pillion wrote: this is bugging me to no end (no pun intended)... I am getting the error: invalid query: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'Condition, ConstructType, BldgDimensions,

[PHP-DB] MySQL- Stored Procedures Views

2007-08-22 Thread Lasitha Alawatta
Hi All, Any body has experience using MySQL Stored Procedures Views with PHP. How is the performance of using SPs in mysql. Lasitha Alawatta Application Developer Destinations of the World Holding Establishment P O Box: 19950 Dubai, United Arab Emirates DOTW DISCLAIMER:

[PHP-DB] mysql different server different EXPLAIN result

2007-07-24 Thread Chenri
Dear All I'm running 3 servers with mysql database - Local : 5.0.18-log, MySQL Community Edition (GPL) - Main Server : 4.1.22-standard-log, MySQL Community Edition - Standard (GPL) - Backup Server : 4.1.20, Source Distribution I copied a database from the Main Server to Local and Backup

Re: [PHP-DB] mysql different server different EXPLAIN result

2007-07-24 Thread Niel
Hi I'm running 3 servers with mysql database - Local : 5.0.18-log, MySQL Community Edition (GPL) - Main Server : 4.1.22-standard-log, MySQL Community Edition - Standard (GPL) - Backup Server : 4.1.20, Source Distribution I copied a database from the Main Server to Local and Backup Server

Re: [PHP-DB] mysql different server different EXPLAIN result

2007-07-24 Thread Chris
Chenri wrote: Dear All I'm running 3 servers with mysql database - Local : 5.0.18-log, MySQL Community Edition (GPL) - Main Server : 4.1.22-standard-log, MySQL Community Edition - Standard (GPL) - Backup Server : 4.1.20, Source Distribution Not sure why you're surprised why they are

RE: [PHP-DB] MySQL user anHTACCESSusername not found?

2007-07-17 Thread Instruct ICC
From: Instruct ICC [EMAIL PROTECTED] Why is this second log entry present? I don't see any place where I ask MySQL to authenticate an HTACCESS username. It came to me. The very fact that we are using mod_auth_mysql in the Apache web server means that Apache is trying to authenticate

[PHP-DB] MySQL user anHTACCESSusername not found?

2007-07-13 Thread Instruct ICC
In my apache web server error log, I see the following: [Fri Jul 13 11:19:55 2007] [error] [client an.ip.addr.ess] MySQL ERROR: Can't connect to MySQL server on 'mysql.server.ip.address' (110) [Fri Jul 13 11:19:55 2007] [error] [client an.ip.addr.ess] MySQL user anHTACCESSusername not found:

[PHP-DB] MySQL Error 1366

2007-05-28 Thread elk dolk
Hi All, I want to load data from dump file to MySQL table using LOAD DATA INFILE but there is Error 1366 : mysql LOAD DATA - INFILE 'D:/SITE/SOMETABLE.SQL' - INTO TABLE SOMETABLE - FIELDS TERMINATED BY ',' - OPTIONALLY ENCLOSED BY '' - LINES TERMINATED BY ')'; ERROR 1366

Re: [PHP-DB] MySQL Error 1366

2007-05-28 Thread Chris
elk dolk wrote: Hi All, I want to load data from dump file to MySQL table using LOAD DATA INFILE but there is Error 1366 : mysql LOAD DATA - INFILE 'D:/SITE/SOMETABLE.SQL' - INTO TABLE SOMETABLE - FIELDS TERMINATED BY ',' - OPTIONALLY ENCLOSED BY '' - LINES TERMINATED BY

Re: [PHP-DB] MySQL Error 1366

2007-05-28 Thread Chetanji
Chetanji says, This may be a typo of yours. Look at the header... CREATE TABLE `sometableo` The 'o' is added by mistake? Blessings, Chetanji elk dolk wrote: Hi All, I want to load data from dump file to MySQL table using LOAD DATA INFILE but there is Error 1366 : mysql LOAD DATA

[PHP-DB] MySQL BETWEEN Problems

2007-05-18 Thread Tony Grimes
I'm using BETWEEN to return a list all people who's last names fall between A and F: WHERE last_name BETWEEN 'A' AND 'F' ... but it's only returning names between A and E. The same thing happens when I use: WHERE last_name = 'A' AND last_name = 'F' ... Shouldn't this work the way I

Re: [PHP-DB] MySQL BETWEEN Problems

2007-05-18 Thread Brad Bonkoski
I think you need between 'A' and 'F%' Aa is between A and F but 'Fa' is not between 'A' and 'F' (but 'Ez' would be between 'A' and 'F') -B Tony Grimes wrote: I'm using BETWEEN to return a list all people who's last names fall between A and F: WHERE last_name BETWEEN 'A' AND 'F' ... but

Re: [PHP-DB] MySQL BETWEEN Problems

2007-05-18 Thread Brad Bonkoski
Try using the substr, since you are only comparing the first letters... (sorry I did not reply all on the other email, Dan) i.e. select name from users where substr(name, 1, 1) = 'A' and substr(name, 1, 1) = 'B'; -B Dan Shirah wrote: So just change it to WHERE last_name BETWEEN 'A' AND 'G' .

Re: [PHP-DB] MySQL BETWEEN Problems

2007-05-18 Thread Tony Grimes
Yeah, but what do I do for Q-Z? I guess I¹ll have to write a condition to use last_name = ŒQ¹ if it finds a Z. I¹ll have to write conditions to look for other exceptions too. Aaarrgh! *looks up at the Gods* Damn you BETWEEN! Why must you torture me so!?! Have a good weekend. On 5/18/07 2:51

Re: [PHP-DB] MySQL BETWEEN Problems

2007-05-18 Thread Tony Grimes
Nice! That did the trick. Thanks Brad. I live to fight another day. Tony On 5/18/07 3:00 PM, Brad Bonkoski [EMAIL PROTECTED] wrote: Try using the substr, since you are only comparing the first letters... (sorry I did not reply all on the other email, Dan) i.e. select name from users

[PHP-DB] MySQL 0 index date and time functions (mode or typo)?

2007-05-16 Thread Dwight Altman
In MySQL, regardless of the documentation version, http://dev.mysql.com/doc/refman/4.1/en/date-and-time-functions.html#function _week I've seen the explanation for receiving a 0 from the WEEK function depending on the mode setting which causes a range between 0-53. But what about: DAYOFMONTH 0 to

RE: [PHP-DB] MySQL Query on the Fly

2007-05-14 Thread Dwight Altman
To: php-db@lists.php.net Subject: [PHP-DB] MySQL Query on the Fly Good Morning, I've been searching and toying with this solution for some time but can't find that right answer. Looking for solutions/suggestions to the following: I created a program that will allow people to track

[PHP-DB] MySQL Query on the Fly

2007-05-11 Thread Todd A. Dorschner
Good Morning, I've been searching and toying with this solution for some time but can't find that right answer. Looking for solutions/suggestions to the following: I created a program that will allow people to track sales and depending on what they've sold, they will either get a set

Re: [PHP-DB] MySQL ERRORS

2007-05-08 Thread Chris
Chetan Graham wrote: Hi to All, I am having problems with the MySQL DB. It started with this command from a call in a PHP script... INSERT INTO docprouser (id,valid,password)VALUES ('user5','Y',md5('ksobhinyai')); or die(mysql_error()); That doesn't do anything (it will create a parse

[PHP-DB] mysql question.

2007-04-03 Thread Me2resh Lists
hi i need help regarding a sql query in my php app. the query is : $SQL = SELECT DISTINCT(EMail) FROM mena_guests WHERE Voted = 'yes' LIMIT $startingID,$items_numbers_list; i want to sort this query by the number of the repeated EMail counts. can anyone help me with that please ?

Re: [PHP-DB] mysql question.

2007-04-03 Thread Dimiter Ivanov
On 4/3/07, Me2resh Lists [EMAIL PROTECTED] wrote: hi i need help regarding a sql query in my php app. the query is : $SQL = SELECT DISTINCT(EMail) FROM mena_guests WHERE Voted = 'yes' LIMIT $startingID,$items_numbers_list; i want to sort this query by the number of the repeated EMail

Re: [PHP-DB] mysql question.

2007-04-03 Thread Haydar TUNA
Hello, I try your SQL statements. There is no problem on your SQL syntax and you can use alias in the order by clause.:) $SQL = SELECT EMail,count(EMail) AS repeated FROM mena_guests WHERE Voted = 'yes' GROUP BY EMail ORDER BY repeated LIMIT $startingID,$items_numbers_list; --

Re: [PHP-DB] MySQL Foreign Key Issue

2007-03-27 Thread OKi98
Luchino - Samel wrote: *Question No. 01* there are some kind of foreign key in database Some of them want give any error when you delete from the table where the foreign key is in, this cause the remove is recursive and it delete also the ORDER linked to the CUSTOMER (CASCADE foreign key). In

Re: [PHP-DB] MySQL Foreign Key Issue

2007-03-26 Thread Luchino - Samel
*Question No. 01* there are some kind of foreign key in database Some of them want give any error when you delete from the table where the foreign key is in, this cause the remove is recursive and it delete also the ORDER linked to the CUSTOMER (CASCADE foreign key). In other kind of foreign key

[PHP-DB] MySQL Foreign Key Issue

2007-03-25 Thread Lasitha Alawatta
Hello, I have 2 issue, regarding MySQL Foreign Key. I have two tables; Table 01 CUSTOMER column name characteristic SID Primary Key Full_Name Table ORDERS column name characteristic Order_ID Primary Key Order_Date Customer_SID Foreign Key Amount When I run

[PHP-DB] MySQL queries

2007-03-21 Thread Ron Croonenberg
Hello all, Is there a discussion list for MySQL queries (I have a rookie MySQL query question and don't want to bug this list with it) Ron -- = It's is not, it isn't ain't, and it's it's, not its, if you mean it is. If you

Re: [PHP-DB] MySQL queries

2007-03-21 Thread Chris
Ron Croonenberg wrote: Hello all, Is there a discussion list for MySQL queries (I have a rookie MySQL query question and don't want to bug this list with it) http://lists.mysql.com/ -- Postgresql php tutorials http://www.designmagick.com/ -- PHP Database Mailing List (http://www.php.net/)

Re: [PHP-DB] MySQL queries

2007-03-21 Thread bedul
howdy - Original Message - From: Chris [EMAIL PROTECTED] To: Ron Croonenberg [EMAIL PROTECTED] Cc: php-db@lists.php.net Sent: Thursday, March 22, 2007 7:06 AM Subject: Re: [PHP-DB] MySQL queries Ron Croonenberg wrote: Hello all, Is there a discussion list for MySQL queries (I have

[PHP-DB] MySQL sort stopped working

2007-03-13 Thread Tony Grimes
I have this page that lists artists alphabetically: http://www.wallacegalleries.com/artists.php At least it did until today. Nobody made any changes to the files, but the database stopped sorting by artist_id. The list shown is just the default order that mysql spits out if the SORT BY clause is

RE: [PHP-DB] MySQL sort stopped working

2007-03-13 Thread Bastien Koert
too small a sort space on the server? have you checked the server config? Bastien From: Tony Grimes [EMAIL PROTECTED] To: PHP-DB php-db@lists.php.net Subject: [PHP-DB] MySQL sort stopped working Date: Tue, 13 Mar 2007 13:22:25 -0600 I have this page that lists artists alphabetically: http

Re: [PHP-DB] MySQL sort stopped working

2007-03-13 Thread Chris
Tony Grimes wrote: I have this page that lists artists alphabetically: http://www.wallacegalleries.com/artists.php At least it did until today. Nobody made any changes to the files, but the database stopped sorting by artist_id. The list shown is just the default order that mysql spits out if

Re: [PHP-DB] Mysql autentication problem

2007-03-03 Thread Roberto Tavares
, bedul wrote: - Original Message - From: Micah Stevens [EMAIL PROTECTED] To: Roberto F Tavares Neto [EMAIL PROTECTED] Cc: php-db@lists.php.net Sent: Saturday, March 03, 2007 3:17 AM Subject: Re: [PHP-DB] Mysql autentication problem Strange. If you look at the users table

Re: [PHP-DB] Mysql autentication problem

2007-03-03 Thread Roberto Tavares
I did the reload, but with no effect... On Sat, 3 Mar 2007 09:17:36 +0700, bedul wrote - Original Message - From: Micah Stevens [EMAIL PROTECTED] To: Roberto F Tavares Neto [EMAIL PROTECTED] Cc: php-db@lists.php.net Sent: Saturday, March 03, 2007 3:17 AM Subject: Re: [PHP-DB] Mysql

Re: [PHP-DB] Mysql autentication problem

2007-03-03 Thread Micah Stevens
*Subject:* Re: [PHP-DB] Mysql autentication problem Reloading the grant tables should happen almost immediately unless you have an extremely large set of users, very little memory, or a very slow computer. On 03/02/2007 06:17 PM, bedul wrote: - Original Message

[PHP-DB] Mysql autentication problem

2007-03-02 Thread Roberto F Tavares Neto
Hello, I'm trying to do a very simple thing: create a database and a user to use it. So, initially, I use the web interface phpmyadmin. Logged as root, I created the database, and the user with some password. But, I could not login using phpmyadmin. Either any php-based system could

Re: [PHP-DB] Mysql autentication problem

2007-03-02 Thread Ted Fines
Hi, So it works from PHP w/o a password, but with a password does not? What are you using for a password? I don't mean post it here, but are there any 'funny' characters in it? I've had trouble because of that before, on other systems. Try a dumb, obviously OK password, like 'apples' and see

Re: [PHP-DB] Mysql autentication problem

2007-03-02 Thread Roberto F Tavares Neto
Ted, I try the classic abc and had the same problem... Roberto Ted Fines escreveu: Hi, So it works from PHP w/o a password, but with a password does not? What are you using for a password? I don't mean post it here, but are there any 'funny' characters in it? I've had trouble because of

Re: [PHP-DB] Mysql autentication problem

2007-03-02 Thread Ted Fines
Hi, When you're connecting from your PHP script, are you connecting from the same machine that the db is on, or a different one? If a different one, you'll need to do grant commands like: grant all privileges on mydbname.* to 'mydbuser'@'myhostname.mycompany.net' identified by 'mypassword';

RE: [PHP-DB] Mysql autentication problem

2007-03-02 Thread Bastien Koert
Subject: [PHP-DB] Mysql autentication problem Date: Fri, 02 Mar 2007 10:05:54 -0300 Hello, I'm trying to do a very simple thing: create a database and a user to use it. So, initially, I use the web interface phpmyadmin. Logged as root, I created the database, and the user with some password

Re: [PHP-DB] Mysql autentication problem

2007-03-02 Thread Roberto F Tavares Neto
From: Roberto F Tavares Neto [EMAIL PROTECTED] To: php-db@lists.php.net Subject: [PHP-DB] Mysql autentication problem Date: Fri, 02 Mar 2007 10:05:54 -0300 Hello, I'm trying to do a very simple thing: create a database and a user to use it. So, initially, I use the web interface phpmyadmin

Re: [PHP-DB] Mysql autentication problem

2007-03-02 Thread Roberto F Tavares Neto
Ted, The [EMAIL PROTECTED] does the same effect as 'mydbuser'@'myhostname.mycompany.net' , right? Btw, for web apps, I got another user, @localhost only. This user is working... I thought it was a problem on the GUI, so I tried a [EMAIL PROTECTED] from mysql command line. It fails too...

Re: [PHP-DB] Mysql autentication problem

2007-03-02 Thread Micah Stevens
Did you give the user permissions to use the database in question? Here's my sequence of actions: . 1) Create DB if it doesn't exist 2) Create the user w/password 3) Give the user permission to use the database. 4) Flush privileges to update the server. 5) login and enjoy. -Micah Roberto F

Re: [PHP-DB] Mysql autentication problem

2007-03-02 Thread Roberto F Tavares Neto
Micah: I did create the database. Then, I use the: GRANT ALL PRIVILEGES ON db.* TO [EMAIL PROTECTED] IDENTIFIED BY 'password' to do the 2 and 3 steps. FLUSH PRIVILEGES to do the step 4. But the step 5 really does not work... only on the shell or when I remove the password from the user...

Re: [PHP-DB] Mysql autentication problem

2007-03-02 Thread Micah Stevens
Strange. If you look at the users table, is there a password hash in the password field? Roberto F Tavares Neto wrote: Micah: I did create the database. Then, I use the: GRANT ALL PRIVILEGES ON db.* TO [EMAIL PROTECTED] IDENTIFIED BY 'password' to do the 2 and 3 steps. FLUSH PRIVILEGES to

Re: [PHP-DB] Mysql autentication problem

2007-03-02 Thread bedul
- Original Message - From: Micah Stevens [EMAIL PROTECTED] To: Roberto F Tavares Neto [EMAIL PROTECTED] Cc: php-db@lists.php.net Sent: Saturday, March 03, 2007 3:17 AM Subject: Re: [PHP-DB] Mysql autentication problem Strange. If you look at the users table, is there a password hash

Re: [PHP-DB] Mysql autentication problem

2007-03-02 Thread Micah Stevens
PROTECTED] Cc: php-db@lists.php.net Sent: Saturday, March 03, 2007 3:17 AM Subject: Re: [PHP-DB] Mysql autentication problem Strange. If you look at the users table, is there a password hash in the password field? i think this must be reload?? not just flush?? it happen to me

Re: [PHP-DB] Mysql autentication problem

2007-03-02 Thread bedul
Subject: Re: [PHP-DB] Mysql autentication problem Reloading the grant tables should happen almost immediately unless you have an extremely large set of users, very little memory, or a very slow computer. On 03/02/2007 06:17 PM, bedul wrote: - Original Message - From: Micah Stevens

Re: [PHP-DB] MYSQL REGEXP question

2007-01-10 Thread Micah Stevens
No, it shouldn't because there are only two B's, one is followed by a 'v' (one of your exceptions) and the other is at the end of the line, right? -Micah Mike van Hoof wrote: That is it almost :) SELECT 'oer bv b' REGEXP 'b[^v]$|b[^v]\s?'; gives me 0 as a result, while it shoud give me 1,

[PHP-DB] MYSQL REGEXP question

2007-01-09 Thread mike
Hello, i am try to make a regular expression work, but keep getting an error message does anyone know how i can make it work? The query is: SELECT 'boer bv' REGEXP '[ b|^b](?![v$|v ])'; So it has to match each starting 'b' and all the b's pf following words. But now followed by a v(line end)

Re: [PHP-DB] MYSQL REGEXP question

2007-01-09 Thread Micah Stevens
Your code states: Match: one of the following letters: -,b,|,^,b negative look ahead one of these: -,v,$,|,v Which isn't what you're looking for. Remember the negating '^' only works at the start of a [] list. And '$' only means line-end if it's outside [], inside it stands for the '$'

Re: [PHP-DB] mysql rereading result set (fetch_assoc)

2007-01-09 Thread Chris
christine wrote: Hi, I would ask which way is more efficient and save time? Save each row to array or mysql_data_seek(0) ? Probably mysql_data_seek(0). That just resets the mysql pointer back to the start and so it doesn't re-run the query or anything like that and doesn't take up any extra

Re: [PHP-DB] mysql rereading result set (fetch_assoc)

2007-01-09 Thread Niel Archer
Hi Hi, I would ask which way is more efficient and save time? Save each row to array or mysql_data_seek(0) ? That totally depends on which resources are more valuable to you. The array will likely use more memory but be faster to process. While mysql_data_seek(0) would probably use no

[PHP-DB] MYSQL REGEXP question

2007-01-08 Thread Mike van Hoof
Hello, i am try to make a regular expression work, but keep getting an error message does anyone know how i can make it work? The query is: SELECT 'boer bv' REGEXP '[ b|^b](?![v$|v ])'; So it has to match each starting 'b' and all the b's pf following words. But now followed by a v(line

[PHP-DB] mysql rereading result set (fetch_assoc)

2007-01-06 Thread lwoods
I'm running thru a result set using fetch_assoc. Now I want to run through it again. How? TIA, Larry Woods -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP-DB] MySQL SQL Query Help

2006-11-13 Thread Peter Beckman
I have a table: id fkid foobar 1 1 345yellow 2 1 34 red 3 2 3459 green 4 2 345brown I want to select the largest value of foo for a unique fkid, and return bar, the results ordered by bar. In this case, 345 is the largest value of foo for fkid 1, and

Re: [PHP-DB] MySQL SQL Query Help

2006-11-13 Thread Niel Archer
Hi Try: SELECT fkid, MAX(foo), bar FROM table GROUP BY fkid ORDER BY bar DESC Niel -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

RE: [PHP-DB] MySQL SQL Query Help

2006-11-13 Thread Miguel Guirao
select max(bar) from mytable where unique fkid order by bar asc as far as I remember!! -Original Message- From: Peter Beckman [mailto:[EMAIL PROTECTED] Sent: Lunes, 13 de Noviembre de 2006 04:59 p.m. To: PHP-DB Mailing List Subject: [PHP-DB] MySQL SQL Query Help I have a table: id

Re: [PHP-DB] MySQL SQL Query Help

2006-11-13 Thread [EMAIL PROTECTED]
!! -Original Message- From: Peter Beckman [mailto:[EMAIL PROTECTED] Sent: Lunes, 13 de Noviembre de 2006 04:59 p.m. To: PHP-DB Mailing List Subject: [PHP-DB] MySQL SQL Query Help I have a table: id fkid foobar 1 1 345yellow 2 1 34 red 3 2 3459 green 4 2

Re: [PHP-DB] MySQL SQL Query Help

2006-11-13 Thread Peter Beckman
de Noviembre de 2006 04:59 p.m. To: PHP-DB Mailing List Subject: [PHP-DB] MySQL SQL Query Help I have a table: id fkid foobar 1 1 345yellow 2 1 34 red 3 2 3459 green 4 2 345brown I want to select the largest value of foo for a unique fkid, and return

Re: [PHP-DB] MySQL SQL Query Help

2006-11-13 Thread Chris
Peter Beckman wrote: On Mon, 13 Nov 2006, [EMAIL PROTECTED] wrote: Actually, that should not work, it should give you an error. This should work: SELECT `fkid`,max(`foo`) as foo,`bar` FROM `test2` GROUP BY `fkid` ORDER BY `bar` ASC Yes, but if the data is in a different order that fails

Re: [PHP-DB] mysql databases

2006-10-14 Thread bob plano
sorry, i meant that i wanted to remove the oldest entry and put in a new entry with UPDATE or INSERT. -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP-DB] mysql databases

2006-10-14 Thread Bastien Koert
whynot keep all and just sort/limit them to get the data you want? bastien From: bob plano [EMAIL PROTECTED] To: php-db@lists.php.net Subject: Re: [PHP-DB] mysql databases Date: Sat, 14 Oct 2006 12:47:38 -0500 sorry, i meant that i wanted to remove the oldest entry and put in a new entry

[PHP-DB] mysql databases

2006-10-13 Thread bob plano
how would you add something new into a table and take out something old? example: (1) 1st something (2) 2nd something (3) 3rd something (4) 4th something and then you add in something new so then the table would look like (1) new something (2) 1st something (3) 2nd something (4) 3rd something

Re: [PHP-DB] mysql databases

2006-10-13 Thread Niel Archer
Hi Bob Your question isn't very clear. Do you want to remove the oldest entry, newest, or is there some other criteria to diceide? Niel -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP-DB] mysql databases

2006-10-13 Thread Dave W
He means that he wants to use REPLACE and take out the old entry and update it with a new one. Although, you would probably use UPDATE instead. -- Dave W

Re: [PHP-DB] mysql databases

2006-10-13 Thread Niel Archer
Hi He means that he wants to use REPLACE and take out the old entry and update it with a new one. Although, you would probably use UPDATE instead. Hmmm... Thought this was DB list, not mind-readers. I would also *guess* that would be the intention, but his example seems to remove the newest

[PHP-DB] mysql ORDER BY problems

2006-06-18 Thread Rob W.
Ok, here's what i got in my mysql db. I got a table listed with numbers as follows 1 2 3 4 5 6 7 10 11 12 13 14 15 16 17 18 19 20 21 22 25 These numbers I can display fine. I'm using .. $query=SELECT * FROM db ORDER BY numbers ASC; Right now it displays it as 1 10 11 12 . 2 22 23 25

RE: [PHP-DB] mysql ORDER BY problems

2006-06-18 Thread Bastien Koert
(fieldname as integer) from table where ... order by ... bastien From: Rob W. [EMAIL PROTECTED] To: php-db@lists.php.net Subject: [PHP-DB] mysql ORDER BY problems Date: Sun, 18 Jun 2006 17:19:03 -0500 Ok, here's what i got in my mysql db. I got a table listed with numbers as follows 1 2 3 4 5 6 7

[PHP-DB] MySQL/PHP Left Join Question

2006-05-25 Thread Andrew Darby
Hello, all. I don't know if this is a php-mysql question or just a mysql, but here goes: I have a list of DVDs that my library loans out, and I'd like to allow people to add comments to each item. Since this list gets regenerated periodically (it's extracted from another system, the library

Re: [PHP-DB] MySQL/PHP Left Join Question

2006-05-25 Thread tg-php
One thing I've done in situations like this is just load your returned DB data into an array. Something like this would do: $dvdarr[$result['call_number']]['Title'] = $result['title']; $dvdarr[$result['call_number']]['Publisher'] = $result['publisher'];

RE: [PHP-DB] MySQL/PHP Left Join Question

2006-05-25 Thread Bastien Koert
= $rows['title']; } //echo out the rest of the data echo trtd.$rows['comment']./td/tr; } hth Bastien From: Andrew Darby [EMAIL PROTECTED] To: php-db@lists.php.net Subject: [PHP-DB] MySQL/PHP Left Join Question Date: Thu, 25 May 2006 11:28:56 -0400 Hello, all. I don't know if this is a php

Re: [PHP-DB] MySQL/PHP Left Join Question

2006-05-25 Thread Brad Bonkoski
Some good examples of how to deal with this in PHP have already been given, especially the associative array solution. The question I have is with something like this, how do you weight out the pros/cons of code development versus speed? i.e. for code development breaking the logic up into 2

Re: [PHP-DB] MySQL/PHP Left Join Question

2006-05-25 Thread Andrew Darby
Thanks to Bastien and TG for their suggestions. I'd been looking at it Bastien's way, but TG's is probably better suited to what I want to do. I'd forgotten about that possibility, cramming it all into an array . . . . Again, thanks for the help, Andrew p.s. I'd be curious about the relative

Re: [PHP-DB] MySQL/PHP Left Join Question

2006-05-25 Thread Bastien Koert
test both and let us know bastien From: Andrew Darby [EMAIL PROTECTED] To: php-db@lists.php.net Subject: Re: [PHP-DB] MySQL/PHP Left Join Question Date: Thu, 25 May 2006 12:33:15 -0400 Thanks to Bastien and TG for their suggestions. I'd been looking at it Bastien's way, but TG's is probably

[PHP-DB] mysql searching with fulltext indexing

2006-05-24 Thread Bevan Christians
Hi Listies I have a question Is there any to query a mysql table to get it to return the field names that it currently has marked as Fulltext Indexes? I need to build a searching engine, there are 60 tables being searched, i have created the fulltext indexes on all tables required and i

<    1   2   3   4   5   6   7   8   9   10   >