niche Posted April 25, 2012 Share Posted April 25, 2012 (edited) This code produces: Column 'subcategory' in where clause is ambiguous "SELECT * FROM stk INNER JOIN plan ON stk.cliorder=plan.cliorder WHERE subcategory = '" . $keyword . "'" What do you think the problem is? Edited April 25, 2012 by niche 1 Link to comment Share on other sites More sharing options...
niche Posted April 25, 2012 Author Share Posted April 25, 2012 Just after I posted, I tried: "SELECT * FROM stk INNER JOIN plan ON stk.cliorder=plan.cliorder WHERE stk.subcategory = '" . $keyword . "'" and was successful. This was the first time I've used WHERE with JOIN. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now