Method and apparatus to develop and generate spreadsheet reports. A
database is used to store information about template spreadsheet files,
queries and functions, query definitions and function calls and programs,
external data sources, data source definitions, inputs to queries, and
outputs generated by queries. A user interface is used to populate the
database with all the information required to define and execute a
report. A program uses report definition information from the database,
makes a copy of the template spreadsheet file to create the spreadsheet
report, executes all defined queries, functions or programs in the
sequence specified within the report definition against external data
sources and stores retrieved data in the locations within the spreadsheet
as specified in the report definition. The queries may also be defined so
as to update the data in the external data sources.