euphoric Posted October 6, 2009 Report Share Posted October 6, 2009 (edited) SELECT * WHERE a='1' AND b='2' Gribu izvadīt info ar papildus kritēriju kur WHERE c='0', bet var jau tikai divus ?! :/ Līdz šim, parbaudīju ar if'u, ja c='0', tad... Varbūt varat ieteikt kā savadak izvadīt info pēc vairākiem 'kritērijiem' ? Paldies :) Edited October 6, 2009 by euphoric Quote Link to comment Share on other sites More sharing options...
Aleksejs Posted October 6, 2009 Report Share Posted October 6, 2009 Nē, var daudzus: SELECT * FROM tabula WHERE a=1 AND b=2 AND c=0 Quote Link to comment Share on other sites More sharing options...
waplet Posted October 6, 2009 Report Share Posted October 6, 2009 kāpēc domā ka tikai AND var vienu? Quote Link to comment Share on other sites More sharing options...
euphoric Posted October 6, 2009 Author Report Share Posted October 6, 2009 hmmm.. Mēģināju , man bija errors, sory, laikam būšu pats pieļāvis kkadu kļūdu :/ Quote Link to comment Share on other sites More sharing options...
Grey_Wolf Posted October 6, 2009 Report Share Posted October 6, 2009 principaa SQL ir sameraa Elestiigs saja zinjaa .. var ne tikai AND bet arii OR teiksim: (x=1 AND y=2) OR (x=5 AND y=6) Tas ir var izmantot arii iekavas , kas dazjos gadijumos paliidz atrisinat nevienu vien problemu Quote Link to comment 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.