To give you an example of how you could summarize your data for fiscal reporting or bilance sheets:
Code:
Select sum(qty*price) as salesincome from orderdetails where orderid in (Select id from orders where orderdate between date(2023,1,1) and date(2023,12,31)
or, if you want the totals per order and not just one overall total:
Code:
Select orderno, sum(qty*price) as ordertotal from orderdetails where orderid in (Select id from orders where orderdate between date(2023,1,1) and date(2023,12,31) group by orderid
Untested, and surely will differ from what you actually need depending on how your application developer strcutured the data, but just to show how little SQL can show you the data you need without going through cumbersome harvesting of data from the documents you have printed, only.
The data of a business is the core of everything, even of starting to program a new application, if the original programmer isn't available anymore. And there are many tools out there for generally connecting to databases and working on them with queries.
Stonefield Query (
is one that I would think of first, as it supports FoxPro data, but not only Foxpro data. It's by Doug Hennig, who also posted here.
And, last not least, when this application is a general business software sold in your country, you're not the only one with the need to comply to the new fiscal law. If the vendor isn't gone out of business that software should have already beed adopted to accomodate that new need or that vendor will lose customers, wouldn't he?
Chriss