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 |
masond
Constraint Violating Yak Guru
447 Posts |
Posted - 2012-12-19 : 06:02:57
|
Hey guys Really stupid question but need some help This is my query, SELECT 'Foreign -issued cards total Transactions and Gross Sales',SUM([hst_sales_tran_R12]) AS [Transactions],SUM([hst_sales_amt_R12]) AS [Gross Sales]FROM [Fact_Financial_History_2] INNER JOIN Dim_Interchange_Tier_2 ON Fact_Financial_History_2.hst_prod_code + '-' + Fact_Financial_History_2.hst_plan_code = Dim_Interchange_Tier_2.Plan_CodeWHERE Region in ('EU', 'INT')GROUP BY Dim_Interchange_Tier_2.regionWhen i run the query it is producing the following results (No column name) Transactions Gross SalesForeign -issued Sales 2554838 228653784.13Foreign -issued Sales 2178699 228165015.92Is there anyway i can get them transactions/gross sales to be on a one liner ? For instance (No column name) Transactions Gross SalesForeign -issued Sales 4733537 456818800.1Would appreciate any help available |
|
bandi
Master Smack Fu Yak Hacker
2242 Posts |
Posted - 2012-12-19 : 06:39:06
|
Try this...WHERE Region in ('EU', 'INT')GROUP BY Dim_Interchange_Tier_2.region--Chandu |
|
|
|
|
|