如何在sql语句中实现变量?
skydb 2003-07-13 10:00:31 我常要执行这样一类sql语句
select * from tableA where date='20003-6-30'
union all
select * from tableB where date='20003-6-30'
union all
select * from tableC where date='20003-6-30'
union all
select * from tableD where date='20003-6-30'
可不可以将其中的'2003-6-30'设成一个变量代替,这样在执行sql语名前我只需更改变量的值即可
谢谢