Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Options for Generating Charts from Oracle Queries

Is there a simple (possibly free) way to generate charts (including Pie) out of Oracle SQL queries. Preferably generated as an image file.

I came across Oracle Chart Builder, but it doesn't seem quite what I want.

like image 594
vicsz Avatar asked Feb 07 '11 21:02

vicsz


People also ask

Can you generate graphs in SQL?

SQL Graph DatabaseUsers can create one graph per database. A graph is a collection of node and edge tables. Node or edge tables can be created under any schema in the database, but they all belong to one logical graph. A node table is collection of similar type of nodes.

How do I export data from Oracle to Excel automatically?

Select Tools, and then Export as Spreadsheet. Depending on how you want to export the data, take an action: Select Save, and then save the file. Select Open, and then work with the data in the browser instance of Microsoft Excel that displays.


2 Answers

Oracle Application Express (APEX) lets you build web-based applications using PL/SQL. It has a pretty decent charting engine so you can use that to build a pie chart from the results of a query. APEX is free and included with recent versions of Oracle though you will have to do some initial setup and configuration.

like image 84
Justin Cave Avatar answered Sep 18 '22 07:09

Justin Cave


I'd probably start with Google Charts. There's a demo here pulling database data into a chart.

One question is where do you want your image file to go.

Option 1. On to the database server. You can actually call the URL through the UTL_HTTP package, pull down the raw data and store it in the database as a BLOB or write it to a file with UTL_FILE

Option 2. Into a browser client. This is where you'd need some gateway between the database server and the browser. 10g/11g has an HTTP server embedded in the database which can be used (eg by a product like Apex). The apex listener is another way to get data out in a format that is easily processed.

An intermediate product, like jasperreports, might also be appropriate. It's a more formal 'enterprisey' approach to database reporting.

Or you can go old-school and have pie-charts in ol' SQL Plus

like image 22
Gary Myers Avatar answered Sep 19 '22 07:09

Gary Myers