Page 1 of 1

Querying the database?

Posted: Thu May 22, 2008 7:18 pm
by Yourchild
I thought I'd ask the question here, since many of php-ers are familiar with mysql techniques.

I have a data table as follows:

Code: Select all

 
messageID    |      message           
---------------------------   
1                       "hi"        
2                       "hello"    
3                       "apple"   
4                       "orange"
5                       "banana"
6                       "grape"
 

I want to select 'hello, apple, orange, banana' only.

How do I write the query for this? I have a hold of the first messageID of the output, which is 2 (hello). How can I use this in my query?

Please help.

Re: Querying the database?

Posted: Thu May 22, 2008 7:25 pm
by Yourchild
ummm nevermind i have the answer thanks for reading. :roll:

Re: Querying the database?

Posted: Fri May 23, 2008 2:29 am
by Sindarin
Please include the answer if a topic is solved, that way we can make use of it, as well. :wink: