怎样通过一张表中记录的表名查n张表?

lttwww 2003-05-27 11:05:36
怎样通过一张表中记录的表名,循环查n张表的内容呢?求教
...全文
12 1 打赏 收藏 转发到动态 举报
写回复
用AI写文章
1 条回复
切换为时间正序
请发表友善的回复…
发表回复
cbzdream 2003-05-27
  • 打赏
  • 举报
回复
rst.open "select tablename from yourtable"
if rst.recordcount>0 then
for i=1 to rst.recordcount
dim s as string
dim strSql as string

s=trim(rst!tablename)
strSql="select * from " & s
rst2.open strSql

.........
rst.movenext

next
end if

1,216

社区成员

发帖
与我相关
我的任务
社区描述
VB 数据库(包含打印,安装,报表)
社区管理员
  • 数据库(包含打印,安装,报表)社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

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