首页 > 数据库技术 > 详细

取得数据库中数据 查询条件where使用规则

时间:2014-11-28 13:55:36      阅读:286      评论:0      收藏:0      [点我收藏+]

string where = string.Format("DnX < {0} and DnD > {0} and Types = ‘{1}‘ and Type1 = ‘{2}‘ and Type2 = ‘{3}‘ and Baojiao = {4} and HasPad = {5}"
, DI, cbTypes.Text, cbType1.Text, cbType2.Text, double.Parse(cbBaojiao.Text),ccbPad.Checked);

字符串要带‘’号 不带引号的类型要转化 

取得数据库中数据 查询条件where使用规则

原文:http://www.cnblogs.com/xzh1993/p/4128167.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!