rcharris Posted August 20, 2006 Share Posted August 20, 2006 Hi all, apologies for the possible n00bness of this post, but I'm self taugh, and i've never done this query beforeI have a query running at the moment which is[quote]SELECT title, id, type, description, updated FROM portfolio WHERE type = \'Web Design and Build\' ORDER BY id DESC[/quote]but what I want the query to do is, yes, still retrieve that type, but only rows with a type of Web Design and Build, and "Main Page"Any ideas?Muchly grateful in advance :),rcharris Quote Link to comment https://forums.phpfreaks.com/topic/18129-simple-query/ Share on other sites More sharing options...
AndyB Posted August 20, 2006 Share Posted August 20, 2006 [code]SELECT title, id, type, description, updated FROM portfolio WHERE type IN('Web Design and Build','Main Page') ORDER BY id DESC[/code] Quote Link to comment https://forums.phpfreaks.com/topic/18129-simple-query/#findComment-77719 Share on other sites More sharing options...
rcharris Posted August 20, 2006 Author Share Posted August 20, 2006 Hi there,Seem to get a [quote]Parse error: parse error, unexpected T_STRING in \path\i\do\not\wanr\to\release\Web Design and Build.php on line 174[/quote] error and I cant see where! Quote Link to comment https://forums.phpfreaks.com/topic/18129-simple-query/#findComment-77723 Share on other sites More sharing options...
AndyB Posted August 20, 2006 Share Posted August 20, 2006 Probably a problem with mismatched ' and " quotes. Better show us a dozen or so lines up to and including line 174 ... Quote Link to comment https://forums.phpfreaks.com/topic/18129-simple-query/#findComment-77779 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.