select语句有问题 [英] Problem with select statement
本文介绍了select语句有问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
亲爱的专家,
期望select语句排除
Dear Expert,
Expecting the select statement to exclude
'DISBURSED','DENIED'
但是上市包括他们
SqlDataAdapter da = new SqlDataAdapter(select * from Apprs_Mast WHERE Facility_Status NOT IN('DISBURSED','DENIED')订购Appraisal_No,连接);
select语句是否正确?
however the listing includes them
SqlDataAdapter da = new SqlDataAdapter("select * from Apprs_Mast WHERE Facility_Status NOT IN ('DISBURSED','DENIED') order by Appraisal_No", connect);
Is the select statement correct ?
推荐答案
只需检查Facility_Status列的类型是否为varchar!如果没有,请根据字句取消'DISBURSED','DENIED'。
Just check the type of "Facility_Status" column is varchar or not ! if not please the 'DISBURSED','DENIED' according to the collumn.
尝试选择你想要排除的那些能给你答案吗?
Try to select the ones you want to exclude does that give you the answer you would expect?
select * from Apprs_Mast WHERE Facility_Status ='DISBURSED' OR Facility_Status ='DENIED' order by Appraisal_No
你会期望这个查询到告诉你一些记录 - 如果不是'DISBURSED'和'DENIED'
You would expect this query to show you some records - if it doesn't the values are not 'DISBURSED' and 'DENIED'
的话
这篇关于select语句有问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文