|
我在看《数据透视表应用大全》第11章
11.2.5节 汇总同一工作簿不同工作表中不同区域的数据的内容
并仿照P246页的语句,写了一段符合自己需要的SQL语句,可是总是报错,希望有高手能指点迷津:
我的目的:
1)将同一工作簿中15个工作表中的相同区域合并
2)生成一张分明细分人名的的数据透视表
我在"编辑OLE DB 查询"对话框中输入了下列语句:
[SELECT"吕爱娜",* from [吕爱娜$B3:E56] UNION ALL SELECT"吕爱娜",* from [吕爱娜$H3:K56] UNION ALL SELECT"郑莉",* from [郑莉$B3:E56] UNION ALL SELECT"郑莉",* from [郑莉$H3:K56] UNION ALL SELECT"曹玉",* from [曹玉$B3:E56] UNION ALL SELECT"曹玉",* from [曹玉$H3:K56] UNION ALL SELECT"童宁",* from [童宁$B3:E56] UNION ALL SELECT"童宁",* from [童宁$H3:K56] UNION ALL SELECT"朱敏",* from [朱敏$B3:E56] UNION ALL SELECT"朱敏",* from [朱敏$H3:K56] UNION ALL SELECT"张凝春",* from [张凝春$B3:E56] UNION ALL SELECT"张凝春",* from [张凝春$H3:K56] UNION ALL SELECT"周婷",* from [周婷$B3:E56] UNION ALL SELECT"周婷",* from [周婷$H3:K56] UNION ALL SELECT"张军仙",* from [张军仙$B3:E56] UNION ALL SELECT"张军仙",* from [张军仙$H3:K56] UNION ALL SELECT"尤佳",* from [尤佳$B3:E56] UNION ALL SELECT"尤佳",* from [尤佳$H3:K56] UNION ALL SELECT"袁菊香",* from [袁菊香$B3:E56] UNION ALL SELECT"袁菊香",* from [袁菊香$H3:K56] UNION ALL SELECT"吉京医",* from [吉京医$B3:E56] UNION ALL SELECT"吉京医",* from [吉京医$H3:K56] UNION ALL SELECT"陈兰香",* from [陈兰香$B3:E56] UNION ALL SELECT"陈兰香",* from [陈兰香$H3:K56] UNION ALL SELECT"刘晓梅",* from [刘晓梅$B3:E56] UNION ALL SELECT"刘晓梅",* from [刘晓梅$H3:K56] UNION ALL SELECT"陈薇",* from [陈薇$B3:E56] UNION ALL SELECT"陈薇",* from [陈薇$H3:K56] UNION ALL SELECT"于晖",* from [于晖$B3:E56] UNION ALL SELECT"于晖",* from [于晖$H3:K56]
出错内容显示:
相关附件:
办公文具申请单.rar
(27.51 KB, 下载次数: 69)
[ 本帖最后由 奶茶绕绕 于 2010-4-20 15:47 编辑 ] |
|