- collection is read only exception
- PayPal sending incorrect carrier information
- paypal guest user notice
- classic asp dictionary not working
- IE8 not supporting innerHTML
- differences between jet and odbc
- sugarcrm not inserting email
- select random records from access
- button click event firing twice
- how to send an email using cdosys
- installing perl on win2003 64 bit
- asp.net page event order
- rewrite rule for subdomains only
- extra items in javascript array
- IE7 margin auto not working
- IE7 border style dotted glitch
- ByRef and ByVal in vbscript
- weather rss feed
- Classic asp crib sheet
- Firefox onsubmit image change
- limit records in access
- AccessDataSource is thick
- double margins in IE6
- extra image padding in html emails
- decimal places in linux flash player
- broken emails in outlook 2007
- double spaced IE list items
- cannot remove movieclip
articles:
differences between jet and odbc
Consider these two connection strings:
"Provider=Microsoft.Jet.OLEDB.4.0; Data Source=" & server.MapPath("\somedb.mdb")
"Driver={Microsoft Access Driver (*.mdb)};DBQ="& server.MapPath("\somedb.mdb")
I have never really noticed any major difference between these two connection strings in terms of what they do, and I have always been under the impression that one was just a wrapper around the other.
However, recently I stumbled upon two things the Jet.OLEDB data provider can do that the ODBC driver cannot:
- Use of SELECT @@IDENTITY to return the ID of the last record to be inserted within a current connection
-
Something like this:
dim conn
set conn = server.createobject("ADODB.connection")
dim rs
set rs = server.createoobject("ADODB.recordset")
conn.open "Provider=Microsoft.Jet.OLEDB.4.0; Data Source=" & server.MapPath("\somedb.mdb")
rs.open "SELECT [tableA.somecolumn], [tableB.somecolumn] FROM [tableA], [tableB] WHERE [tableA.id = tableB.tableAid]",conn, 3
do while not rs.EOF
response.write(rs("tableA.somecolumn") & " " & rs("tableB.somecolumn"))
rs.movenext
loop
rs.close
set rs = nothing
conn.close
set conn = nothingIf you use the ODBC driver with the above SQL you'll get an error saying that tableA.somecolumn is not in the collection.
Not necessarily the most ground breaking of scientific or articles, but may solve somebody's puzzle.
Comments
There are no comments on this article yet, be the first to leave one
Post a comment
