SQL probems
3 posts
• Page 1 of 1
SQL probems
Anyone know why this SQL query doesnt work?
SELECT * FROM enquirys WHERE action='1' AND WHERE record_type='1' ORDER BY id_number DESC
Thanks
Stuart
Linux Master
Currently hosting 17 Linux servers
Currently hosting 17 Linux servers
You should be able to concatenate "where"s with an AND, not AND WHERE. I think it will work then, unless I'm missing something else.
Good luck,
-TC
K6-II 300MHz - PCChips M571 (ALi chipset) - S3 Virge (2MB) - Processor Fan with Attached Heat Sink - Power Supply with Onboard Fuse - 128MB 72-Pin SIMM Ram - 8GB Quantum Fireball 5.25" - 100 Mbps NIC - Redhat 7.1
The second WHERE clause is not necessary in this query.
use this instead
use this instead
- Code: Select all
SELECT * FROM enquirys WHERE action='1' AND record_type='1' ORDER BY id_number DESC
ZeroByte
- ZeroByte
- Posts: 1199
- Joined: Thu Aug 01, 2002 2:12 am
- Location: Mexico, NY
- Real Name: Mike Sheats
3 posts
• Page 1 of 1
Return to HTML, CSS, and Scripts
Who is online
Users browsing this forum: No registered users and 2 guests