Results 1 to 11 of 11
  1. #1
    DonnyBoy is offline Novice
    Windows 10 Office 365
    Join Date
    Feb 2023
    Posts
    4

    Using an Access table for input processing

    [COLOR=var(--black-200) !important][COLOR=var(--black-500) !important]0



    [/COLOR]
    [/COLOR]
    I need to process through a list of technical skills one by one and get a count of the number of developers we have in 3 locations who have that skill. For example, Skill = "Java". How many persons have this skill listed in their resume.
    I have 2 tables:
    Skills: contains a single column listing skills - "Java" for example Resources: contains 4 columns, Resource-ID, Name, Location, and a long text field called "Resume" containing text of their resume.
    If this were a single skill I would process the SQL something like below (SQL syntax not exact) SELECT count FROM [Resources] WHERE ([Resources].[Resume] Like "Java*");


    I want to process the Skills table serially printing the "Skill" and the count in each location.
    Help appreciated
    I've only used Access as a DB for single record retrieval, never using table values as input to loop through a process. I suspect that this is a simple execution in MS Access.







  2. #2
    orange's Avatar
    orange is offline Moderator
    Windows 10 Office 365
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,870
    I suggest you take a few sample RESUME data from your table and post it for readers to get some flavor of your context. And a list of the Skills involved.

  3. #3
    Join Date
    Jan 2017
    Location
    Swansea,South Wales,UK
    Posts
    6,572
    Possibly group by skill and location.
    Please use # icon on toolbar when posting code snippets.
    Cross Posting: https://www.excelguru.ca/content.php?184
    Debugging Access: https://www.youtube.com/results?sear...bug+access+vba

  4. #4
    June7's Avatar
    June7 is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,772
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  5. #5
    DonnyBoy is offline Novice
    Windows 10 Office 365
    Join Date
    Feb 2023
    Posts
    4
    Very well, I made a sample DB, attached. I also added a sample query for the search if I were looking a single skill. In my example, I want to walk through each of the skills listed in the Skill table and list out a count.

    SELECT Resource.PID, Resource.Name, Resource.Location, Resource.[Resume Text]
    FROM Resource
    WHERE Resource.[Resume Text] Like "*" &'java'& "*";
    Attached Files Attached Files

  6. #6
    June7's Avatar
    June7 is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,772
    Have you reviewed solution suggested on your StackOverflow question?
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  7. #7
    DonnyBoy is offline Novice
    Windows 10 Office 365
    Join Date
    Feb 2023
    Posts
    4
    Yes I reviewed but it did not answer my question. I posted that same response. I also did not have the oppty to upload an Access DB as I do here. That artifact helps illustrate the question.

  8. #8
    June7's Avatar
    June7 is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,772
    Exactly how does the two answers not resolve issue? Both suggestions produce the output you require: "count of the number of developers we have in 3 locations who have that skill"

    My approach used LIKE operator, Albert used InStr() function. Both perform a pattern match search.

    There was no image in the response you posted which was an inappropriate use of the answer feature. It also specifies a different requirement: "desired result is a simple matrix listing counts of skills by resource and where they are" - this says 'counts of skills' instead of 'counts of developers'. A 'resource' is a developer?
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  9. #9
    Join Date
    May 2018
    Location
    Living in Scotland UK
    Posts
    1,822
    Hi

    Use the following as the criteria.

    You can then use it for whatever criteria needed

    Like "*" & [Enter Skill Required] & "*"

  10. #10
    xps35's Avatar
    xps35 is offline Competent Performer
    Windows 10 Office 365
    Join Date
    Jun 2022
    Location
    Schiedam, NL
    Posts
    300
    Try something like
    Code:
    SELECT Resource.Location, Skill.[Normalized skill], Count(Resource.ID) AS CountOfPlantSkillFROM Resource, Skill
    WHERE (((Resource.[Resume Text]) Like "*" & [Normalized skill] & "*"))
    GROUP BY Resource.Location, Skill.[Normalized skill];
    Groeten,

    Peter

  11. #11
    DonnyBoy is offline Novice
    Windows 10 Office 365
    Join Date
    Feb 2023
    Posts
    4

    Solution

    Quote Originally Posted by xps35 View Post
    Try something like
    Code:
    SELECT Resource.Location, Skill.[Normalized skill], Count(Resource.ID) AS CountOfPlantSkillFROM Resource, Skill
    WHERE (((Resource.[Resume Text]) Like "*" & [Normalized skill] & "*"))
    GROUP BY Resource.Location, Skill.[Normalized skill];

    Step 1: Create a query that executes the below SQL to get a counts (here named "Step1Query")
    SELECT Skills.SkillName, Resources.Location,
    Sum(Abs([Resume] Like '*' & [SkillName] & "*")) AS DevCt
    FROM Skills, Resources
    GROUP BY Skills.SkillName, Resources.Location;


    Step 2: Create a second query that uses the Step 1 query as input. (you can do this via the wizard)
    TRANSFORM Sum(Step1Query.DevCt) AS SumOfDevCt
    SELECT Skills.SkillName, Resources.Location,
    Sum(Abs([Resume] Like '*' & [SkillName] & "*")) AS DevCt
    FROM Skills, Resources
    GROUP BY Skills.SkillName, Resources.Location
    PIVOT Step1Query_qry.[Location];


    Result lists out a matrix form

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

Similar Threads

  1. Replies: 6
    Last Post: 05-18-2022, 09:10 AM
  2. Replies: 14
    Last Post: 12-17-2018, 10:06 AM
  3. Replies: 8
    Last Post: 01-09-2018, 04:36 AM
  4. processing e-mails from outlook into access
    By Mlki in forum Programming
    Replies: 1
    Last Post: 07-11-2016, 09:40 AM
  5. Table Setup advice for invoice processing...
    By Delta729 in forum Database Design
    Replies: 1
    Last Post: 11-23-2010, 11:52 AM

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