my self avinash
i m developing one application in vb 6 and sql server 7
i have one table name - Salesvoucher which has fields like voucherno,voucherdate,debitto,creditto,amount.
i want to show all my voucher records in ascending order by date.
when i display it i used some button to navigate list so that user get some friendly interface these buttons r MoveFirst,Movenext,MovePrevious,MoveLast. i write query for each button which display TOP 20 records order by voucherno when i click to NExt Button it display next TOP 20 record so on....but now i want to display the record by using grouping on date. i.e say i have 10 records of voucherdate 01/05/2004, 15 records of voucherdate 8/6/04 and 4 records of voucherdate 15/6/04. then i want to display these records by group on voucherdate i.e when i click to MoveFirst Button then all records of date 01/05/2004 should display then i click to Next Button then all records will come of 8/6/04 date like this.
so plz help me in building these query
i m developing one application in vb 6 and sql server 7
i have one table name - Salesvoucher which has fields like voucherno,voucherdate,debitto,creditto,amount.
i want to show all my voucher records in ascending order by date.
when i display it i used some button to navigate list so that user get some friendly interface these buttons r MoveFirst,Movenext,MovePrevious,MoveLast. i write query for each button which display TOP 20 records order by voucherno when i click to NExt Button it display next TOP 20 record so on....but now i want to display the record by using grouping on date. i.e say i have 10 records of voucherdate 01/05/2004, 15 records of voucherdate 8/6/04 and 4 records of voucherdate 15/6/04. then i want to display these records by group on voucherdate i.e when i click to MoveFirst Button then all records of date 01/05/2004 should display then i click to Next Button then all records will come of 8/6/04 date like this.
so plz help me in building these query