为什么下面的语句会报错???

hgc2002 2003-10-14 10:32:25
update canshu
set value= :canshutime.sle_ts1.text
where name="ts1start"
using sqlca;

canshu是个参数表,value和name都是varchar类型,
数据库为access 2000
错误为:datadasec0038:sqlstate=37000 Access的update语法错误???
...全文
50 12 打赏 收藏 转发到动态 举报
写回复
用AI写文章
12 条回复
切换为时间正序
请发表友善的回复…
发表回复
119119 2003-10-22
  • 打赏
  • 举报
回复
哈哈,叫我怎么说呢!
liliang800207 2003-10-21
  • 打赏
  • 举报
回复
sql语句里不能写t_1.text。须写到变量里
scmyxj 2003-10-21
  • 打赏
  • 举报
回复
楼上说的很清楚了,SQL语句中给列赋值最好用变量或者常量:)
fulongbiao 2003-10-18
  • 打赏
  • 举报
回复
string str
str=canshutime.sle_ts1.text
update canshu
set value= :str
where name="ts1start"
using sqlca;
wantsong 2003-10-16
  • 打赏
  • 举报
回复
第一使用变量
第二char、varchar型用''

str = canshutime.sle_ts1.text
update canshu
set value= :str
where name='ts1start'
using sqlca;
qqjj7758 2003-10-16
  • 打赏
  • 举报
回复
都被你们说了,我还能说什么。。。。。。。。
佣工7001 2003-10-15
  • 打赏
  • 举报
回复
数据库的常量时要用单引号的!!!!!!!!!
update canshu
set value= :canshutime.sle_ts1.text
where name='ts1start'
using sqlca;
knetfox 2003-10-14
  • 打赏
  • 举报
回复
up
workhand 2003-10-14
  • 打赏
  • 举报
回复
如上,sql语句里不能写t_1.text。须写到变量里
地狱余烬 2003-10-14
  • 打赏
  • 举报
回复
说得对
xavier_lee 2003-10-14
  • 打赏
  • 举报
回复
value is column?

canshutime.sle_ts1.text...?

//you try:

string str

str = sle_ts11.text;

...
set value = :str
...
coordinate 2003-10-14
  • 打赏
  • 举报
回复
string str
str=canshutime.sle_ts1.text
update canshu
set value= :str
where name="ts1start"
using sqlca;

740

社区成员

发帖
与我相关
我的任务
社区描述
PowerBuilder 脚本语言
社区管理员
  • 脚本语言社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

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