Results 1 to 2 of 2

Thread: excel-sql

  1. #1
    Join Date
    Dec 1969

    Default excel-sql

    my code runs as follows:<BR><BR><BR>Dim row<BR> Dim b0,b1,b2,b3,b4,b5,b6,b7,b8,b9,b10,b11,b12,b13,coun t<BR> Dim oConn <BR> Dim i,x<BR> Set oConn=Server.CreateObject("ADODB.connection")<BR> oConn.Open "Provider=Microsoft.Jet.OLEDB.4.0;" & _<BR> "Data Source=C:Dbquizgrades.xls;" & _<BR> "Extended Properties=""Excel 8.0;"""<BR> Set objRS=server.createobject("ADODB.recordset")<BR> objRS.Open "Select * from [Sheet1$A1:N12]", oConn, adOpenStatic<BR><BR><BR>wot shud be the sql query next so that i can retrieve the first three rows of the quizgrades.xls file alongwith the skeleton of the table,i mean three rows with values in the fields of a table as they appear in an excel file?<BR>

  2. #2
    Join Date
    Dec 1969

    Default Did you try...

    ...simply getting the first three records from objRS???<BR><BR>I would *think* that would do the job.<BR><BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts