Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8851193
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T13:05:37+00:00 2026-06-14T13:05:37+00:00

In my Access database, I’m trying to perform a search and find routine which

  • 0

In my Access database, I’m trying to perform a search and find routine which is quite complicated. Basically, I have 4 criteria to look for in these four tables: Date, Service, Code and Function.

With this information I go into a table, and search in a field and for one criteria. After I’ve found the rows which correspond to one of the 4 criteria, I save the value of the neighboring field for all the rows which matched correctly. After this, I wanted to save the values of all the neighboring fields as an array. Then repeating these steps, I was going to save all 4 searches as 4 individual arrays.

The relationships of my tables are as follows:

Table Relationships

I receive a “Demande” which is a request, and in that request are the four criteria: Date, Service, Code and Function.

In the table “Services_YES” I look for the Service that corresponds to the demand.

In the table “Pool_Personnel” I look for the Fonction that corresponds to the demand.

In the table “Days_Available” I look for both the Date and the Code (called Code_Horaire) which corresponds to the demand.

From there, I was hoping to record each Code_Personal for all of the results found, and then find which Code_Personal’s matched in all of the 3 tables.


So My question:

How I can do a search and find function which creates an array of for all of the Code’s which correspond to the criteria rows?

I have created psuedo code to help explain, and incase someone can translate this into real VBA:

While demandeTable.functionField.Value = poolpersonnelTable.Fonction1Field.Value
  get all poolpersonnelTable.codepersonalField.Value for all rows that match
  save fonctionArray = codepersonalField.Values
Loop

I’m very stuck on how to complete this ‘filtering’, and would strongly appreciate all help.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T13:05:38+00:00Added an answer on June 14, 2026 at 1:05 pm

    Using VBA is not the answer.

    I ended up creating a Query, and using user-inputed text to fill in the variable parts of the query:

    comboService = Chr(34) & Me.Combo8.Value & Chr(34)
    txtDate = Chr(34) & Me.Text15.Value & Chr(34)
    comboCodeHoraire = Chr(34) & Me.Combo17.Value & Chr(34)
    
    "SELECT tblPoolPersonnel.LName, tblPoolPersonnel.FName, tblPoolPersonnel.[Tel Natel], tblPoolPersonnel.[Tel Home], tblPoolPersonnel.Email" & vbCrLf
    "FROM ((tblPoolPersonnel INNER JOIN tblFonction ON tblPoolPersonnel.Code_Personal = tblFonction.Code_Personel) INNER JOIN tblDayAvailable ON tblPoolPersonnel.Code_Personal = tblDayAvailable.Code_Personal) INNER JOIN tblServiceYES ON tblPoolPersonnel.Code_Personal = tblServiceYES.Code_Personal" & vbCrLf
    "WHERE (((tblServiceYES.Service)=" & comboService & ") AND " + _
                    "((tblDayAvailable.Availability)=True) AND " + _
                    "((tblDayAvailable.Date)=" & txtDate & ") AND " + _
                    "((tblDayAvailable.CodeHoraire1)=" & comboCodeHoraire & "))"
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have an (access) database table which contains data I would like to populate
I have an access database which manipulates data from a Magento e-commerce store, reformats
I have an MS Access database on a network drive with a userform which
I have an MS-Access database, which I am connecting to in Java using the
I have an Access database which has a table with around 6k records. When
I have an Access database in which I drop the table and then create
I have a Microsoft Access database query that I'm trying to import into a
I have an access database on a windows machine, which I must import into
I have an access database with a parent form which has a subform in
I have an access database with these tables: - sequences: it describes the sequences

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.