Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Recent content by mdsoren

  1. mdsoren

    Setting SORT BY

    BIG THANX SwampBoogie!!! That fixed it. Whoopie!!!
  2. mdsoren

    Setting SORT BY

    I have tried to search the forum, but don't see anything like what I am trying to do... I have my SQL statement built on the fly based on values selected from 5 combo boxes users may choose as many or as few, but at least one. No matter which elements they are searching the database for, the...
  3. mdsoren

    Create a SELECT query based on user input

    It would seem that simple, but I don't think it is... because of the herarchy of the tables. I'll try and give an example here: if they want to find John Brown (an owner), the query has to search the officer's table, the owner's table and the main table (where he may be listed as a contact)...
  4. mdsoren

    Create a SELECT query based on user input

    I have been hunting for a solution for this for two months and have yet to find it! I have a VB application which allows the user to select one, any combination or all five variables to search on (Owner's name, Attorney's name, State, Company Type and Accounting Firm used). The report to be...
  5. mdsoren

    Create a SELECT query based on user input

    Thanx all. I have tried to build the query in pieces and have even gotten it to run now, but I am not getting the results I expected from query. It returns ALL records in my "parent" table everytime, no matter what selection criteria I use. My problem I am sure is related to my...
  6. mdsoren

    Set up "WHERE" criteria on the fly

    Thanx Jeremy. Actually, I do have the names all stored in one table and ID's used in all the subsequent tables, I just abbrev'd my code to eliminate those references as I know how to get the name if the ID is selcted. I like the idea of putting the "AND" at the beginning and then...
  7. mdsoren

    Set up "WHERE" criteria on the fly

    Jeremy, I will try and give you the gist of what I am working with... Table structure - tblCorp is a table of corporations with an specific ID for ea record along with a little company specific data, e.g. responsible attorney, primary contact, corporation type (for-profit, not-for-profit...
  8. mdsoren

    Create a SELECT query based on user input

    HELP!!! I have been trying find a way to create a SELECT query at runtime based on the user selecting values from five combo boxes. They must select at least one, but may select any combination or even all five. The data comes from a hierarchy of tables. My table structure can be one, two or...
  9. mdsoren

    Set up "WHERE" criteria on the fly

    HELP!!! I have been trying find a way to create a SELECT query at runtime based on the user selecting values from five combo boxes. They must select at least one, but may select any combination or even all five. The data comes from a hierarchy of tables. My table structure can be one, two or...
  10. mdsoren

    Help with UNION

    I appreciate your assistance and I don't want to sound stupid, but... what's a view? The users only access the database thru the VB app and do not have MS Access installed on their systems. Does any of that matter? The same fields are pulled no matter what the criteria: company name...
  11. mdsoren

    Help with UNION

    That might work... but I am pulling the data from 6 different tables, in at least two cases using "parent-child" relationships between the tables (in at least one of those cases that relationship extends two levels deep, a sub-table and a sub-sub-table). I have used LEFT JOINS on some...
  12. mdsoren

    Help with UNION

    I have an app which allows the user to create their own search criteria (by selecting from any or all of 5 fields). The selections they can make come from values in combo boxes, so they can only search for data that pre-exists. I have built an individual SELECT query for each searchable field...
  13. mdsoren

    Help with JOIN (or UNION?)

    I am a real "green horn" when it comes to writing SQL statements. Can anyone help with what I see as a difficult JOIN query? I have 5 different fields users can select a value in to build their search query. They can choose 1 field, all 5 fields or any combination in between. Given...
  14. mdsoren

    Nested query, sub-query, join or what?

    THANK YOU cmmrfrds!!! That did it, I figured since I could "visualize it" that it was possible, but I didn't know how. The (SELECT...) AS XXX within the the main SELECT did the trick perfectly. THANKS AGAIN, I was struggling for 2 days with that and now I can sleep :) MDS
  15. mdsoren

    Nested query, sub-query, join or what?

    Here's my problem - I need to build a single recordset from multiple tables based on the input of one record ID. Given this ID I pull the "main" record from table one, search tables 2, 3, and 4 for linked records based on the ID already provided. Upto here I am fine and have the...

Part and Inventory Search

Back
Top