[ODBC Microsoft Access驱动程序]查询输入必须至少包含一个表或查询 [英] [ODBC Microsoft Access Driver] Query input must contain at least one table or query

查看:103
本文介绍了[ODBC Microsoft Access驱动程序]查询输入必须至少包含一个表或查询的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用odbc执行查询.
我已将access(.mdb)数据库附加到dsn,然后使用以下查询

i have used the odbc to excute the query.
i have attached the access(.mdb) database to the dsn then used the following query

insert into SCRIPT (ID1, NM )
 select ''10'' as DTID1 , ''DD'' as DTNM  Union All
select ''20'' as DTID1 , ''DRR'' as DTNM  Union All
select ''30'' as DTID1 , ''DDD'' as DTNM  Union All
select ''40'' as DTID1 , ''CXCVX'' as DTNM  Union All
select ''50'' as DTID1 , ''DGFDFG'' as DTNM


当我执行插入查询时,它会引发以下异常


when i excute the insert query it throws following exception

Execute Query Exception :ERROR [HY000] [Microsoft][ODBC Microsoft Access Driver] Query input must contain at least one table or query.



如何执行上述查询?
在此先感谢



how to excute the above query?
thanks in advance

推荐答案

这看起来很混乱,为什么您不能只插入xxx值(x,y)?
This looks messy, why can''t you just have insert into xxx values(x,y) ?


这篇关于[ODBC Microsoft Access驱动程序]查询输入必须至少包含一个表或查询的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆