我保存到文本文件已经订购了多少食物,我总是需要更新号码,我该怎么做?它总是重置它......
我尝试了这个,但它没有工作:
create table #something
(
FieldName varchar(25)
, Before varchar(25)
,After varchar(25)
)
insert #something
select 'Category', 'lx', 'mt' union all
select 'AskingPrice', '9.50', '10.00' union all
select 'Name', 'Paul', 'Paula' union all
select 'AskingPrice', '7.20', '9.10' union all
select 'Category', 'za', 'pz';
with MyCte as
(
select *
from #something
where FieldName = 'AskingPrice'
)
select *
from MyCte
where CONVERT(decimal(7, 2), After) > CONVERT(decimal(7, 2), Before);