databse connection

Results 1 to 3 of 3

Thread: databse connection

  1. #1
    ashumati Guest

    Default databse connection

    here is my code for database connection my database is in access.<BR>it;s giving a error showing jet engine error.&#060;html&#062;<BR>&#060;head&#062;<BR>&#06 0;meta http-equiv="Content-Type" content="text/html; charset=windows-1252"&#062;<BR>&#060;meta name="GENERATOR" content="Microsoft FrontPage 4.0"&#062;<BR>&#060;meta name="ProgId" content="FrontPage.Editor.Document"&#062;<BR>&#060 ;title&#062;test&#060;/title&#062;<BR>&#060;/head&#062;<BR>&#060;body&#062;<BR>&#060;% dim con , rs<BR> set con = server.createobject ("adodb.connection")<BR> "provider=microsoft.jet.oledb.4.0;;data source=c:employeeemsq.mdb"<BR> set rs = server.createobject("adodb.recordset")<BR> if len(request.querystring("idno"))&#060;&#062;0 then<BR> "select name from employee where dept=&#03901&#039order by scale desc & idno=" & request.querystring("pf_acno"),con, 0,1<BR> %&#062;<BR>anybody there since i am beginner asp .please help<BR>

  2. #2
    Join Date
    Dec 1969

    Default RE: databse connection

    You didn&#039t supply a driver, and I&#039m pretty sure you have to. I usually use a DSN connection, but I&#039m 90% sure you have to specify the driver. I think it will be something like so (don&#039t quote me on this):<BR><BR> "driver=(Microsoft Access Driver (*.mdb))"<BR><BR>Once again, I haven&#039t used DSNless connections a lot, but that&#039s a start!

  3. #3
    Join Date
    Dec 1969

    Default Don't need driver

    No, I don&#039t think you do need a driver, the provider and the data source is one legitimate way of opening a connection. I do see two semi-colons, rather than one, in the connection string. Was this just a typo in the message? It might be the problem.<BR><BR>I made a post after 11 PM Sunday on a related subject which didn&#039t receive any response probably because very few people saw it today. Its entitled "ADO could not find specified provider" Since then, I&#039ve solved my problem by downloading from microsoft and reinstalling the ole db dlls. Its not that such is the problem here, but I mention several formats of the connection string I had tried, one of which was the provider and data source. After the reinstall this format has worked. Another format could be Driver and DBQ. In my research, I saw that Microsoft is deprecating the use of ODBC and ODBC drivers in preference of direct access to the OLEDB provider. I don&#039t know that a provider is really just another kind of driver but the terminology is different. It has to do with Microsoft&#039s Universal Data Link strategy.

Posting Permissions

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