Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
AskSQLTeam
Ask SQLTeam Question
0 Posts |
Posted - 2002-03-12 : 09:36:36
|
| meer writes "I have following tablesBanner (Master)-----------intbannerIdintAffiliateId Advertiser(Master Table)----------intAffiliateId chvNamechvAddressBannerView (Transaction)-----------intViewintbannerIdintAffiliateId Clicks------inrClickIdintbannerIdintAffiliateId PLeads (Transaction)--------intLeadIdintbannerIdintAffiliateId CLeads (Transaction)--------intLeadIdintbannerIdintAffiliateId Questions1) want to find out the total number of leads provided in Cleads and Pleads by a particulalr affiliate.2)want to get report on total banner views ,Clicks and Leads Regards Meer" |
|
|
yakoo
Constraint Violating Yak Guru
312 Posts |
Posted - 2002-03-12 : 13:02:01
|
1) want to find out the total number of leads provided in Cleads and Pleads by a particulalr affiliate.SELECT SUM(TotalLeads) FROM((SELECT Count(intLeadID) as TotalLeads FROM Pleads WHERE intAffiliateID = 1)UNION(SELECT Count(intLeadID) as TotalLeads FROM Cleads WHERE intAffiliateID = 1)) as for question 2 "want to get report on total banner views ,Clicks and Leads" based upon what criteria. Is intbannerID and intAffiliateID a 1 to 1 relationship or can affiliates share banners? |
 |
|
|
meer_b
Starting Member
1 Post |
Posted - 2002-03-13 : 00:29:05
|
| Thanks yacoo....:)Questions1) want to find out the report on total number of leads provided in Cleads and Pleads by a affiliates order by total of Cleads and Pleads.2)want to get report on total banner views ,Clicks and Leads here affiliates can shear banners. (1 banner to many affiliates)Regards Meer" |
 |
|
|
|
|
|