+ Reply to Thread
Results 1 to 3 of 3

Problem with Aggregate Function ADO SQL

  1. #1
    Forum Guru Kyle123's Avatar
    Join Date
    03-10-2010
    Location
    Leeds
    MS-Off Ver
    365 Win 11
    Posts
    7,238

    Problem with Aggregate Function ADO SQL

    Hi,

    I have a spreadsheet that I populate from an Access database which I have no problem doing, except for the below query.

    The SQL query works fine in Access, but returns no records when running the below code from Excel and there are no error messages. This is the first Aggregate function that I have run from Excel so it's quite possible I'm missing something, but any help would be very much appreciated!

    Please Login or Register  to view this content.
    Last edited by Kyle123; 03-10-2010 at 07:49 AM.

  2. #2
    Valued Forum Contributor Richard Schollar's Avatar
    Join Date
    05-23-2006
    Location
    Hampshire UK
    MS-Off Ver
    Excel 2002
    Posts
    1,264

    Re: Problem with Aggregate Function ADO SQL

    Hi

    I believe it's because in this ADO provider you need to use the % character to denote a wildcard so the SQL should look like this:

    Please Login or Register  to view this content.
    Richard
    Richard Schollar
    Microsoft MVP - Excel

  3. #3
    Forum Guru Kyle123's Avatar
    Join Date
    03-10-2010
    Location
    Leeds
    MS-Off Ver
    365 Win 11
    Posts
    7,238

    Re: Problem with Aggregate Function ADO SQL

    That's great, works fine now.

    Thanks Richard

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1