3 ms·
There really is no documentation on how to use your own database as a data source. Am I misunderstanding what FnordMetric is meant to do? Is it meant to allow
by sida 12y ago
There really is no documentation on how to use your own database as a data source.
Am I misunderstanding what FnordMetric is meant to do? Is it meant to allow me to generate charts from my existing postgres database or is it something where I have to feed data into it?
- chenster 12y agoI too agree. It's the holy grail to directly draw using a database source by skipping the middle man.
- zorbo 12y agoI too am wondering this. This tool would be great if it could directly use data from my own databases. But it seems data has to be imported first: http://fnordmetric.io/documentation/chartsql/external_data_sources/ http://fnordmetric.io/documentation/chartsql/external_data_s...
- paulasmuth 12y agoI think we need to improve the wording in the documentation. The IMPORT statement only creates a "virtual table", it doesn't actually import any data. As much of the query as possible is pushed down into MySQL/the external data source.
- paulasmuth 12y agoYes, you can use FnordMetric to create charts from data in your existing database. Have a look at this documentation page: http://fnordmetric.io/documentation/chartsql/external_data_sources/ http://fnordmetric.io/documentation/chartsql/external_data_s... Here is a simple example for a query that uses an external MySQL database: https://github.com/paulasmuth/fnordmetric/blob/master/fnordmetric-doc/examples/queries/mysql_backend.sql https://github.com/paulasmuth/fnordmetric/blob/master/fnordm... Currently we only support CSV and MySQL as external data sources, but a postgres plugin is on it's way.
- sida 12y agoI have some questions: 1. Does IMPORT TABLE mean that it has to copy data from MySQL Database into its own storage or does it merely mean it will connect to the MySQL db and query it directly? 2. If it is a long query (e.g. a 60 second query), does FnordMetric server cache previous results?
- paulasmuth 12y ago> 1. Does IMPORT TABLE mean that it has to copy data from MySQL Database into its own storage or does it merely mean it will connect to the MySQL db and query it directly? It will only connect to the MySQL database and won't copy any data into it's own storage. The SQL query will be pushed down into the MySQL database and the chart will be rendered from the result set that is returned by MySQL database (or other external storage system). > 2. If it is a long query (e.g. a 60 second query), does FnordMetric server cache previous results? Not yet but this is on the roadmap. (Pull Requests always welcome!)