[PHP] Re: php-mysql problem

2007-04-03 Thread itoctopus
$sql = "SELECT count(Email) as numEmails, Email FROM mena_guests WHERE Voted='yes' GROUP BY Email ORDER BY numEmails DESC LIMIT $startingID, $items_numbers_list"; I answered this morning, I don't know why it got deleted -- itoctopus - http://www.itoctopus.com ""Me2resh Lists"" <[EMAIL PROTECTED]>

[PHP] Re: php-mysql problem

2007-04-03 Thread itoctopus
$sql = "SELECT count(Email) as numEmails, Email FROM mena_guests WHERE Voted='yes' GROUP BY Email ORDER BY numEmails DESC LIMIT $startingID, $items_numbers_list"; -- itoctopus - http://www.itoctopus.com ""Me2resh Lists"" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > hi > i need hel

Re: [PHP] Re: php mysql problem

2006-05-03 Thread chris smith
On 5/3/06, Richard Lynch <[EMAIL PROTECTED]> wrote: On Tue, May 2, 2006 7:22 am, chris smith wrote: > On 5/2/06, Ross <[EMAIL PROTECTED]> wrote: >> This is my database now...I will use the item_id for the order but >> what if I >> want to change item_id 3 to item id 1? How can I push all the item

Re: [PHP] Re: php mysql problem

2006-05-03 Thread Richard Lynch
On Tue, May 2, 2006 7:22 am, chris smith wrote: > On 5/2/06, Ross <[EMAIL PROTECTED]> wrote: >> This is my database now...I will use the item_id for the order but >> what if I >> want to change item_id 3 to item id 1? How can I push all the items >> down one >> place? How can I delete any gaps when

Re: [PHP] Re: php mysql problem

2006-05-03 Thread Richard Lynch
On Tue, May 2, 2006 7:05 am, Ross wrote: > This is my database now...I will use the item_id for the order but > what if I > want to change item_id 3 to item id 1? How can I push all the items > down one > place? How can I delete any gaps when items are deleted. Change item_id 3 to 1. ... select i

Re: [PHP] Re: php mysql problem

2006-05-02 Thread Dave Goodchild
Exactly - I don't think you really understand how a relational database works. The ids are retained as they may relate to records in another table. Internal sorting order is of no relevance at the application level. I think you need to rethink your design a little. On 02/05/06, T.Lensselink <[EMA

Re: [PHP] Re: php mysql problem

2006-05-02 Thread T.Lensselink
> This is my database now...I will use the item_id for the order but what if > I > want to change item_id 3 to item id 1? How can I push all the items down > one > place? How can I delete any gaps when items are deleted. > > > CREATE TABLE `board_papers` ( > `id` int(4) NOT NULL auto_increment, >

Re: [PHP] Re: php mysql problem

2006-05-02 Thread chris smith
On 5/2/06, Ross <[EMAIL PROTECTED]> wrote: This is my database now...I will use the item_id for the order but what if I want to change item_id 3 to item id 1? How can I push all the items down one place? How can I delete any gaps when items are deleted. Why do you want to do that? There's no be

[PHP] Re: php mysql problem

2006-05-02 Thread Ross
This is my database now...I will use the item_id for the order but what if I want to change item_id 3 to item id 1? How can I push all the items down one place? How can I delete any gaps when items are deleted. CREATE TABLE `board_papers` ( `id` int(4) NOT NULL auto_increment, `doc_date` va

[PHP] Re: php mysql problem

2006-05-02 Thread Barry
Ross schrieb: Just say I have a db CREATE TABLE `mytable` ( `id` int(4) NOT NULL auto_increment, `fileName` varchar(50) NOT NULL default '', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=latin1 AUTO_INCREMENT=7 ; when I add items they go id 1,2,3 etc. Whn I delete them gaps appear. 1

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

2005-07-20 Thread Mikey
Ross wrote: Hi all, I am trying to create a table on the remote server but it never seems to work CREATE TABLE `sheet1` ( `id` int(10) NOT NULL auto_increment, `title` varchar(255) NOT NULL default '', `fname` varchar(255) NOT NULL default '', `sname` varchar(255) default NULL, `job_tit

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

2005-07-19 Thread Jay Blanchard
[snip] 1064 - 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 'DEFAULT CHARSET=latin1 AUTO_INCREMENT=303' at line 18 and this is what the manual says (not very helpful) a.. Error: 1064 SQLSTATE: 42000 (ER_PA

[PHP] Re: PHP, MySQL problem

2004-01-14 Thread Jan Grafström
Hi Add records with this code. name address Hope this helps. Jan "Nicolai Elmqvist" <[EMAIL PROTECTED]> skrev i meddelandet news:[EMAIL PROTECTED] > Hi > > I have just started working with PHP and MySQL and have gone through 3 > tutorials on how to add and delete records from a databa

Re: [PHP] MySQL Problem

2003-06-05 Thread Oscar F
Felipe, I'm replying in spanish so you can understand better. El problema que tienes es que la variable $nueva_base esta vacia. Si deseas especificar el nombre con esa variable debes asignarle algun valor antes de llamarla, si lo que quieres es crear una base de datos que se llame nueva_base,

RE: [PHP] MySQL problem with RedHat 8

2003-01-15 Thread Daniel Elenius
> Dimension Networks, Inc. > (727) 723-8388 > > -Original Message- > From: Daniel Elenius [mailto:[EMAIL PROTECTED]] > Sent: Tuesday, January 14, 2003 5:22 PM > To: [EMAIL PROTECTED] > Subject: Re: [PHP] MySQL problem with RedHat 8 > > Yes, mysql.so is in /usr

Re: [PHP] MySQL problem with RedHat 8

2003-01-14 Thread Daniel Elenius
Yes, mysql.so is in /usr/lib/php4. The php.ini file has this in it: [daniel@p85 etc]$ grep mysql php.ini ;extension=php_mysql.dll extension=mysql.so mysql.allow_persistent = On mysql.max_persistent = -1 mysql.max_links = -1 ; Default port number for mysql_connect(). If unset, mysql_connect() will

Re: [PHP] MySQL problem with RedHat 8

2003-01-14 Thread Joseph W. Goff
Make sure that the shared module is in the correct directory. Check your php.ini file to make sure but it is most likely at /usr/lib/php4 make sure that you have mysql.so - Original Message - From: "Daniel Elenius" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Tuesday, January 14, 2003

Re: [PHP] mysql problem

2002-10-03 Thread Marek Kilimajer
Look into the logs, they should be more verbose. How did you install the three. BB wrote: >I seem to have a php-mysql problem on my new Sun Qube3 (RH Linux). >php works fine, mysql works fine, apache works fine, only the combination of >the three seems troublesome. >php does not recognize comma

Re: [PHP] MySQL Problem with PHP

2002-06-26 Thread BB
I understand about the concat function, but that doesn't really fit into my scheme of things I run all text for the web through a function SafeSQL so that values from the web don't make SQL error or potential hacks occur. All SafeSQL was doing (for mssql, access and just about any other db) was

RE: [PHP] MySQL Problem with PHP

2002-06-26 Thread John Holmes
> INSERT INTO `contracts` (`key`, `content`) VALUES (1,'blah blah blah > character 39 is a single speach mark '+CHAR(39)+' blah blah blah') That's because you are adding strings together, not concatenating them (this isn't javascript!) Use CONCAT() in MySQL to join strings together. mysql> sel

Re: [PHP] MySQL problem

2001-12-30 Thread GoodFella
- Original Message - From: David Jackson To: [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] ; [EMAIL PROTECTED] Sent: Monday, December 31, 2001 2:41 AM Subject: Re: [PHP] MySQL problem I almost forgot add a or mysql_error() for each line like this: This will return "

Re: [PHP] MySQL problem

2001-12-30 Thread David Jackson
> From: David Jackson > To: [EMAIL PROTECTED] > Cc: [EMAIL PROTECTED] > Sent: Monday, December 31, 2001 1:48 AM > Subject: Re: [PHP] MySQL problem > > > Here's the example from the PHP manual: > The tutorial here are very helpfull: >

Re: [PHP] MySQL problem

2001-12-30 Thread Brian Clark
* GoodFella ([EMAIL PROTECTED]) [Dec 30. 2001 21:10]: > Thanks for the quick reply. I used the PHP manual example and it connects > to the database successfully but cannot select the database. So you are using this line: > > mysql_select_db("booktest"); Correct? What does the server "say" i

Re: [PHP] MySQL problem

2001-12-30 Thread GoodFella
rom: David Jackson To: [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Sent: Monday, December 31, 2001 1:48 AM Subject: Re: [PHP] MySQL problem Here's the example from the PHP manual: The tutorial here are very helpfull: http://www.melonfire.com/community/columns/trog/ -- David

Re: [PHP] MySQL problem

2001-12-30 Thread David Jackson
Here's the example from the PHP manual: The tutorial here are very helpfull: http://www.melonfire.com/community/columns/trog/ -- David \n"; while ($line = mysql_fetch_array($result, MYSQL_ASSOC)) { print "\t\n"; foreach ($line as $col_value) { print "\t\t$col_value\n"; }

RE: [PHP] mySQL problem

2001-11-02 Thread Jon Snell
The issue here is that you aren't getting an index of "Company" from that query. It is probably stored under the index of "UCASE(Company)". Try: $Query = "SELECT UCASE(Company) as ucCompany, Icons, ID,..."; Then the ucCompany field will contain your capitalized company data. Jon -Origina

RE: [PHP] mySQL problem

2001-11-02 Thread Niklas Lampén
"SELECT UCASE(Company) AS Company" works great, thanks! Niklas -Original Message- From: Dimitris Kossikidis [mailto:[EMAIL PROTECTED]] Sent: 2. marraskuuta 2001 11:11 To: 'Niklas Lamp¨¦n' Cc: PHP General Subject: RE: [PHP] mySQL problem Try this $Query = &

RE: [PHP] mySQL problem

2001-11-02 Thread Dimitris Kossikidis
Try this $Query = "SELECT UCASE(Company) as company, Icons, ID, LogoD FROM feComps"; List ( $company, $icons, etc ) = mysql_fetch_row( ); > -Original Message- > From: Niklas Lamp&igr;n [mailto:[EMAIL PROTECTED]] > Sent: Friday, November 02, 2001 10:22 AM > To: Php-General > Subj

RE: [PHP] mySQL problem

2001-11-02 Thread Dimitris Kossikidis
Try this $Query = "SELECT UCASE(Company) as company, Icons, ID, LogoD FROM feComps"; List ( $company, $icons, etc ) = mysql_fetch_row( ); > -Original Message- > From: Niklas Lamp&igr;n [mailto:[EMAIL PROTECTED]] > Sent: Friday, November 02, 2001 10:22 AM > To: Php-General > Subj

RE: [PHP] MySQL problem

2001-07-04 Thread Simon Kimber
Sorry!!! I'm stupid! I forgot to mention that the list of causes has to be for a specified accident_report.weekending Cheers Simon > -Original Message- > From: Don Read [mailto:[EMAIL PROTECTED]] > Sent: 04 July 2001 23:21 > To: Simon Kimber > Cc: [EMAIL PROTECTED]

RE: [PHP] MySQL problem

2001-07-04 Thread Don Read
On 04-Jul-01 Simon Kimber wrote: > Hi All, > > Does anyone know if this can be done with one query? > > I have to create a chart based on info in two tables that are four tables > apart. > > Here are the relevant tables and just the most relevant fields... > > accident_report > - ID > - weeke

Re: [PHP] MySQL problem...

2001-04-26 Thread Thimo von Rauchhaupt
Generally spoken, echo the SQL-Statement, and paste it in your local MySql Client (e.g. MySql-Font). These Frontends give you a better error, and you´ll find the problem in seconds. (hope so) ""Peter Houchin"" <[EMAIL PROTECTED]> schrieb im Newsbeitrag [EMAIL PROTECTED]">news:[EMAIL PROTECTED]..

RE: [PHP] MySQL problem...

2001-04-25 Thread Maxim Maletsky
[EMAIL PROTECTED] www.phpbeginner.com -Original Message- From: Brian Rue [mailto:[EMAIL PROTECTED]] Sent: Thursday, April 26, 2001 12:24 PM To: [EMAIL PROTECTED] Subject: Re: [PHP] MySQL problem... Here's all the code that uses MySQL... $db = mysql_connect("localhost",&

Re: [PHP] MySQL problem...

2001-04-25 Thread Brian Rue
Here's all the code that uses MySQL... $db = mysql_connect("localhost","user","pass"); mysql_select_db("db",$db); $gmdquery="SELECT * FROM game_of_the_day"; $the_info = mysql_query($gmdquery,$db); while ($myrow = mysql_fetch_row($the_info)) { (get info from the result) } ... (dec

RE: [PHP] MySQL problem...

2001-04-25 Thread Maxim Maletsky
it might also be the characters escaping. Sincerely, Maxim Maletsky Founder, Chief Developer PHPBeginner.com (Where PHP Begins) [EMAIL PROTECTED] www.phpbeginner.com -Original Message- From: Brian Rue [mailto:[EMAIL PROTECTED]] Sent: Thursday, April 26, 2001 9:28 AM To: [EMAIL P

RE: [PHP] MySQL problem...

2001-04-25 Thread Peter Houchin
some code would be nice to have a look at :) Other than that, check table names, database names, also your result lines, I've found i get that error by not calling a result or calling the incorrect table/database Peter -Original Message- From: Brian Rue [mailto:[EMAIL PROTECTED]

RE: [PHP] MySQL problem - stumped

2001-03-10 Thread John Vanderbeck
identifier. Grr.. Thanks again. Your a deadline saver :) - John Vanderbeck - Admin, GameDesign > -Original Message- > From: Christian Reiniger [mailto:[EMAIL PROTECTED]] > Sent: Saturday, March 10, 2001 2:32 PM > To: PHP User Group > Subject: Re: [PHP] MySQL problem - stum

RE: [PHP] MySQL problem - stumped

2001-03-10 Thread John Vanderbeck
that call. - John Vanderbeck - Admin, GameDesign > -Original Message- > From: Julian Wood [mailto:[EMAIL PROTECTED]] > Sent: Saturday, March 10, 2001 2:28 PM > To: John Vanderbeck; PHP User Group > Subject: Re: [PHP] MySQL problem - stumped > > > > Well, PHP

Re: [PHP] MySQL problem - stumped

2001-03-10 Thread Christian Reiniger
On Saturday 10 March 2001 19:58, you wrote: > The following code is giving an me problems, I can't figure it out to > save my soul. The last line gives: > > Here is the code: > > $link = db_connect(); > $query = "UPDATE Users SET firstname='$firstname', lastname='$lastname' > WHERE username='$use

RE: [PHP] MySQL problem - stumped

2001-03-10 Thread Matt Williams
> > >The following code is giving an me problems, I can't figure it > > out to save > > >my soul. The last line gives: > > > > > >Here is the code: > > > > > >$link = db_connect(); > > >$query = "UPDATE Users SET firstname='$firstname', lastname='$lastname' > > >WHERE username='$user' && password

Re: [PHP] MySQL problem - stumped

2001-03-10 Thread Julian Wood
&. But the > problem remains. Same error. > Any other ideas? > > - John Vanderbeck > - Admin, GameDesign > >> -Original Message- >> From: Rick St Jean [mailto:[EMAIL PROTECTED]] >> Sent: Saturday, March 10, 2001 2:09 PM >> To: PHP User Grou

RE: [PHP] MySQL problem - stumped

2001-03-10 Thread John Vanderbeck
> From: Rick St Jean [mailto:[EMAIL PROTECTED]] > Sent: Saturday, March 10, 2001 2:09 PM > To: PHP User Group > Subject: Re: [PHP] MySQL problem - stumped > > > At 01:58 PM 3/10/01 -0500, John Vanderbeck wrote: > > > You are using && in your statement ... should b

Re: [PHP] MySQL problem - stumped

2001-03-10 Thread Ernest E Vogelsinger
At 19:58 10.03.2001, John Vanderbeck said: [snip] >$query = "UPDATE Users SET firstname='$firstname', lastname='$lastname' >WHERE username='$user' && password='$password'"; [snip] Try "AND" instead of "&&", this shou

Re: [PHP] MySQL problem - stumped

2001-03-10 Thread Rick St Jean
At 01:58 PM 3/10/01 -0500, John Vanderbeck wrote: You are using && in your statement ... should be "AND" . >The following code is giving an me problems, I can't figure it out to save >my soul. The last line gives: > >Here is the code: > >$link = db_connect(); >$query = "UPDATE Users SET firs

Re: [PHP] mysql problem

2001-02-19 Thread Thomas Deliduka
I think if you echo the error (echo mysql_error();) you will see the exact error you would get if connected directly to the db. You can do something like: $result = @mysql_query($sql_query); // hide any errors If (!$result) { echo "Error: " . Mysql_error() . ""; } On 2/20/01 2:57 AM this wa

RE: [PHP] mysql problem

2001-02-19 Thread ..s.c.o.t.t..
TECTED]] > Sent: Monday, February 19, 2001 17:00 > To: PHP User Group > Subject: Re: [PHP] mysql problem > > > Ok, I've fixed the problem, it seems there's some major differences > between the linux / win32 ports of the client. > > instead of > > blah in

Re: [PHP] mysql problem

2001-02-19 Thread Josh G
AIL PROTECTED]> Sent: Tuesday, February 20, 2001 11:42 AM Subject: Re: [PHP] mysql problem > Nope, I've been using autoincrement on that box for a year or so. > > It's not a copy/paste thing, cause I'm getting it when I type the lines > in by hand, too... > > Gfu

Re: [PHP] mysql problem

2001-02-19 Thread Josh G
hangovers, and hangovers to... suffering. - Original Message - From: "David Robley" <[EMAIL PROTECTED]> To: "Josh G" <[EMAIL PROTECTED]>; "PHP User Group" <[EMAIL PROTECTED]> Sent: Tuesday, February 20, 2001 11:41 AM Subject: Re: [PHP] my

Re: [PHP] mysql problem

2001-02-19 Thread David Robley
On Tue, 20 Feb 2001 10:57, Josh G wrote: > Hi, sorry to post this here, but it's driving me crazy. On my local > machine, the following works no furys: > > create table category (category_id integer primary key > auto_increment,name varchar(255) ); > > But on the production machine, I get: > > ERR