Advertisement

07.18.2008 at 02:23PM PDT, ID: 23578296
[x]
Attachment Details

Access combination query

Asked by johnnyg123 in Access Coding/Macros, SQL Query Syntax, Access Forms

Here's my situation

I have 2 MS Access 2003 tables in order table and an order detail table

here is a sample layout for the order table

order_id     order_date
1234           20080710
2345           20080711


here is a sample layout for the order_detail  table

order_id     part_num
1234           ABC123
1234           XYZ123
2345           ABC123




I have been asked to create a csv file that will take order id records, followed by corresponding
order detail.  (Via an ms access form)

Using the sample data it would look like the following
1234,20080710,ABC123,XYZ123
2345,20080711,ABC123

Is there a way I can write a query that would return the data in the above format?

I was thinking I could create a recordset from the query and then write the field values to a file

I did something similiarusing sql server using a user defined function way back when but not sure if access has the equivalent.Start Free Trial
[+][-]07.18.2008 at 02:34PM PDT, ID: 22040003

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]07.18.2008 at 02:48PM PDT, ID: 22040089

View this solution now by starting your 7-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

 

About this solution

Zones: Access Coding/Macros, SQL Query Syntax, Access Forms
Sign Up Now!
Solution Provided By: capricorn1
Participating Experts: 3
Solution Grade: A
 
 
[+][-]07.19.2008 at 03:09PM PDT, ID: 22043808

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
 
Loading Advertisement...
20080716-EE-VQP-32 / EE_QW_2_20070628