Hi again FredericoFonseca, (and other viewers... if any?)
I see what you are telling me. And you are right about that every Entry_Date_ID is unique in your query, but as I mentioned before my goal is to add all amounts for each month and there may be several entry_date_ids on a month.
Here is...
But I have nearly the same SQL as you:
-----------------
SELECT DISTINCT Dim_Customer.CustomerName, Dim_Date.YearAndMonth,
(SELECT SUM(OriginalAmount)
FROM Customer_Entry f2
WHERE...
Hi again, your'e right about the joins. They are no problem. But your solution don't give the right output.
With your solution I get one post for each entry_date_id what the goal is, is to get one post for each month! There can be several entry_date_ID's in one month.
Take a look at my example...
Dear Experts,
I have 3 tables:
"Dim_Date"
Date_ID
MonthNumber (Month nr... ex. jan=1)
Year (ex. Year=2007)
Year&Month (Contains both year and name of month... ex. "2007 - July")
"Customer"
Customer_ID
CustomerNumber (Contains a customernr... ex. "08243")
CustomerName (Contains the Customers...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.