摘要: 1<scripttype="text/javascript">23varxmlhttp;4varurl="ajax.aspx";56functioncreatexmlttp(){78if(window.XMLHttpRequest){9xmlhttp=newXMLHttpRequest();10}1112if(window.ActiveXobject){13try{1415xmlhttp=newActiveXObject("Microsoft.XMLHTTP");16}17catch(e){1819try{20xmlhtt 阅读全文
posted @ 2011-05-18 15:47 Code & Life 阅读(336) 评论(0) 推荐(0) 编辑
摘要: 今天在操作数据库时,需要将字符串转换成Decimal类型。代码如下:select cast('0.12' as decimal(18,2)); select convert(decimal(18,2), '0.12');当需要将科学计数法的数字字符串转换成Decimal时,这2种写法都报错:Msg 8114, Level 16, State 5, Line 1Error converting data type varchar to numeric.select cast('0.12e+006' as decimal(18,2)); select 阅读全文
posted @ 2011-05-18 15:34 Code & Life 阅读(5382) 评论(0) 推荐(0) 编辑