RE: [PHP-DB] WHERE field = str

2001-07-25 Thread Boget, Chris

 I am trying to find a str within a field using a select statement like
 SELECT * FROM tablename WHERE fieldname has the string within it
 Is there a way to do this?

WHERE fieldname LIKE %$string%

Chris



RE: [PHP-DB] WHERE field = str

2001-07-25 Thread Boget, Chris

 I searched everything I could think of. Where should I have 
 found this is the manual?

Nowhere in the PHP manual, I think.  But you could find
info on this in the MySQL manual (or any other db server's
documentation...)

Chris



RE: [PHP-DB] WHERE field = str

2001-07-25 Thread Matthew Loff


Certainly not in the PHP manual, and LIKE isn't really covered in the
MySQL manual either...

Here's a good page with an intro to SQL queries:
http://developer.ecorp.net/sqltut.htm

--Matt


-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] 
Sent: Wednesday, July 25, 2001 2:46 PM
To: PHP DataBase-List
Subject: Re: [PHP-DB] WHERE field = str


Thanks Chris
I searched everything I could think of. Where should I have found this
is the manual? Dave


|  I am trying to find a str within a field using a select statement 
|  like SELECT * FROM tablename WHERE fieldname has the string within 
|  it Is there a way to do this?
| 
| WHERE fieldname LIKE %$string%
| 
| Chris
| 

[EMAIL PROTECTED]

SeaPortNetHosting: Reliable Web Hosting
Plans from $17.95 www.yourname.com
http://www.SeaPortNet.com/
1(209)551-7028 

-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]


-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




RE: [PHP-DB] WHERE field = str

2001-07-25 Thread Paul DuBois

At 2:55 PM -0400 7/25/01, Matthew Loff wrote:
Certainly not in the PHP manual, and LIKE isn't really covered in the
MySQL manual either...

Of course it is.

http://www.mysql.com/doc/S/t/String_comparison_functions.html



Here's a good page with an intro to SQL queries:
http://developer.ecorp.net/sqltut.htm

--Matt


-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, July 25, 2001 2:46 PM
To: PHP DataBase-List
Subject: Re: [PHP-DB] WHERE field = str


Thanks Chris
I searched everything I could think of. Where should I have found this
is the manual? Dave


|  I am trying to find a str within a field using a select statement
|  like SELECT * FROM tablename WHERE fieldname has the string within
|  it Is there a way to do this?
|
| WHERE fieldname LIKE %$string%
|
| Chris
|

[EMAIL PROTECTED]

SeaPortNetHosting: Reliable Web Hosting
Plans from $17.95 www.yourname.com
http://www.SeaPortNet.com/
1(209)551-7028


-- 
Paul DuBois, [EMAIL PROTECTED]

-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




RE: [PHP-DB] WHERE field = str

2001-07-25 Thread Matthew Loff


Good call, Paul...

I checked through the manual briefly to see if LIKE was in there, I
guess I missed that page.  


-Original Message-
From: Paul DuBois [mailto:[EMAIL PROTECTED]] 
Sent: Wednesday, July 25, 2001 5:08 PM
To: Matthew Loff; [EMAIL PROTECTED]; 'PHP DataBase-List'
Subject: RE: [PHP-DB] WHERE field = str


At 2:55 PM -0400 7/25/01, Matthew Loff wrote:
Certainly not in the PHP manual, and LIKE isn't really covered in the 
MySQL manual either...

Of course it is.

http://www.mysql.com/doc/S/t/String_comparison_functions.html



Here's a good page with an intro to SQL queries: 
http://developer.ecorp.net/sqltut.htm

--Matt


-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, July 25, 2001 2:46 PM
To: PHP DataBase-List
Subject: Re: [PHP-DB] WHERE field = str


Thanks Chris
I searched everything I could think of. Where should I have found this 
is the manual? Dave


|  I am trying to find a str within a field using a select statement 
|  like SELECT * FROM tablename WHERE fieldname has the string within 
|  it Is there a way to do this?
|
| WHERE fieldname LIKE %$string%
|
| Chris
|

[EMAIL PROTECTED]

SeaPortNetHosting: Reliable Web Hosting
Plans from $17.95 www.yourname.com
http://www.SeaPortNet.com/
1(209)551-7028


-- 
Paul DuBois, [EMAIL PROTECTED]


-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]