FROM [KoolSmiles].[dbo].[v_DigitalMedia]
where (REportDate between '3/14/11' and '3/20/11')and sitename = 'Google'--where (REportDate between @start and @end)and sitename = 'Google'
group by sitename,campaign

SELECT sitename, campaign, SUM(cost)as sitecost, SUM(calls)as sitecalls, (SUM(cost)/NULLIF(SUM(calls),0) as 'CPC' FROM [KoolSmiles].[dbo].[v_DigitalMedia] where (REportDate between '3/14/11' and '3/20/11') and sitename = 'Google' group by sitename,campaign

SELECT sitename, campaign, SUM(cost)as sitecost, SUM(calls)as sitecalls, isnull(SUM(cost)/NULLIF(SUM(calls),0),0) as 'CPC' FROM [KoolSmiles].[dbo].[v_DigitalMedia] where (REportDate between '3/14/11' and '3/20/11') and sitename = 'Google' group by sitename,campaign

When we have to pass multiple rows of data to SQL Server, the developers either have to send one row at a time or come up with other workarounds to meet requirements like using XML to pass data, which is complex and tedious to use. There is a …

Hi all,
It is important and often overlooked to understand “Database properties”. Often we see questions about "log files" or "where is the database" and one of the easiest ways to get general information about your database is to use “Database p…

Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…

This video gives you a great overview about bandwidth monitoring with SNMP and WMI with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg).
If you're looking for how to monitor bandwidth using netflow or packet s…