|
-
Oct 1st, 2010, 10:27 AM
#1
Thread Starter
Junior Member
getting sum of a duplicated record using sql
I have a table that stores income and expenditure. every time an entry is made, it is saved independently in the table so as to be able to track every income or expenditure entered. i would want to get a list of all incomes and expenditure saved in the table with the sum without repeating any record. am using vb6 and ms access, i would like appreciate your help.
-
Oct 1st, 2010, 10:29 AM
#2
Re: getting sum of a duplicated record using sql
Moved From the FAQ Section
-
Oct 1st, 2010, 11:32 AM
#3
Re: getting sum of a duplicated record using sql
Why would there be repeating records?
-tg
-
Oct 2nd, 2010, 12:31 AM
#4
Re: getting sum of a duplicated record using sql
He probably did a join which result in columns from one table being repeated...depash, post you current SQL query.
-
Oct 2nd, 2010, 04:54 AM
#5
Thread Starter
Junior Member
Re: getting sum of a duplicated record using sql
selectRecord.Open "SELECT account, drcr from tbl_incomestmt where IncomeDate between #" & f & "# and #" & t & "# and acc_period_id = " & activeAccountingPeriod & " order by tbl_incomestmt.head_no;", Cn
Set rpt_incomestmt.DataSource = selectRecord
The records are repeated becease every time an entry is made, it is saved in the table and not updating any record. the same case which happens when a customer buys items in a shop using a POS, this will help me to view all sales per day and whichever day they want
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|