0
基本上我有一個運行從應用程序快速SQL查詢並顯示錶(代碼如下所示)一個.asp頁:如何設置Oracle SQL輸出表的樣式?
<%
Set DBConn = Server.CreateObject("ADODB.Connection")
DBConn.Open "Driver={Oracle in OraClient11g_home1};DBQ=ORCL;UID=ops$USERNAME;PWD=PWD;"
Set QueryResult = DBConn.Execute("SELECT * FROM LOAN")
Response.Write "<table border=1 cellpadding=4>"
Response.Write "<tr>"
For I = 0 to QueryResult.Fields.Count - 1
Response.Write "<td><b>" & QueryResult(I).Name & "</b></td>"
Next
Response.Write "</tr>"
Do While Not QueryResult.EOF
Response.Write "<tr>"
For I = 0 To QueryResult.Fields.Count - 1
Response.Write "<td>" & QueryResult(I) & "</td>"
Next
Response.Write "</tr>"
QueryResult.MoveNext
Loop
Response.Write "</table>"
QueryResult.Close
DBConn.Close
%>
我遇到的唯一問題是如何樣式表。我從來沒有做過這種輸出,我不知道我應該把樣式規則放在哪裏。我只需要它與網站其他部分的樣式相同:sans-serif等。另一件事是如何更改顯示列的標題?
感謝您的幫助,我很堅持了這個,因爲我從來沒有使用VBScript /的Oracle Application Express