Quantcast
Channel: Transact-SQL forum
Viewing all articles
Browse latest Browse all 23857

How to compare this week with last years week sales ?

$
0
0

Hi all,

I have a table called Sales with two columns  Date and UnitsSold

Date is of type smalldatetime   and will have the date of the sales

while UnitsSold is type int and will have the number of units sold

I need to write a stored procedure that will compare between a week's sales from last year with a week sales from this year and show the percent in sales difference

Thanks

 


Viewing all articles
Browse latest Browse all 23857

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>