Mombu the Php Forum

Go Back   Mombu the Php Forum > Php > Selecting Rows Based on Row Values Being in Array
User Name
Password
REGISTER NOW! Mark Forums Read




Reply Bookmark and Share
1 3rd October 10:32
lists
External User
 
Posts: 1
Default Selecting Rows Based on Row Values Being in Array



???

What is wrong with the above statement?

This should be an easy one for you to figure out?


..
..
..
..
..
..
..
..
..
..
..
..
..
..
..
..
..
..
..
..
..
..
..
..
..
..
..
..
..
..
..
..
..
..
..
..

Give up?

Well, looks like you are inserting the sql statement inside it self

It should look like this

SELECT *
FROM shoe
WHERE CONCAT( size, color, weight ) IN('7orange50lbs','8purple60lbs')


not

SELECT *
FROM shoe
WHERE CONCAT( size, color, weight )
IN (SELECT * FROM shoe WHERE CONCAT(size,color,weight)
IN('7orange50lbs','8purple60lbs')

Notice the sub-select???

Find where you are inserting the SQL into itself and remove it, and you
might have the answer to your problems.

Jim
  Reply With Quote


 


Reply


Thread Tools
Display Modes


Some other forums that might be of your interest : Php 5 forum, Apache forum, Iis forum, Functions forum, Classes forum, Librarys forum, Bugs forum, Postgres forum, Mysql forum, Paradox forum, Ms sql forum, Configurations forum, Php.ini forum, Problems forum, Scripting forum, Css forum, General forums, Off-topic talk, Links, Extra forums, Php


Copyright © 2006 SmartyDevil.com - Dies Mies Jeschet Boenedoesef Douvema Enitemaus -
666