ASP遍歷資料庫

2021-05-28 04:42:58 字數 585 閱讀 2408

<%@language="vbscript" codepage="65001"%>

<%setrstschema = db.openschema(20)do untilrstschema.eof '遍歷資料庫表

ifrstschema("table_type")="table"thenresponse.write rstschema("table_name") & ":"setrs=db.execute("select * from " & rstschema("table_name"))fori=0tors.fields.count-1 '遍歷表中字段

response.write rs(i).name &" "next

end ifresponse.write "

" rstschema.movenextloop%>

FAQ 22 Cursor 遍歷資料庫

使用 contentprovider 與 sqlite 資料庫過程中,獲取 cursor 物件之後,可以遍歷資料庫。當前資料庫裡面的資料 第一列 id 第二列 name 第三列 gender 說明,下面的查詢結果均是按降序排列。1.movetonext cursor c getcontentreso...

SQL 建立索引,遍歷資料庫所有表

檢視資料庫表占用的磁碟空間 執行儲存過程 exec sp spaceused tablename 建立聚簇索引 create clustered index indexname on tablename columnname 不允許有重覆記錄 create index clustered index...

js遍歷資料

1 使用object.keys 遍歷 返回乙個陣列,包括物件自身的 不含繼承的 所有可列舉屬性 不含symbol屬性 var obj object.keys obj foreach function key 輸出結果 0 a1 b 2 c2 使用for in 遍歷 迴圈遍歷物件自身的和繼承的可列舉屬...