请高手帮我看下这条语句出了什么问题!

aiker666 2010-08-06 11:10:03
db2 export to c:/20100728_130_KZL.dat of del modified by nochardel decplusblank striplzeros Select cardno,rtrim(issuebrc),rtrim(issuebrc),rtrim(custno),rtrim(acctno),cardflg,case when substr(cardstat,1,1)='0' then '0' else '1' end,substr(usedate,1,4)||substr(usedate,6,2)||substr(usedate,9,2),substr(usedate,1,4)||substr(usedate,6,2)||substr(usedate,9,2),case when closedate=' ' then '29991231' else closedate end,case when teller=' ' then ' ' else rtrim(teller) end from cmscardinfo


单独执行SELECT语句不报错,但是在DB2命令行里执行这个EXPORT就报错,报在,SUBSTR(USEDATE,1,4)之后发现意外的标记,
SUBSTR不是内部或者外部命令!
...全文
89 3 打赏 收藏 转发到动态 举报
写回复
用AI写文章
3 条回复
切换为时间正序
请发表友善的回复…
发表回复
yangxiao_jiang 2010-08-06
  • 打赏
  • 举报
回复
加上"
zhaojianmi1 2010-08-06
  • 打赏
  • 举报
回复
db2 "export to c:/20100728_130_KZL.dat of del modified by nochardel decplusblank striplzeros Select cardno,rtrim(issuebrc),rtrim(issuebrc),rtrim(custno),rtrim(acctno),cardflg,case when substr(cardstat,1,1)='0' then '0' else '1' end,substr(usedate,1,4)||substr(usedate,6,2)||substr(usedate,9,2),substr(usedate,1,4)||substr(usedate,6,2)||substr(usedate,9,2),case when closedate=' ' then '29991231' else closedate end,case when teller=' ' then ' ' else rtrim(teller) end from cmscardinfo"
贾shasha 2010-08-06
  • 打赏
  • 举报
回复
你换行 弄的看起来名确定不好么 这么看着眼都费劲

5,889

社区成员

发帖
与我相关
我的任务
社区描述
IBM DB2 是美国IBM公司开发的一套关系型数据库管理系统,它主要的运行环境为UNIX(包括IBM自家的AIX)、Linux、IBM i(旧称OS/400)、z/OS,以及Windows服务器版本
社区管理员
  • DB2
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧