LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default tricky SQL problem using VBA Excel to read Access File

Thanks for the advice, but I already tried that. I managed to resolve
this on my own by adding another layer of nesting. To restate the
problem, there are items, orders and, customers. I am selecting
orders that contain a certain item# in a certain date range (the inner
most select) and then trying to count (among these orders) the number
of unique orders by customer that have a different item#. My query
could successsfully sum the the quantity and cost of this different
item# for each customer but couldn't give me a unique count of orders
that included the item -- instead the count counted the number of items
meeting the criteria, not unique orders.

I solved it by changing the above query to sum up the quantity, cost
etc. by order (not by customer) and then nest all of it within another
select statement that summed those order subtotals by customer, which
could then properly count the number of orders. Whew!

 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
When opening Excel - get Access (Read-Only) file and error DeltaDagger Setting up and Configuration of Excel 1 October 31st 06 10:22 AM
i cannot open excel file error Cannot access read-only document me Lenda. Excel Worksheet Functions 1 March 14th 05 06:15 PM
Network access to file - read only property AL Excel Discussion (Misc queries) 1 December 2nd 04 01:22 AM
Use ADO in VB to read excel file problem ong Excel Programming 5 September 6th 04 02:33 PM
tricky Excel/VBA/Access needed Doug Shannon Excel Programming 3 June 22nd 04 04:18 PM


All times are GMT +1. The time now is 08:02 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"