[Zope] Export to Excel format??
Mark Langkau
mark.langkau@pbmplus.com
Fri, 13 Jul 2001 14:26:28 -0500
Hi Norman,
The data will exist in a number of places - mostly in Oracle tables. Queries
and access will be through the browser to Zope.
For example, let's say that the default response for a query is an html page
with a table of daily sales figures. Just a simple html table with column
headings of Date, Region1, Region2, Region3, etc. and rows containing the date,
and then numbers for the different regions. (This is a made up example). The
client would like to be able to look at this html page and maybe download that
into his local Excel if he wants to work with the numbers. He may be looking at
many pages of different products or timeframes. When he finds something that
looks interesting, and wants to play "what-if" games, he would like to click a
link and download that data into his local Excel to play with.
What I'm thinking about now is creating a csv file, like:
"date","Region1","Region2","Region3"
"20010101","100","200","300"
"20010102","110","220","330"
etc.
The user can import that into Excel once they download it from Zope. I need to
work on either converting the page into this format (extracting just the table
and converting), or rerunning the query and format the result as comma
separated values rather than html (or both at the same time to avoid rerunning
the query).
In summary, the use case will be something like: User queries data, user finds
interesting data, user requests local copy of data to import into local
spreadsheet for independent analysis.
Cheers,
Mark
Norman Khine wrote:
> Hi Mark,
> In Excel you can run web queries that connect to your server and load-up the
> data. How is the data originally stored, is it in a database?
>
> I think you can write a script to get your data and put this in a file then
> you can use webdrive to to create a network drive and connect to this and
> link it to excel.
>
> It all depends what the dat is needed for!
>
> -----Original Message-----
> From: zope-admin@zope.org [mailto:zope-admin@zope.org]On Behalf Of Mark
> Langkau
> Sent: 13 July 2001 18:32
> To: zope@zope.org
> Subject: [Zope] Export to Excel format??
>
> Hi,
>
> I have a need to have data returned from a query to be displayed in
> either html, ascii, or MS-Excel formats. Before submitting a query, the
> user chooses if they want the result returned as a rendered html page to
> view, an ASCII file to download and import into something else, or as an
> Excel spreadsheet to download. (From the customers request. They haven't
> defined what "ascii' means yet - fixed length or csv).
>
> Any ideas on how to do this (export to Excel)? I don't think I'll need
> anything fancy, such as formulas, cell formatting, etc. Probably just a
> conversion of the html table into something that will be recognized and
> loaded by Excel. (Would a csv file named "something.xls" or even
> "something.csv" work??)
>
> I've searched the mailing list, but only found discussions on importing
> from Excel to Zope. I need to go the other way.
>
> Thanks,
> Mark
>
> _______________________________________________
> Zope maillist - Zope@zope.org
> http://lists.zope.org/mailman/listinfo/zope
> ** No cross posts or HTML encoding! **
> (Related lists -
> http://lists.zope.org/mailman/listinfo/zope-announce
> http://lists.zope.org/mailman/listinfo/zope-dev )