I want to take the sale report,
Group by catID ,
Daily report ,
table name : tblbasket BID Auto Incre, Prim Key
BID int(20), BasketSessionID varchar(100),ProductCode varchar(50), CatID
int(10), Quantity int(20), AfterDiscount double,purchasedate datetime,
Status int(3)
table name : tblsale SaleID Auto Incre, Prim Key
SaleID int(20), BillNo varchar(30), BasketSessionID varchar(200),
CatID int(10), AfterDiscount double, VAT int(20),purchasedate datetime,
Status int(2)
the above is my table structure,
I want to build two query ,
One query should display the daily sale report ,(for this i have
purchasedate, AfterDiscount nothing but an bill amount, Status once the
billing sucess then tblbasket status goes to 3 and tblsale Status goes to 1,
On both table relationship is only BasketSessionID )
second query, this query should display the sale report group by cat id with
VAt(vat is present in sale table, )
How to create the query ,For this scenario
and another is