Re: [PHP] Re: MySQL and PHP weirdness - RESOLVED

2012-02-15 Thread Richard S. Crawford
This has been resolved. A previous programmer had snuck in a function that would convert the value of the "description" field to a date value if it contained the word "Date". This has been fixed. On Tue, Feb 14, 2012 at 5:44 PM, David Robley wrote: > Richard S. Crawford wrote: > > > Bear with m

[PHP] Re: MySQL and PHP weirdness

2012-02-14 Thread David Robley
Richard S. Crawford wrote: > Bear with me here. I have a problem with PHP and MySQL that's been > stumping me for a couple of days now. I'm not even sure how to describe > it, so I'll just do my best. > > There's a row in our bugs database that looks like every other row in the > table, but when

[PHP] Re: [MySQL] Re: MySQL select matching

2010-07-19 Thread Ashley M. Kirchner
On 7/19/2010 10:48 AM, Michael Dykman wrote: Not quite sure what the question is. from: mysql> select * from table where id='1'; +---+-+-+---+ | 1 | 123 | 0.0 | C | | 1 | 234 | 0.1 | D | | 1 | 345 | 0.0 | D | | 1 | 456 | 0.1 | C | | 1 | 567 | 0.1 | G | +

[PHP] Re: MySQL select matching

2010-07-19 Thread Michael Dykman
Not quite sure what the question is. from: > mysql> select * from table where id='1'; > +---+-+-+---+ > | 1 | 123 | 0.0 | C | > | 1 | 234 | 0.1 | D | > | 1 | 345 | 0.0 | D | > | 1 | 456 | 0.1 | C | > | 1 | 567 | 0.1 | G | > +---+-+-+---+ How do we d

[PHP] RE: mysql query returning slowly

2010-04-07 Thread David Murphy
Nathan, The profiling I included proved that was not the case. Mysql run the query and return the single column single row result in under 1 second but PHP's mysql->query waited much longer than that to return. If it was a big result set I could see some slow down in parsing the results into

[PHP] Re: mysql query returning slowly

2010-04-06 Thread Nathan Rixham
David Murphy wrote: > > This is from our application > I enabled profile in mysql to determine why an update took 20seconds. As > you can see MySQL reported no where near that amount of duration took > place. > Is there any way I can dig into php and determine why mysql client libs are > so

[PHP] Re: MySQL: Return Number of Matched Rows

2010-03-26 Thread Shawn McKenzie
James Colannino wrote: > Hey everyone, > > I have a question. If I do a mysql query that updates a column in a row > to the same value, I get 0 rows affected. However, I also get 1 or more > matched rows. Is there a way that I can return the number of matched > rows, rather than the number of

Re: [PHP] Re: MySQL ID -- what happens when you run out of range?

2010-01-25 Thread John Meyer
On 1/25/2010 1:19 PM, Nathan Rixham wrote: Parham Doustdar wrote: Hello there, A friend called me today and was wondering what happens if the ID colomn of an MYSQL database, set to autoinc reaches the int limit. Will it return and begin choosing the ID's that have been deleted, or... what? you

[PHP] Re: MySQL ID -- what happens when you run out of range?

2010-01-25 Thread Nathan Rixham
Parham Doustdar wrote: > Hello there, > A friend called me today and was wondering what happens if the ID colomn of > an MYSQL database, set to autoinc reaches the int limit. Will it return and > begin choosing the ID's that have been deleted, or... what? you change it to bigint before that happ

[PHP] Re: MySQL auto_increment fields Server version: 5.1.32-community-log

2009-08-11 Thread Nisse Engström
On Mon, 10 Aug 2009 01:17:21 +0200, "Ralph Deffke" wrote: >> On Sun, 9 Aug 2009 20:17:15 +0200, "Ralph Deffke" wrote: >> >>> I'm facing the fact that it seems that auto_increment fields in a table not >>> start at 1 like it was in earlier versions even if I install mySQL brand new >>> creating all

[PHP] Re: MySQL auto_increment fields Server version: 5.1.32-community-log

2009-08-10 Thread Ollisso
On Sun, 09 Aug 2009 21:17:15 +0300, "Ralph Deffke" wrote: Hi all, I'm facing the fact that it seems that auto_increment fields in a table not start at 1 like it was in earlier versions even if I install mySQL brand new creating all tables new. it seems to me that auto_increments handlin

[PHP] Re: MySQL auto_increment fields Server version: 5.1.32-community-log

2009-08-09 Thread Ralph Deffke
I should mention that I use MyISAM as storage engine what makes it even more wiered. "Nisse Engström" wrote in message news:91.f7.55947.dc74f...@pb1.pair.com... > On Sun, 9 Aug 2009 20:17:15 +0200, "Ralph Deffke" wrote: > > > I'm facing the fact that it seems that auto_increment fields in a tabl

[PHP] Re: MySQL auto_increment fields Server version: 5.1.32-community-log

2009-08-09 Thread Ralph Deffke
this is a very good startup for the issue. now the question is where does it get the value if there is no max(ai) or when I do an insert in an empty table with the ai field set to 1 where does the innoDB get the next ai value 10720 ? I assume that the SELECT MAX(ai_col) FROM t FOR UPDATE; return i

[PHP] Re: MySQL auto_increment fields Server version: 5.1.32-community-log

2009-08-09 Thread Nisse Engström
On Sun, 9 Aug 2009 20:17:15 +0200, "Ralph Deffke" wrote: > I'm facing the fact that it seems that auto_increment fields in a table not > start at 1 like it was in earlier versions even if I install mySQL brand new > creating all tables new. it seems to me that auto_increments handling has > change

[PHP] Re: MySQL after oracle, still Wise?, was Web application design .......

2009-06-02 Thread Shawn McKenzie
optoma...@rogers.com wrote: > Everybody has given Angus really great advice in this previous thread > and I have learned a lot too. I hope no one mines the fork but I am in > the exact same situation as Angus. If anyone could spare a bit of time > regarding application infrastructure I would really

Re: [PHP] Re: mysql create table with date or timestamp

2009-05-28 Thread Andrew Ballard
On Thu, May 28, 2009 at 11:20 AM, Daniel Brown wrote: > On Thu, May 28, 2009 at 11:15, Andrew Ballard wrote: >> >> Make that a 'comma', not the 'coma' that I seem to be in.  :-) > >    Eh, it's your birthday.  You're allowed.  ;-P > >    Happy birthday, by the way. > Thanks! It's a weak e

Re: [PHP] Re: mysql create table with date or timestamp

2009-05-28 Thread Andrew Ballard
On Thu, May 28, 2009 at 11:15 AM, Andrew Ballard wrote: > 2009/5/28 Grega Leskovsek : >> I GOT THIS ERROR when  I tried first sample with when timestamp; >> >> >> ERROR 1064 (42000): You have an error in your SQL syntax; check the >> manual thatcorresponds to your MySQL server version for the righ

Re: [PHP] Re: mysql create table with date or timestamp

2009-05-28 Thread Daniel Brown
On Thu, May 28, 2009 at 11:15, Andrew Ballard wrote: > > Make that a 'comma', not the 'coma' that I seem to be in.  :-) Eh, it's your birthday. You're allowed. ;-P Happy birthday, by the way. -- daniel.br...@parasane.net || danbr...@php.net http://www.parasane.net/ || http://www.pi

Re: [PHP] Re: mysql create table with date or timestamp

2009-05-28 Thread Grega Leskovsek
The problem was I didn't type a comma before unique id(iddary). Thanks to everybody for helping me on the seminar. Love, Grega 2009/5/28 LinuxManMikeC : > Actually, AUTO_INCREMENT is the correct syntax for MySQL.  I think the > problem is NOT NULL should come first: iddiary INT NOT NULL > AUTO_I

Re: [PHP] Re: mysql create table with date or timestamp

2009-05-28 Thread Andrew Ballard
2009/5/28 Grega Leskovsek : > I GOT THIS ERROR when  I tried first sample with when timestamp; > > > ERROR 1064 (42000): You have an error in your SQL syntax; check the > manual thatcorresponds to your MySQL server version for the right > syntax to use near 'id(iddiary) )' at line 1 > > > 2009/5/2

Re: [PHP] Re: mysql create table with date or timestamp

2009-05-28 Thread LinuxManMikeC
Actually, AUTO_INCREMENT is the correct syntax for MySQL. I think the problem is NOT NULL should come first: iddiary INT NOT NULL AUTO_INCREMENT. 2009/5/28 João Cândido de Souza Neto : > It´s not auto_increment, it´s auto increment. > > -- > João Cândido de Souza Neto > SIENS SOLUÇÕES EM

Re: [PHP] Re: mysql create table with date or timestamp

2009-05-28 Thread Jo�o C�ndido de Souza Neto
It´s not auto_increment, it´s auto increment. -- João Cândido de Souza Neto SIENS SOLUÇÕES EM GESTÃO DE NEGÓCIOS Fone: (0XX41) 3033-3636 - JS www.siens.com.br "Grega Leskovsek" escreveu na mensagem news:1df2d4810905280748uec4f425kaf14b6410caa...@mail.gmail.com... I GOT THIS ERROR when

Re: [PHP] Re: mysql create table with date or timestamp

2009-05-28 Thread Grega Leskovsek
I GOT THIS ERROR when I tried first sample with when timestamp; ERROR 1064 (42000): You have an error in your SQL syntax; check the manual thatcorresponds to your MySQL server version for the right syntax to use near 'id(iddiary) )' at line 1 2009/5/28 João Cândido de Souza Neto : > If you n

[PHP] Re: mysql create table with date or timestamp

2009-05-28 Thread Jo�o C�ndido de Souza Neto
If you need date and hour the best way is: CREATE TABLE diary ( iddiary int auto_increment not null, imepriimek varchar(50), when timestamp, action varchar(30), onfile varchar(100) unique id(iddiary) ); if you need only date you can use: CREATE TABLE diary ( iddiary int auto_increment not

Re: [PHP] Re: MYSQL 5 auto increment not working

2009-05-21 Thread Bastien Koert
On Thu, May 21, 2009 at 9:34 AM, Nathan Rixham wrote: > Leidago !Noabeb wrote: > >> Hi All >> >> >> I know this is not strictly a PHP question, but i have a problem whenever >> i >> insert a record using PHP. Basically the auto increment field does not >> work >> at all. Here's the structure of t

[PHP] Re: MYSQL 5 auto increment not working

2009-05-21 Thread Nathan Rixham
Leidago !Noabeb wrote: Hi All I know this is not strictly a PHP question, but i have a problem whenever i insert a record using PHP. Basically the auto increment field does not work at all. Here's the structure of the table that i'm using: CREATE TABLE `children` ( `cid` int(4) NOT NULL auto

[PHP] Re: MySQL class. Thoughts?

2009-01-21 Thread Al
Jay Moore wrote: This is a MySQL class I use and I wanted to get everyone's thoughts on how/if I can improve it. This is for MySQL only. I don't need to make it compatible with other databases. I'm curious what you all think. Thanks, Jay Class: -- { // Constructor functio

[PHP] Re: MYSQL insert problems

2008-10-17 Thread Frank Stanovcak
Just incase the problem was refrencing an array in an SQL statement I tried this too with the same result. $value) { echo $key . ' : ' . $value . ''; }; echo ''; }; mysql_close($connection); include('..\VariableReveal.php'); ?> -- PHP General Mailing List (http://www.php.net/) To unsubs

Re: [PHP] Re: MySQL Workbench coming for Linux

2008-09-18 Thread Ross McKay
Luke wrote: >so it's like Microsoft Access? I don't get it... No, Microsoft Access is a development environment sitting on top of a simplistic database (JET). Access gives you a nice GUI to help you interactively build up your database, and it makes a great prototyping tool and data massage tool,

Re: [PHP] Re: MySQL Workbench coming for Linux

2008-09-18 Thread Luke
so it's like Microsoft Access? I don't get it... 2008/9/18 Ross McKay <[EMAIL PROTECTED]> > Bastien Koert wrote: > > >what about dia on llinux? Not quite as nice as visio...but livable > > The Enterprise Architect version of Visio lets you add column > definitions to your entities, add foreign ke

Re: [PHP] Re: MySQL Workbench coming for Linux

2008-09-17 Thread Ross McKay
Bastien Koert wrote: >what about dia on llinux? Not quite as nice as visio...but livable The Enterprise Architect version of Visio lets you add column definitions to your entities, add foreign key relationships, add indices, add comments at the table and column level, and then generate a build sc

Re: [PHP] Re: MySQL Workbench coming for Linux

2008-09-17 Thread Bastien Koert
On Wed, Sep 17, 2008 at 4:13 AM, Ross McKay <[EMAIL PROTECTED]> wrote: > On Wed, 17 Sep 2008 09:00:45 +0100, Luke wrote: > > >What is it? > > > >I'm only familiar with the MySQL tools such as Query Browser and Admin? > > http://dev.mysql.com/downloads/workbench/5.0.html > > In short, it's a data m

Re: [PHP] Re: MySQL Workbench coming for Linux

2008-09-17 Thread Ross McKay
On Wed, 17 Sep 2008 09:00:45 +0100, Luke wrote: >What is it? > >I'm only familiar with the MySQL tools such as Query Browser and Admin? http://dev.mysql.com/downloads/workbench/5.0.html In short, it's a data modelling tool. Such things are very handy for designing and building databases, and usu

Re: [PHP] Re: MySQL Workbench coming for Linux

2008-09-17 Thread Luke
What is it? I'm only familiar with the MySQL tools such as Query Browser and Admin? 2008/9/17 Dax Solomon Umaming <[EMAIL PROTECTED]> > Ross McKay wrote: > > Posting this here, because a few people responded when I mentioned not > > having a Linux-native data modelling tool. Apparently, MySQL Wo

[PHP] Re: MySQL Workbench coming for Linux

2008-09-16 Thread Dax Solomon Umaming
Ross McKay wrote: > Posting this here, because a few people responded when I mentioned not > having a Linux-native data modelling tool. Apparently, MySQL Workbench > should be alpha-ready by end of the month... I've been waiting for this. I'm getting tired of DBDesigner4's bugs and all. -- Dax S

Re: [PHP] Re: MySQL Group?

2008-03-19 Thread Chris
John Taylor-Johnston wrote: Thanks for getting me started. (Sorry, I'm a top quoter.) Below is some working code for the archives. What I've learned so far is that : 1) what I'm referring to in `person` has to be a key. It should be a unique item rather than just a 'key' (indexed item). If y

Re: [PHP] Re: MySQL Group?

2008-03-19 Thread John Taylor-Johnston
Thanks for getting me started. (Sorry, I'm a top quoter.) Below is some working code for the archives. What I've learned so far is that : 1) what I'm referring to in `person` has to be a key. 2) if I want to refer to more than one field from person in shopping, I have to use unique keys. I'm

Re: [PHP] Re: MySQL Group?

2008-03-19 Thread Chris
George J wrote: Hi John, "John Taylor-Johnston" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] Does anyone know of a good MySQL group? I want to make a relational link from `data` to `shopping` so when I insert a new record in `shopping`, I will see the contents of `data`.`name`

[PHP] Re: MySQL Group?

2008-03-19 Thread George J
Hi John, "John Taylor-Johnston" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Does anyone know of a good MySQL group? > I want to make a relational link from `data` to `shopping` so when I > insert a new record in `shopping`, I will see the contents of > `data`.`name` and `data`.

[PHP] Re: MySQL Group?

2008-03-19 Thread John Taylor-Johnston
John Taylor-Johnston wrote: Does anyone know of a good MySQL group? Found it: http://lists.mysql.com/mysql/ Thanks, John -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: mysql test and error

2008-02-24 Thread Nathan Rixham
hE wrote: hi, I found an e-book in the net about php and mysql and with its sample program I am trying to test whether I have mysql working correctly or not. the following program gives error message. why? Test MySQL Error “ . mysql_errno() . “: “ . mysql_error() . “”; else { ?> Variable

Re: [PHP] Re: mysql input

2008-02-19 Thread admin
Filter the data $data = str_replace("'", "", $data); I am sure there are many ways to filter the data before insert. (If you are SURE you have "A.D.D." then it wont matter what I say to you.) Rick B. On Feb 18, 2008 11:24 PM, Shawn McKenzie <[EMAIL PROTECTED]> wrote: > nihilism machine w

Re: [PHP] Re: mysql input

2008-02-19 Thread Daniel Brown
On Feb 18, 2008 11:24 PM, Shawn McKenzie <[EMAIL PROTECTED]> wrote: > nihilism machine wrote: > > I have a user saving a VARCHAR(255) field in a mysql db which has single > > quotes in the text, how can i replace them so that they dont fuck up my > > mysql command? > > > > -e > > > Have you tried:

Re: [PHP] Re: mysql input

2008-02-19 Thread Nathan Rixham
Bastien Koert wrote: thats awesome bastien> To: php-general@lists.php.net> Date: Tue, 19 Feb 2008 11:21:02 +> From: [EMAIL PROTECTED]> Subject: Re: [PHP] Re: mysql input> > Zoltán Németh wrote:> > 2008. 02. 19, kedd keltezéssel 11.03-kor Nathan Rixham ezt írta:

RE: [PHP] Re: mysql input

2008-02-19 Thread Bastien Koert
thats awesome bastien> To: php-general@lists.php.net> Date: Tue, 19 Feb 2008 11:21:02 +> From: [EMAIL PROTECTED]> Subject: Re: [PHP] Re: mysql input> > Zoltán Németh wrote:> > 2008. 02. 19, kedd keltezéssel 11.03-kor Nathan Rixham ezt írta:> >> Richard

Re: [PHP] Re: mysql input

2008-02-19 Thread Nathan Rixham
Nathan Rixham wrote: Zoltán Németh wrote: 2008. 02. 19, kedd keltezéssel 11.03-kor Nathan Rixham ezt írta: Richard Heyes wrote: Shawn McKenzie wrote: nihilism machine wrote: I have a user saving a VARCHAR(255) field in a mysql db which has single quotes in the text, how can i replace them so

Re: [PHP] Re: mysql input

2008-02-19 Thread Nathan Rixham
Zoltán Németh wrote: 2008. 02. 19, kedd keltezéssel 11.03-kor Nathan Rixham ezt írta: Richard Heyes wrote: Shawn McKenzie wrote: nihilism machine wrote: I have a user saving a VARCHAR(255) field in a mysql db which has single quotes in the text, how can i replace them so that they dont fuck u

Re: [PHP] Re: mysql input

2008-02-19 Thread Zoltán Németh
2008. 02. 19, kedd keltezéssel 11.03-kor Nathan Rixham ezt írta: > Richard Heyes wrote: > > Shawn McKenzie wrote: > >> nihilism machine wrote: > >>> I have a user saving a VARCHAR(255) field in a mysql db which has single > >>> quotes in the text, how can i replace them so that they dont fuck up my

Re: [PHP] Re: mysql input

2008-02-19 Thread Nathan Rixham
Richard Heyes wrote: Shawn McKenzie wrote: nihilism machine wrote: I have a user saving a VARCHAR(255) field in a mysql db which has single quotes in the text, how can i replace them so that they dont fuck up my mysql command? -e Have you tried: dont_fuck_up_my_mysql_command() Hrmph, I c

Re: [PHP] Re: mysql input

2008-02-19 Thread Richard Heyes
Shawn McKenzie wrote: nihilism machine wrote: I have a user saving a VARCHAR(255) field in a mysql db which has single quotes in the text, how can i replace them so that they dont fuck up my mysql command? -e Have you tried: dont_fuck_up_my_mysql_command() Hrmph, I can't seem to find that

[PHP] Re: mysql input

2008-02-18 Thread Shawn McKenzie
nihilism machine wrote: > I have a user saving a VARCHAR(255) field in a mysql db which has single > quotes in the text, how can i replace them so that they dont fuck up my > mysql command? > > -e Have you tried: dont_fuck_up_my_mysql_command() -- PHP General Mailing List (http://www.php.net/

[PHP] Re: mysql question #2

2008-02-10 Thread Shawn McKenzie
nihilism machine wrote: > Ok, I read the php.net info. so with this function though: > > public function select_one($sql) { > $this->last_query = $sql; > $r = mysql_query($sql); > if (!$r) { > $this->last_error = mysql_error(); > return false; >

[PHP] Re: mysql date question

2008-01-03 Thread Adam Williams
nevermind, figure it out, had to take the ' ' away from contract.length_start :) Adam Williams wrote: I have a field in mysql as shown by describe contract; | length_start | date| YES | | NULL || Which stores it in the mysql format of -MM-

[PHP] Re: MySQL Identifying worst-performing codes

2007-11-08 Thread Colin Guthrie
Lasitha Alawatta wrote: > 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 > procedur

[PHP] Re: MySQL and SVN

2007-10-25 Thread Jens Kleikamp
Emil Edeholt schrieb: Hi all! Maybe slightly off topic, but I would like to know how you guys handle mysql structures between different computers (and for that matter from the developer desktop to the stable server). I work on my home and my office computer with the same php projects. I kee

[PHP] Re: mySQL Results To XML -- my xmltag() functions

2007-10-06 Thread Timothy Murphy
mike wrote: > I made this at one point: > > function array2xml($array, $complete = true) { > $xml = "<$array[NODE] "; > unset($array['NODE']); > ksort($array); > foreach(array_keys($array) as $key) { > $xml .= "$key=\"$array[$key]\" "; > } > if($complete) { >

[PHP] Re: MySQL Identifying worst-performing codes

2007-10-04 Thread Colin Guthrie
Lasitha Alawatta wrote: > 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

[PHP] Re: mysql question

2007-07-16 Thread Man-wai Chang
> CREATE TEMPORARY haha ( KEY (field1), KEY (field2) ) > AS > SELECT po_no, po_date, item_no FROM . WHERE > Then I don't need the privilege for ALTER TABLE. I meant I could build index on a temp table without the privilege to use "ALTER TABLE" by making the index definitions as part of t

[PHP] Re: mysql question

2007-07-16 Thread Man-wai Chang
> You didn't send much info along, so I assume you're using some version > of MySQL 5.0. Thanks. I figured it out (doesn't need 5.0): CREATE TEMPORARY haha ( KEY (field1), KEY (field2) ) AS SELECT po_no, po_date, item_no FROM . WHERE Then I don't need the privilege for ALTER TABLE. -

[PHP] Re: mysql question

2007-07-16 Thread Daniel Kullik
Man-wai Chang wrote: > I tried to post to mysql.general, but the message never appeared. So I > am trying my luck here. > > How could I build an index for a table created using the "CREATE > TEMPORARY TABLE ... SELECT ... FROM ..." syntax, using an account > without the privilege to use ALTER TAB

Re: [PHP] Re: MySQL exceptions

2007-04-10 Thread Davi
Em Terça 10 Abril 2007 19:26, Richard Lynch escreveu: > > I don't think MySQL or even mysqli have any kind of exception throwing > yet, if ever. Googling a bit more, I think that MySQL already have some exceptions [1], the question, now, is: how to catch them with PHP? =] I think that just using

Re: [PHP] Re: MySQL exceptions

2007-04-10 Thread Richard Lynch
On Mon, April 9, 2007 6:34 pm, Davi wrote: > Em Segunda 09 Abril 2007 21:21, itoctopus escreveu: >> Use the @ in front of the statement and then check the result if >> it's >> valid. >> >> -- >> itoctopus - http://www.itoctopus.com > > > I already use it, but I believe that try-catch would be _more

Re: [PHP] Re: MySQL exceptions

2007-04-09 Thread Davi
Em Segunda 09 Abril 2007 21:21, itoctopus escreveu: > Use the @ in front of the statement and then check the result if it's > valid. > > -- > itoctopus - http://www.itoctopus.com I already use it, but I believe that try-catch would be _more_ useful... With try-cath I can _get_ more errors instead

[PHP] Re: MySQL exceptions

2007-04-09 Thread itoctopus
Use the @ in front of the statement and then check the result if it's valid. -- itoctopus - http://www.itoctopus.com "Davi" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > > Hi all! > > I'm developing an OOP app using PHP 5. > I want to use try-catch with mysql functions. > > So, the

RE: [PHP] Re: mysql ORDER BY problem

2006-06-18 Thread Peter Lauri
Just do: SELECT * FROM thetable ORDER BY yourfieldyouwanttoorder If you want it in reverse order you add DESC in the end. /Peter -Original Message- From: John Nichel [mailto:[EMAIL PROTECTED] Sent: Monday, June 19, 2006 5:51 AM To: php-general@lists.php.net Subject: Re: [PHP] Re

Re: [PHP] Re: mysql ORDER BY problem

2006-06-18 Thread John Nichel
syntax, or ask on the MySQL list. You want PHP to do the sorting, look at PHP's array functions; however, it'd be more efficient to go the MySQL route. - Original Message - From: "Michael Rasmussen" <[EMAIL PROTECTED]> To: Sent: Sunday, June 18, 2006 4:51 PM

Re: [PHP] Re: mysql ORDER BY problem

2006-06-18 Thread Rob W.
It's not in general to mysql, it's how php and mysql is displaying it. - Original Message - From: "Michael Rasmussen" <[EMAIL PROTECTED]> To: Sent: Sunday, June 18, 2006 4:51 PM Subject: [PHP] Re: mysql ORDER BY problem On Sun, 18 Jun 2006 15:55:14 -0500,

[PHP] Re: mysql ORDER BY problem

2006-06-18 Thread Michael Rasmussen
On Sun, 18 Jun 2006 15:55:14 -0500, Rob W. wrote: > > Is there a way with my mysql query so that I can list the numbers in > correct order? > In what way is this problem related to PHP? Try a MySQL group instead. -- Hilsen/Regards Michael Rasmussen http://keyserver.veridis.com:11371/pks/lookup

[PHP] Re: mysql query/$post problem

2006-03-27 Thread Barry
Mark wrote: I havnt even tried this query but i know its wrong can anyone help! How do you know it's wrong ? O_o *** $query = "INSERT INTO users (AVATARS) VALUES ('$avname') WHERE id = $user_id"; This works only if the $avname is a STRING! mysql_query($

[PHP] Re: MySql connection error on win XP for script that works on Freebsd 5.3

2005-10-26 Thread Holografix
Hi See this http://dev.mysql.com/doc/refman/5.0/en/old-client.html Best regards "Vizion" <[EMAIL PROTECTED]> escreveu na mensagem news:[EMAIL PROTECTED] >I have just installed MySql on Win XP and am attempting to run a php script >to > create some databases. The script works fine on FreeBSD 5.3

Re: [PHP] Re: mysql table row updation based on user input.

2005-09-18 Thread Jasper Bryant-Greene
John Taylor-Johnston wrote: Me thinks you have to name the checkboxes differently, otherwise the post variable will only take the last value it found, overwriting previous values. Otherwise they act like radioboxes. print " "; No, he's passing an array of checkboxes -- see the

[PHP] Re: mysql table row updation based on user input.

2005-09-18 Thread John Taylor-Johnston
Me thinks you have to name the checkboxes differently, otherwise the post variable will only take the last value it found, overwriting previous values. Otherwise they act like radioboxes. print " "; -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://w

[PHP] Re: mysql problem- I know it isn't strictly php

2005-07-20 Thread Ethilien
That last line always causes me problems, I think it is probably a difference in versions of mysql. Just change the last line to: ); without any of the text in their. It doesn't really do much anyway. Ross wrote: Hi all, I am trying to create a table on the remote server but it never seems t

[PHP] Re: MySQL error

2005-07-01 Thread Jasper Bryant-Greene
Wessley Roche wrote: I'm having a problem with the following code: $sql = "LOAD DATA LOCAL INFILE '/path/to/file.txt' INTO TABLE `mytable` FIELDS TERMINATED BY '\t' ESCAPED BY '\' LINES TERMINATED BY '\n'"; mysql_query($sql) or die(''.mysql_error()); I get this MySQL error: You have an erro

Re: [PHP] Re: MySql injections....

2005-05-11 Thread Richard Lynch
On Wed, May 11, 2005 3:36 am, M. Sokolewicz said: > [EMAIL PROTECTED] wrote: > >> Hi, >> This is not the proper list to put this question but i hope you can help >> me. >> Does anyone know a good tutorial about mysql injections? >> >> Thanks a lot for your help >> >> > what's there to make a tutori

[PHP] Re: MySql injections....

2005-05-11 Thread M. Sokolewicz
[EMAIL PROTECTED] wrote: Hi, This is not the proper list to put this question but i hope you can help me. Does anyone know a good tutorial about mysql injections? Thanks a lot for your help what's there to make a tutorial about? :| If you can get out of a value via a variable, then that means th

[PHP] Re: mysql blob datatype for documents

2005-04-18 Thread Satyam
"Dave Bosky" <[EMAIL PROTECTED]> wrote in message Would it be better to store uploaded pdf, word, or excel documents in a MySql blob field rather than keeping them in a directory? I really want to secure the documents and limit document access to specific users. Curious Dave -

[PHP] Re: mysql regexp select questions

2005-04-07 Thread Eli
Andras Kende wrote: I would like to do the following: mysql db: andrew anthony joe janice john simon sql_query ( select names . I would need only the distinct first character from the query result would be: a,j,s I think maybe its REGEXP but never did it b

Re: [PHP] Re: MySQL empty row

2005-04-05 Thread GamblerZG
DB Error: constraint violation What DB do you use? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Re: MySQL empty row

2005-04-04 Thread Neo Theone
GamblerZG wrote: Please replace die($res->getMessage()) with user_error($res->getMessage(), E_USER_ERROR) and then post the output. on one table it still does not work: this is the error: DB Error: constraint violation -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http:

[PHP] Re: MySQL empty row

2005-04-04 Thread Satyam
You might have changed inadvertently one of the include files. It might have trailing blanks after the final ?>, which obviously you don't see, being blank, but they are echoed to the browser, and the header('location ... then gives an error. Might have nothing to do with the SQl instructions

Re: [PHP] Re: MySQL empty row

2005-04-04 Thread Neo Theone
GamblerZG wrote: Please replace die($res->getMessage()) with user_error($res->getMessage(), E_USER_ERROR) and then post the output. If I uncomment this it seems to work. Not error or anything in the code. Truely don't know what the error is. -- PHP General Mailing List (http://www.php.net/) To un

[PHP] Re: MySQL empty row

2005-04-04 Thread GamblerZG
Please replace die($res->getMessage()) with user_error($res->getMessage(), E_USER_ERROR) and then post the output. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: mySQL outputting XML

2005-03-25 Thread C Drozdowski
There is a pear package that does this: XML_sql2xml. It's at: http://pear.php.net/package-info.php?pacid=18 There is more info at: http://php.chregu.tv/sql2xml/ It's pretty flexible. But not so complicated that you cannot read through the code to figure out what's going on. -- PHP General Mailing

Re: [PHP] Re: mysql problems

2005-03-04 Thread Richard Lynch
Jed R. Brubaker wrote: > Thank you both for your responces. > > Unfotuantely there is no form that instantiates this action. So the double > submit (while a good idea), is not possible. > > As for some sample code, it is part of a rather complicated system that > makes a number of changes but essen

[PHP] Re: mysql problems

2005-03-04 Thread Jon Drukman
Jed R. Brubaker wrote: I have a PHP script that populates a database table. No big deal. It creates mailing labels. However, a weird things keeps happening - every once in a while, a query is run twice. It is the same query, same information, even the same time (there is a now() in the query - a

[PHP] Re: mysql problems

2005-03-03 Thread Jed R. Brubaker
Thank you both for your responces. Unfotuantely there is no form that instantiates this action. So the double submit (while a good idea), is not possible. As for some sample code, it is part of a rather complicated system that makes a number of changes but essentailly what is going on is this:

[PHP] Re: MySQL Error 1251 / phpMyAdmin

2005-02-07 Thread Michael Stassen
The short answer is, download the php source and add --with-mysql=/your/path/to/mysql to your build options. The long answer is in the directions in the php manual . Michael GH wrote: I am still new to the PHP scene could you tell me how I "rebuil

[PHP] Re: MySQL Error 1251 / phpMyAdmin

2005-02-07 Thread GH
I am still new to the PHP scene could you tell me how I "rebuild" the PHP with the client library... On Mon, 07 Feb 2005 12:20:26 -0500, Michael Stassen <[EMAIL PROTECTED]> wrote: > > You have mysql 4.1.8, but your php was built with the library for an earlier > version, which, as the error mess

[PHP] Re: MySQL Error 1251 / phpMyAdmin

2005-02-07 Thread Michael Stassen
You have mysql 4.1.8, but your php was built with the library for an earlier version, which, as the error message says, doesn't support the new, more secure authentication protocol. Your choices are to tell mysql to use the older, less-secure protocol, or build a copy of php using your current

[PHP] Re: MySQL Connection problem

2004-12-11 Thread Peter Lauri
It would be nice if you submit code that generates the error. /Peter "Mike Francis" <[EMAIL PROTECTED]> skrev i meddelandet news:[EMAIL PROTECTED] Hi, I have Apache 2, PHP 5 and MySQL 4.1 installed on an XP pro box. I have created a new database 'ijdb' with a single table 'joke' and have entere

[PHP] Re: MySQL > Excel

2004-11-12 Thread Manuel Lemos
Hello, On 11/12/2004 07:44 PM, Sam Smith wrote: I've got it working writing out a file (fopen) to CSV (comma delimited) and the "header('Content-Disposition: attachment; filename="myFile.csv"')" method but it's clumsy for the user to figure out how to use the file. Is there some totally slick way o

[PHP] Re: MySQL scalability...

2004-10-22 Thread Kevin Grigorenko
"Kevin Grigorenko" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Hello, > > Now, I just found out after implementing this whole solution locally that > when I uploaded to the server, the PHP safe_mode options are on, and > non-overwritable. Therefore, fopen() doesn't even work! >

[PHP] Re: MySQL to OO

2004-09-15 Thread Matthew Weier O'Phinney
* Neo Theone <[EMAIL PROTECTED]>: > I am searching for a MySQl to Object abstraction class. > I am thinking something like WebObjects does in Java (it is just a part) > in PHP. I had one for Ruby but now I have to use a DB in MySQL and such > a class would make it alot easier. > > Does anybody kn

Re: [PHP] RE: MySQL & PHP Examples & Training Providers Required

2004-08-12 Thread Harlequin
Jay, guys. Thanks very much for all your responses on this issue. I'm sorry if I don't always reply through the group but if I am working from the office I have a problem connecting to the mailing list. which is just one of the reasons I prefer working from home. I, along with your help, have ins

RE: [PHP] RE: MySQL & PHP Examples & Training Providers Required

2004-08-12 Thread Jay Blanchard
[snip] > On Wed, 11 Aug 2004 18:20:23 -0400, Lukasz Karapuda <[EMAIL PROTECTED]> wrote: >>Why I chose to reply to your email is because PHP is not usually used for >>the development of more complex functionality like the Web site module that >>we have developed. > > I beg to differ. Many large and

Re: [PHP] RE: MySQL & PHP Examples & Training Providers Required

2004-08-11 Thread Lester Caine
Justin Patrin wrote: On Wed, 11 Aug 2004 18:20:23 -0400, Lukasz Karapuda <[EMAIL PROTECTED]> wrote: Why I chose to reply to your email is because PHP is not usually used for the development of more complex functionality like the Web site module that we have developed. I beg to differ. Many large an

Re: [PHP] RE: MySQL & PHP Examples & Training Providers Required

2004-08-11 Thread Justin Patrin
On Wed, 11 Aug 2004 18:20:23 -0400, Lukasz Karapuda <[EMAIL PROTECTED]> wrote: > Michael, > > My company has recently developed a Web site module for a local > manufacturing company. The Web site module is a PHP and MySQL application > composed of several screens and advanced engineering functiona

[PHP] RE: MySQL & PHP Examples & Training Providers Required

2004-08-11 Thread Lukasz Karapuda
Michael, My company has recently developed a Web site module for a local manufacturing company. The Web site module is a PHP and MySQL application composed of several screens and advanced engineering functionality (graphing, calculations etc). One of the database tables for the application has ove

Re: [PHP] Re: [mysql]Problem with PHP5

2004-07-19 Thread [EMAIL PROTECTED]
Ciprian, I may have missed whether or not you were able to resolve your problem from a couple days ago. In one of my development environments (Win2K), I decided to install PHP 5.0 with MySQL(i) 4.1.x support in IIS5.0 and Apache 2 (running on different ports). It took a bit more work than I in

  1   2   3   4   >