Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

2 Access tables, count verbiage used

Posted on 2016-11-07
6
Medium Priority
?
55 Views
Last Modified: 2016-11-07
I have a table named Orders with field Product. In that field, there is string of text which contains the color of the product. In another table, I have field Color, which has all the possible colors that may be in the text string in the other table. I need to count the number of Products in table Orders that have the Color from the second table. Reason: I need to count how many orders used each possible Color. Ideally, I would add a field called Color in table Orders right after field Product which would store the color found in the other table.
0
Comment
Question by:QMBB
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 3
6 Comments
 
LVL 120

Expert Comment

by:Rey Obrero (Capricorn1)
ID: 41877711
first, you need to create a UDF to parse the content of the field Product to get all the colors for that record.
next is to compare the result to the values in the  second table.


a sample db is needed to do this.

upload a copy of the db with the two tables.
0
 

Author Comment

by:QMBB
ID: 41877719
0
 
LVL 120

Expert Comment

by:Rey Obrero (Capricorn1)
ID: 41877744
the color field contains text that are not color, is this correct  (21 - 29 in)
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 

Author Comment

by:QMBB
ID: 41877754
Yes, 2 records, but I need to find those as well.
0
 
LVL 120

Accepted Solution

by:
Rey Obrero (Capricorn1) earned 2000 total points
ID: 41877773
test this revised db, I added a field color in table orders and populate by running the sub checkColors()

see code In module1  checkColors()
db12_rev.mdb
0
 

Author Closing Comment

by:QMBB
ID: 41877794
Thanks very much.
0

Featured Post

What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In Part II of this series, I will discuss how to identify all open instances of Excel and enumerate the workbooks, spreadsheets, and named ranges within each of those instances.
Did you know that more than 4 billion data records have been recorded as lost or stolen since 2013? It was a staggering number brought to our attention during last week’s ManageEngine webinar, where attendees received a comprehensive look at the ma…
Basics of query design. Shows you how to construct a simple query by adding tables, perform joins, defining output columns, perform sorting, and apply criteria.
In Microsoft Access, learn how to “cascade” or have the displayed data of one combo control depend upon what’s entered in another. Base the dependent combo on a query for its row source: Add a reference to the first combo on the form as criteria i…

618 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question