RE: [PHP-DB] Query Error
| From: | Robert Sossomon | Date: | Tue, 04 Nov 2003 19:49:27 +0000 |
| Subject: | RE: [PHP-DB] Query Error | ||
| References: | 1 | Groups: | php.db |
| Request: | Send a blank email to php-db+get-31419@lists.php.net to get a copy of this message | ||
That fixed the output to actually find the information, however I'll be
danged if it is not adding the items to the database.
In fact I am seeing errors with it adding half the stuff to the database
from stuff that was working.
I rebooted the system. Removed the database, stopped the server.
Started the server. Reloaded the database. Refreshed the data. Now I
am not seeing stuff added to the system and I have no idea why.
According to the scripts everything is working fine. The information is
being passed to the pages correctly and even the output on the page
showed that the data was correct for insertion, however when I look at
the database where the information should be, it is not there. I'm
losing my mind!
Any thoughts?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
A horse! A horse! My kingdom for a horse!
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-----Original Message-----
From: CPT John W. Holmes [mailto:holmes072000@charter.net]
Sent: Tuesday, November 04, 2003 1:31 PM
To: Robert Sossomon; php-db@lists.php.net
Subject: Re: [PHP-DB] Query Error
From: "Robert Sossomon" <robert@gcnorris.com>
> The errors as it prints are:
>
> The query I just ran was: select * from GCN_items where
>
item_num =
> '%fm-a294%' The query I just ran was: Resource id #2 0
Those aren't errors; it's just what you asked the script to display.
Your query simply isn't returning any rows.
You should be using LIKE instead of the equal sign, since I assume
you're looking for a pattern.
select * from GCN_items where item_num LIKE '%fm-a294%'
otherwise you're looking for the literal string "%fm-a294%"
---John Holmes...
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php