Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Aged trial balance
Message
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Stored procedures, Triggers, UDFs
Titre:
Aged trial balance
Divers
Thread ID:
00554942
Message ID:
00554942
Vues:
60
Hi

I have finding a solution for this one:

From a table containing customer numbers and total due i need to create a stored procedure or an sql statement creating the ageing of the total due.

Our 3 Tables are

Customers: Account, TotDue
Current transactions: Account, InvoiceNo, Date, Amount
Transaction History : Account, InvoiceNo, Date, Amount

Starting with current transactions, then if neccessary, go to the history file. i need to get a cursor with invoice amounts in the appropriate columns, up to the total due.

The cursor i need back would look like this:

Account, Current, t30Day, t60Days, t90Days, t120Days


The problem is both the current transaction file and the history file have millions of records.

We are using SQL Server 2000.

Thanks for any help.
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform