Home
> Uncategorized > Using OleDb with Excel
Using OleDb with Excel
Being an advocate of OleDb, I thought I’d share some information I learnt tonight regarding connecting to Excel spreadsheets using OleDb. Using a DSN such as Provider=Microsoft.Jet.OLEDB.4.0;Data Source=<filename>;&Extended Properties="Excel 8.0;" you get access to the spreadsheet "tables" as if it was an access database.
A few points I noticed. was that sheets are named [sheet1$], column headers may not always be named, so you may need to resort to using ordinals in your recordset. Also, when doing "LIKE" clauses in sql, you use the % syntax, not the * syntax, as common with MS Access.
Categories: Uncategorized
Comments (0)
Trackbacks (0)
Leave a comment
Trackback