正文:
QUOTE:
作用:
列出已知 Access 数据库名中的数据库表与视图的名称
shawl.qiu
2006-5-30
CODE:
CODE:
-----------------------/视图 between_
表/--- buarticle
表/--- buclass
表/--- bunclass
表/--- bureply
表/--- butag
-----------------------/视图 count_
-----------------------/视图 count_union_1
表/--- ctarticle
表/--- ctclass
表/--- ctglossary
表/--- ctglossarysubcat
表/--- ctglossarysubsubcat
表/--- ctglossarysupercat
表/--- ctnclass
表/--- ctreply
表/--- ctsearch
表/--- cttag
-----------------------/视图 date_query_by_month
-----------------------/视图 distinct_year
-----------------------/视图 group_by_gr
-----------------------/视图 having_2
-----------------------/视图 having_repeat_title
-----------------------/视图 iif_1
-----------------------/视图 inner_join_select_3
-----------------------/视图 inner_join_select_4
-----------------------/视图 inner_join-cascading2
-----------------------/视图 isnull
-----------------------/视图 select_
-----------------------/视图 select_distinct
-----------------------/视图 select_less_great
-----------------------/视图 t3
表/--- Ta
表/--- tg
表/--- ts
表/--- ts1
表/--- tscC
表/--- tspic
-----------------------/视图 v_column_siteall
-----------------------/视图 v_column_subcat
-----------------------/视图 v_column_supercat
-----------------------/视图 v_page_article
-----------------------/视图 v_page_class_ctclass
-----------------------/视图 v_page_class_ctnclass
-----------------------/视图 v_page_ctglossary
-----------------------/视图 v_page_date
-----------------------/视图 v_page_search_ctarticle
-----------------------/视图 v_page_search_ctglossary
set rs=server.createobject("Adodb.connection")
rs.open MM_conn_string
set rsSchema=rs.openSchema(20)'20 指定查找表,视图; 23 指定查找视图
while not rsSchema.EOF
if rsSchema("TABLE_TYPE")="TABLE" then '显示表名
response.write "表/--- "
response.write rsSchema("TABLE_NAME")
response.write "<br>"
end if
if rsSchema("TABLE_TYPE")="VIEW" then '显示视图名
response.write "-----------------------/视图 "
response.write rsSchema("TABLE_NAME")
response.write "<br>"
end if
rsSchema.movenext
wend
rsSchema.close
set rsSchema=nothing
rs.close
set rs=nothing 'code by shawl.qiu
%>