Skip to main content
Announcements
Introducing Qlik Answers: A plug-and-play, Generative AI powered RAG solution. READ ALL ABOUT IT!
cancel
Showing results for 
Search instead for 
Did you mean: 
vikasmahajan

How to calculate closing for every month in sql urgent

Dear all

I have  Sql Script  Question  I have following query will display  closing balance of april 2013 , Now I want to build query for

every month  ( April 13   1322751 , may 124545 ....)

Select PROD_CODE,a.INVDATE,sum(a.BalanceQty) as Qty

FROM FACT_MonthlyInventory a

WHERE a.invdate <='01-Apr-2012'

group by a.PROD_CODE,a.INVDATE

PROD_CODEINVDATEQty
1CY42012-04-01 00:00:00.0001322751

How to achieve the same in sql , any SQl Expert Comments Pls.

thanks in adv.

Vikas

Hope this resolve your issue.
If the issue is solved please mark the answer with Accept as Solution & like it.
If you want to go quickly, go alone. If you want to go far, go together.
0 Replies