Results 1 to 7 of 7
  1. #1
    beetgirl is offline Novice
    Windows XP Access 2010 64bit
    Join Date
    Jul 2011
    Posts
    3

    Access 2010 - search query not working

    I created a search query on my database form to search for data already stored on a table. However, when I click the Search button and the Search field pops up, I type a word that I want the query to find and it returns a portion of the table that is not sorted in any way. (i.e. It wouldn't matter what I typed inot the search field, I would get the same result. Which is not at all the format I would even need that information to populate.) Please help! This is what I have showing in my action catalog:



    OpenQuery
    Query Name Search Meeting

    OpenTable
    Table Name Enrollment Meeting Tracking Table

    FindRecord
    Find What Rep Name
    Last edited by beetgirl; 07-07-2011 at 02:50 PM. Reason: To be more specific

  2. #2
    boblarson is offline --------
    Windows 7 64bit Access 2010 32bit
    Join Date
    Jun 2011
    Posts
    1,272
    For having a sort order you would need to have a query with the sort order defined. Simply opening a table isn't going to get you sorted information. Open the query in Design view and then go to SQL view and copy and paste the query contents here so we can see what you currently have.

    Also, why are you opening the query and then opening a table?

  3. #3
    zaza123 is offline Novice
    Windows XP Access 2007
    Join Date
    Jun 2011
    Posts
    19
    Try using apply filter... I need see ur Form and ur sql codes...
    Last edited by zaza123; 07-08-2011 at 12:50 AM.

  4. #4
    zaza123 is offline Novice
    Windows XP Access 2007
    Join Date
    Jun 2011
    Posts
    19
    Here's a demo i did if there is an error tell me ill fix it for u cause i did it in a rush????Tell me if it is something like this or explain further for me!!!

  5. #5
    beetgirl is offline Novice
    Windows XP Access 2010 64bit
    Join Date
    Jul 2011
    Posts
    3
    Bob, the answer to your question is simple...when I hit the search button, the query was bringing up a blank table. So I thought I needed to insert an OpenTable command to correct this. (I am new to this, in case it's not already obvious.) But, of course all that does is open the entire table and not just the information I requested in the search box. I'm attempting to provide examples as you requested of what I'm working with. The last screen shot is the result I receive when I type something into the search box. That information is jibberish and not at all what I need from this.

    I appreciate any and all feedback since I am desperate to get this to work.

  6. #6
    jscriptor09 is offline Advanced Beginner
    Windows XP Access 2010 32bit
    Join Date
    Jul 2011
    Posts
    60
    Normally if the query is returning a blank table .... it implies that there is NO match.

    So, If I were you, I would focus on the query string and make sure thatg it is doing what you "really" want it to do. Just because it ran with no error, it does not mean that the query is constructed right.

    BTW: I run into this situation often, hence mu advice.

    Mike

  7. #7
    boblarson is offline --------
    Windows 7 64bit Access 2010 32bit
    Join Date
    Jun 2011
    Posts
    1,272
    Here's your database sample modified. Form1 is now unbound and opens Form2 with the results as a datasheet. Look at the code behind my new search button. I used code instead of macros.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 4
    Last Post: 06-15-2011, 03:55 AM
  2. Replies: 9
    Last Post: 05-05-2011, 02:05 PM
  3. Working with OLE excel charts in Access 2010
    By snoopy2003 in forum Programming
    Replies: 1
    Last Post: 02-23-2011, 12:46 PM
  4. nested functions not working in 2010?
    By Gdm in forum Queries
    Replies: 2
    Last Post: 08-02-2010, 08:02 AM
  5. Search field is not working correctly
    By jakeao in forum Programming
    Replies: 9
    Last Post: 05-18-2009, 07:47 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums