ActiveX Data Objects, a Microsoft middleware for accessing data sources. Allows to access data from various languages without knowing how the database is implemented. Successor of RDO (Remote Data Objects) and DAO (Data Access Objects), first introduced in 1996.
Questions tagged [adodb]
1825 questions
6
votes
1 answer
Upload file with ADODB for Web-DAV "cannot find any objects or data in accordance with the name..."
I have an MS Access 2007 VBA application running on Windows 7. One crucial function is to upload files to a WebDAV server. The code below works perfectly on one PC, but fails on other PCs (and yes, each is configured the same way).
Here is a…

user1922341
- 69
- 2
6
votes
4 answers
Using "SELECT SCOPE_IDENTITY()" in ADODB Recordset
Using a VBA script in Excel, I'm trying to insert a new row into a table and then get back the identity value of that row. If I run:
INSERT INTO DataSheet(databaseUserID, currentTimestamp)
VALUES (1, CURRENT_TIMESTAMP);
SELECT SCOPE_IDENTITY()
in…

JoeCool
- 4,392
- 11
- 50
- 66
6
votes
2 answers
Recordset only returning 1000 records
I'm doing an ADODB recordset.open() command with an LDAP query to get all the users from my Active Directory.
There are about 2600 users, but I'm only getting back 1000 of them.
I've tried altering the recordset's PageSize and MaxRecords properties…

ChristianLinnell
- 1,368
- 2
- 16
- 22
5
votes
2 answers
VBA macro in Excel to Run SQL Insert statement
Hey im quite new to VBA and I was hoping someone could help me with last bit of code.
I am trying to take cells from a spreadsheet and add them to a SQL table but I am having trubble running the SQL statement. Here is the code I have so far.
…

user1167046
- 51
- 1
- 1
- 2
5
votes
2 answers
"Invalid procedure call or argument" error on "New ADODB.Connection" only if compiled on Windows 7
I'm experiencing some problem when I compile some legacy apps on VB6 since I got a new development machine in windows 7. (my old one was on Windows XP.)
If I compile the project on my XP machine, everything is fine.
If I compile the same project on…

DavRob60
- 3,517
- 7
- 34
- 56
5
votes
2 answers
How to diagnose syntax error from a parameterized SQL Server query in VBA ADODB
I'm using VBA adodb to write INSERT statements in a SQL Server based on Excel row contents.
I'm using parameterized queries so my VBA code has the following form:
sqlStatement = "INSERT INTO dbo.mytable (" & Join(insertElement(0), ", ") & ") VALUES…

deseosuho
- 958
- 3
- 10
- 28
5
votes
4 answers
Windows Script Host (jscript): how do i download a binary file?
i'm trying to automate a file download with Windows Script Host (JScript). i see ADODB.Stream has an Open method whose documentation makes it seem like it should be possible to open a HTTP URL and stream the response body:
var url =…

just somebody
- 18,602
- 6
- 51
- 60
5
votes
2 answers
Problems in Excel 2013 when using ranges that extend beyond row 65536
I am trying to perform an ADODB query on a named range in an Excel 2013 workbook.
My code is as follows:
Option Explicit
Sub SQL_Extract()
Dim objConnection As ADODB.Connection
Dim objRecordset As ADODB.Recordset
Set…

YowE3K
- 23,852
- 7
- 26
- 40
5
votes
2 answers
Troubleshooting a Parameterized SQL Statement in asp
I'm trying to secure some legacy code written in what I guess is VB or asp(Not really sure if there is a difference). When I try to execute the statement the page gets an internal server error. I'm convinced this is a result of the connection but I…

HopAlongPolly
- 1,347
- 1
- 20
- 48
5
votes
1 answer
PHP SQLSRV has intermitent delay on sqlsrv_fetch_array/sqlsrv_fetch
we switched our DB connection from ADODB to SQLSRV and I seem to have issues with it causing intermitent delays using sqlsrv_fetch_array.
I do a query in my database that returns around 426 rows with 5 fields.
The code looks like this (for speed…

user3242224
- 169
- 7
5
votes
0 answers
How can I specify a cursor type for a recordset in pyodbc?
I am struggling with Python scripts that use the ADODB classes via COM. I have concluded that the pyodbc module will be better for my purposes. However, there are options available in the ADODB.Recordset.Open() method that I do not see in pyodbc. …

ROBERT RICHARDSON
- 2,077
- 4
- 24
- 57
5
votes
1 answer
How to return multiple recordsets in a single execution using ADODB?
I need to iterate through multiple recodsets produced by a single query.
However my current connection does not seem to support doing this. So when I do .NextRecordset I get the message:
Current provider does not support returning multiple…

lisovaccaro
- 32,502
- 98
- 258
- 410
5
votes
2 answers
How to save a text file (CSV) with UTF-8 without BOM encoding in VBA (Excel)?
So this was my initial question. The answer to my question below, seems to be that the only solution to get UTF-8 (and UTF-8 without BOM) encoding, is to use the ADODB.Stream object. The answer to my new question in the subject line is posted as a…

Niclas
- 1,069
- 4
- 18
- 33
5
votes
1 answer
ADODB Connection String: Workgroup Information file is Missing?
I have a few data sources in access that I need to connect to programatically to do things with behind the scenes and keep visibility away from users.
Said datasource has a password 'pass' as I'm going to call it here. Using this connection method…

Mohgeroth
- 1,617
- 4
- 32
- 47
5
votes
2 answers
How to import a csv file using @ as delimiter with VBA
I am trying to load data from a csv file in Excel with VBA using ADODB.
I have a function to return a Connection object.
Private Function OpenConnection(dataSource As String) As ADODB.Connection
Set OpenConnection =…

marcw
- 893
- 8
- 18