这是我的小号 发表于 2014-11-13 15:44
第一个问题:请确认Excel版本是否2003的。第二个问题,正确的写法是: select * from [sheet1$A2:C1000], ...
todaynew 发表于 2014-11-13 19:30
Sql = "TRANSFORM sum(数量) SELECT 字段1,字段2 FROM in " & wkbook.FullName & "![sheet1$!" & sAddress ...
kent_73 发表于 2014-11-14 08:24
谢谢回复。这句sql语句提示:运行时错误'-2147217900(80040e14)':FROM子句语法错误。
现传上附件,请帮 ...
todaynew 发表于 2014-11-14 10:09
Sql = "TRANSFORM sum(数量) SELECT 字段1,字段2 FROM [sheet1$!" & sAddress & "] in " & wkbook.FullNa ...
kent_73 发表于 2014-11-14 10:32
还是有错的。
DoCmd.RunSQL "Insert INTO 表名 Select * FROM [Excel 8.0;DATABASE=E:\桌面\测试数据.xls].[Sheet1$]"
DoCmd.RunSQL "Insert INTO 表名 Select * FROM [Sheet1$] IN 'E:\桌面\测试数据.xls'[EXCEL 8.0;]"
DoCmd.RunSQL "Insert INTO 表名 Select * FROM [Sheet1$] IN 'E:\桌面\测试数据.xls' 'EXCEL 8.0;'"
DoCmd.RunSQL "Select * INTO [Excel 8.0;DATABASE=E:\桌面\测试数据.xls].[Sheet1] FROM 表名"
DoCmd.RunSQL "Select * INTO [Sheet1] IN 'E:\桌面\测试数据.xls'[EXCEL 8.0;] FROM 表名"
DoCmd.RunSQL "Select * INTO [Sheet1] IN 'E:\桌面\测试数据.xls' 'EXCEL 8.0;' FROM 表名"
欢迎光临 Office中国论坛/Access中国论坛 (http://www.office-cn.net/) | Powered by Discuz! X3.3 |