for example i rent a space for stock keeping and i can get 1% of total prices per day. I had created a database to record all in/out stock per day as
[date] [status] [quantities] [unit_price]
2007-09-16 'IN' 1000 3.50
2007-09-16 'OUT' 100 3.51
2007-09-17 'IN' 500 3.40
2007-09-18 'IN' 1000 3.35
Sorry for my dumb, i'm stuck on a database calculation above. i hope any expert can show me how to get income calculation between $date1 and $date2 through sql query?