i'm preparing a few reports for my manager in food business.
i have a few tables:
purchase-(id, code,date,doNo,amount)<--related to supplier
suppliers & purchase
1) i need to display the list of suppliers and the amount of purchase we made for certain month.
i can group them by code but how can i display them accordingly(sorted by name)?
foodtrans & papertrans
2) there's 2 types of transfer, In and Out. i need to get the total amount of food and paper transfer according to their types, also for a certain month.
all this into 1 dynamic table.
Can i use only 1 query statement?