Need advice on banking application

  • Thread starter Thread starter VB Programmer
  • Start date Start date
V

VB Programmer

I am working on an ASP.NET 2.0 banking-type application. No, it's NOT a
school question! This is a real-world web application. :)

The table "Transactions" contain all types of individual "transactions" -
interest_payment, deposits, withdrawals & fees mostly. Each of these
entries are related to an "account". (So, of course, summing all of these
would give the current account "balance".)

On a nightly basis I have to do this...
FOR EACH "account" I need to (1) get the current "balance" of the account,
(2) increase it by a small set percentage (all accounts get the same %
increase) then (3) insert a NEW interest_payment record in the Transactions
table for EACH account.

Any idea how I should go about this?

I'm not sure if I can do this in 1 or 2 steps (like a large SQL statement)
or if I have to write some VB.NET code and loop thru every record. I'd
appreciate your insight.

Thanks in advance!
 
Can u provide a sample? Even if rough? Thx...

Miha Markic said:
Stored procedure is a way to go.

--
Miha Markic [MVP C#, INETA Country Leader for Slovenia]
RightHand .NET consulting & development www.rthand.com
Blog: http://cs.rthand.com/blogs/blog_with_righthand/

VB Programmer said:
I am working on an ASP.NET 2.0 banking-type application. No, it's NOT a
school question! This is a real-world web application. :)

The table "Transactions" contain all types of individual "transactions" -
interest_payment, deposits, withdrawals & fees mostly. Each of these
entries are related to an "account". (So, of course, summing all of
these would give the current account "balance".)

On a nightly basis I have to do this...
FOR EACH "account" I need to (1) get the current "balance" of the
account, (2) increase it by a small set percentage (all accounts get the
same % increase) then (3) insert a NEW interest_payment record in the
Transactions table for EACH account.

Any idea how I should go about this?

I'm not sure if I can do this in 1 or 2 steps (like a large SQL
statement) or if I have to write some VB.NET code and loop thru every
record. I'd appreciate your insight.

Thanks in advance!
 
VB Programmer,

You know that any solution given in a newsgroup is as it is.

There is not any guarantee that it is working or will work or be a true
solution even if the answer is given by Microsoft people.

This message to prevent that you think that you ever can refer by problems
to answers given in a newsgroup.

This especially because that in a banking application there can be high
financial risc for the developer.

Cor
 
Very true. I always thoroughly test my code and don't take anything "as
is". I was just seeking some guidance. Thanks Cor...
 
Back
Top