• Topic
  • Discussion
  • UdaWikiWeb.CodeSamplesASP(Last) -- Owiki? , 2016-08-19 14:59:44 Edit owiki 2016-08-19 14:59:44

    <%@ Language=VBScript %> 
    <HTML> 
    <HEAD> 
    <TITLE>ASP script example</TITLE> 
    </HEAD> 
    <BODY> 
    
    <%Set Conn = Server.CreateObject("ADODB.Connection") 
    Conn.Open "DRIVER={OpenLink Generic 32 Bit Driver v4.0};HOST=localhost;ServerType=SQLServer 2000;DATABASE=pubs","sa", "" 
    Set rs_test = Conn.Execute("SELECT * FROM authors") 
    %> 
    <H2>Extract list of authors extracted from SQL Server on localhost</H2> 
    <BR> 
    <TABLE> 
            <% Do While not rs_test.EOF %> 
            <TR> 
                <TD><%= rs_test("au_id")%></TD> 
                <TD><%= rs_test("au_lname")%></TD> 
                <TD><%= rs_test("au_fname")%></TD> 
                <TD><%= rs_test("phone")%></TD> 
                <TD><%= rs_test("address")%></TD> 
            </TR> 
            <% rs_test.MoveNext 
            Loop %> 
    </TABLE> 
    
    
    </BODY> 
    </HTML> 
    
    

    Referenced by...