+ Reply to Thread
Results 1 to 6 of 6

Query with multiple condition to get data from access

  1. #1
    Registered User
    Join Date
    08-07-2012
    Location
    Mysore
    MS-Off Ver
    Excel 2010
    Posts
    38

    Query with multiple condition to get data from access

    Hi,
    Could you please help to combine below two quries under one?
    VBA Code:
    Please Login or Register  to view this content.
    Code:
    Please Login or Register  to view this content.
    Both are working fine when user separately.
    when try to combine them together nothing worrks.
    What I want is, first query to work when date range is given.
    Please help.

    https://www.mrexcel.com/board/thread...query.1178002/
    Last edited by AliGW; 08-01-2021 at 09:28 AM.

  2. #2
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    79,369

    Re: Query with multiple condition to get data from access

    Administrative Note:

    We would very much like to help you with your query, however you need to include code tags around your code.

    Please take a moment to add the tags. Posting code between [code]Please [url=https://www.excelforum.com/login.php]Login or Register [/url] to view this content.[/code] tags makes your code much easier to read and copy for testing, and it also maintains VBA formatting.

    Please see Forum Rule #2 about code tags and adjust accordingly. Click on Edit to open your post, then highlight your code and click the # icon at the top of your post window. More information about these and other tags can be found here

    (Note: this change is not optional. No help to be offered until this moderation request has been fulfilled.)
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

  3. #3
    Forum Moderator alansidman's Avatar
    Join Date
    02-02-2010
    Location
    Steamboat Springs, CO
    MS-Off Ver
    MS Office 365 Version 2403 Win 11 Home 64 Bit
    Posts
    23,810

    Re: Query with multiple condition to get data from access

    Administrative Note:

    Welcome to the forum.

    We would very much like to help you with your query, however it has been brought to our attention that the same query has been posted on one or more other forums and you have not provided the required cross-post link(s) here.

    Please see Forum Rule #3 about cross-posting and adjust accordingly. Read this to understand why we (and other sites like us) consider this to be important.

    (Note: this requirement is not optional. No help to be offered until the link is provided.)
    Alan עַם יִשְׂרָאֵל חַי


    Change an Ugly Report with Power Query
    Database Normalization
    Complete Guide to Power Query
    Man's Mind Stretched to New Dimensions Never Returns to Its Original Form

  4. #4
    Registered User
    Join Date
    08-07-2012
    Location
    Mysore
    MS-Off Ver
    Excel 2010
    Posts
    38

    Re: Query with multiple condition to get data from access

    Hi alansidman,
    Thanks for reminding on proving link to other forum. Ogirinal post updated with link.
    Please help with some solution to the problem posted.
    Thanks again.

  5. #5
    Forum Moderator alansidman's Avatar
    Join Date
    02-02-2010
    Location
    Steamboat Springs, CO
    MS-Off Ver
    MS Office 365 Version 2403 Win 11 Home 64 Bit
    Posts
    23,810

    Re: Query with multiple condition to get data from access

    Please Login or Register  to view this content.
    Maybe the above. You need to test as you have the source data.

  6. #6
    Registered User
    Join Date
    08-07-2012
    Location
    Mysore
    MS-Off Ver
    Excel 2010
    Posts
    38

    Re: Query with multiple condition to get data from access

    Dear alansidman,
    the code works. I think I have not told the requirement correctly.
    My requirement is, I want to include sDate and eDate to below code so that the filter works when date range is given and user can get the data for the selected dates along with the search item in combobox and textbox.

    Please Login or Register  to view this content.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. [SOLVED] How to access data via VBA from a Connection Only Power Query query.
    By MLAN_75 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 05-14-2020, 11:45 AM
  2. Excel Power Query Refresh or Access Query - 2nd Query Run is faster
    By Steveapa in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 01-03-2020, 10:16 AM
  3. Extract data from Access query
    By xrajncajnx in forum Excel General
    Replies: 2
    Last Post: 04-09-2015, 10:29 AM
  4. Reading data from ACCESS query
    By RAMSES955i in forum Access Tables & Databases
    Replies: 0
    Last Post: 07-04-2012, 02:52 AM
  5. Database Query-a query that reads data from MS Access
    By Osmar Mateus in forum Excel General
    Replies: 4
    Last Post: 01-29-2006, 04:10 PM
  6. [SOLVED] Data extract from access query
    By TrevorM in forum Excel General
    Replies: 4
    Last Post: 09-23-2005, 05:05 AM
  7. Multiple Query of Access Database
    By pb999 in forum Excel General
    Replies: 2
    Last Post: 05-14-2005, 08:21 AM

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