Is this a SQL Server you're working with? Perhaps you could post this question in the SQL Server forum ... Sergey (or somebody) will probably have ideas for you.
~~Bonnie
>Hi all:
>
>I use a code from the internet that calculate the amortization of a loan and is working fine. The problem is that in a report they want the summary of that amortization and I want to use the same table that this amortization create. I make a function call but in the function I can not use insert delete or update. How I can create the table and return the sum of the column I want from the same store procedure . Remember that the main table have all the loan with all the values to calculate each amortization.
>
>I did not use the formulas that calculate total interest because the sum of that formulas does not match exactly with the numbers in the amortization detail. Our tester are very picky reports and screen display has to match values. So for that reason I am trying to use the same table or the same code that produce my amortization.
>
>Any Idea how to make this problem work will be very apreciated.
>
>TIA