|
[广告] VBA代码宝 - VBA编程加强工具 · VBA代码随查随用 · 内置多项VBA编程加强工具 ★ 免费下载 ★ ★ 使用手册★
本帖最后由 魂断蓝桥 于 2012-7-20 06:37 编辑
lsrzggod 发表于 2012-7-19 17:51
这是原始数据,我已经定义好表格了,您看看,谢谢您了。
select *,"01、金子-左" from aa union all
select *,"01、金子-中" from ab union all
select *,"01、金子-右" from ac union all
select *,"02、玉溪-左" from ad union all
select *,"02、玉溪-中" from ae union all
select *,"02、玉溪-右" from af union all
select *,"03、渠江-左" from ag union all
select *,"03、渠江-中" from ah union all
select *,"03、渠江-右" from ai union all
select *,"04、三江汇合-左" from aj union all
select *,"04、三江汇合-右" from al union all
select *,"05、坝上-左" from am union all
select *,"05、坝上-中" from an union all
select *,"05、坝上-右" from ao union all
select *,"06、坝下-左" from ap union all
select *,"06、坝下-中" from aq union all
select *,"06、坝下-右" from ar union all
select *,"07、梁沱-左" from ass union all
select *,"07、梁沱-中" from att union all
select *,"07、梁沱-右" from au
as 与 at 是sql内部使用的东西,不能定义成名称使用,改一下就好了。
另:名称里面没找到ak表,你自己再重新定义一下名称。
新建 Microsoft Excel 工作表.rar
(24.18 KB, 下载次数: 7)
|
|