database - SQL IS NULL logic error -
database - SQL IS NULL logic error -
i'm new forum i'm not sure if it's post twice same questions seems lastly question sort of died out , kind of have new question, here is
i wanted programme if combo box empty, mean select (or imagine ignore where
clause start out with). reply found throughout net utilize param = @param or @param null
. however, when , want display data, shows column row names (meaning got right table) no data. i'm not sure why, read method sort of if statement. here's code simplified jut problem
da.selectcommand = new oledbcommand("select * testquery customername = @customername or @customername null)", cs); da.selectcommand.parameters.add("@customername", oledbtype.varchar).value = combo_customerview.text.tostring();
da = info adapter. i'm using visual studio 2010 , ado.net oledb (access). works when have info on client when theres none, problem described above. sorta help helpful... thanks
sql database visual-studio-2010 ms-access ado.net
Comments
Post a Comment