Page 1 of 1

help with extracting from a database

Posted: Mon Sep 09, 2002 7:11 am
by m3mn0n
Here is the table

-----------------------
|ID-|Col1-|Col2-|
|--------------------|
|1--|Wrd1-|Wrd2|
-----------------------

maybe it's because i'm sleepy as hell or too much stress, but i can't figure this out...

How would i do a query if Wrd1 was picked, it shows *only* Wrd2?

thx

Posted: Mon Sep 09, 2002 7:26 am
by 9902468
Explain more...

Posted: Mon Sep 09, 2002 7:29 am
by m3mn0n
This is a translation type search engine.

If a user inputs a a word into a form where the value = wrd1 and sends it to the handle page, i want on the handle page to show only wrd2.

Posted: Mon Sep 09, 2002 7:41 am
by Takuma

Code: Select all

SELECT col2 FROM table WHERE col1 = 'string'

Posted: Mon Sep 09, 2002 8:58 am
by m3mn0n
thx much! 8)