Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: SQL-Server-2008 C#4.0 , +
i have two data tables namely profitloss and delivery, the query for each are as follows:
SELECT        customer.name, SUM([Milk Delivery].Paid) AS Paid
FROM            customer INNER JOIN
                         [Milk Delivery] ON customer.Code = [Milk Delivery].Code
WHERE        ([Milk Delivery].Date BETWEEN @id AND @id2)
GROUP BY customer.name
here customer is a different table which helps to know the customer name using the code. If a certain date range is being entered using textbox or similar input, it groups the output using customer name and shows the total amount paid for each customer within the timeperiod.
 
profitloss adapter is as follows:
SELECT    id, date, item, supplier, qty, amt, paid, due
FROM            profitloss
WHERE        (date BETWEEN @id AND @id2)
ORDER BY date
my question is how can i show these together without using sub report, in such a manner that, the results would come up like a full outer join, as there is no dependencies with these two, and show them in crystal report? i already included them in a new dataset and have set the same as the data source for my crystal report, also have included these two tables in crystal report,
but in result crystal report shows repeated rows, just like a cross join or cartesian product, which i do not want to see, instead i want the result to show just like the result of a full outer join with null rows removed! please help!
furthermore, if anyone can show me how to put these two together in a single adapter using full outer join, it would be same helpful for me.
Posted 21-Feb-13 1:00am
Edited 21-Feb-13 6:17am
(no name)498.9K
v2
Comments
Member 8336012 at 22-Feb-13 6:33am
   
I think that it is all due to the linking in crystal reports, I have got full outer join option disabled! Please help me...

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 245
1 Jochen Arndt 155
2 PIEBALDconsult 150
3 Afzaal Ahmad Zeeshan 120
4 DamithSL 115
0 OriginalGriff 5,695
1 DamithSL 4,591
2 Maciej Los 4,012
3 Kornfeld Eliyahu Peter 3,480
4 Sergey Alexandrovich Kryukov 3,190


Advertise | Privacy | Mobile
Web04 | 2.8.141220.1 | Last Updated 21 Feb 2013
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100