0

I am using Pentaho CDE . I have a requirement to implement a d3 chart http://bl.ocks.org/robschmuecker/7880033

i have installed the d3 component library. selected the d3 component from d3 components in the component panel.

how do i proceed coding. since this chart is taking json as input, but i need to pass sql data source.

could anyone guide me on this. I know this is quite a broad question, but i am stuck at the very beginning.

mzy
  • 1,754
  • 2
  • 20
  • 36
Alen
  • 174
  • 4
  • 11

1 Answers1

0

You need to transform your data from a SQL table to the json the component requires.

If you're building a CDE dashboard, you should use CDA to query the database and return the result set. Then in the D3 component postFetch function, execute the required transformations.

Pedro Vale
  • 756
  • 1
  • 4
  • 4
  • this is pretty old tutorial, but it might get you up and running with CDE: http://type-exit.org/adventures-with-open-source-bi/2011/06/creating-dashboards-with-cde/. There are other more up to date paid materials - google for CDE tutorial. – Pedro Vale Aug 03 '14 at 14:01
  • @PedroVale some other d3 chart in CDE tutorial? – ssoto Oct 03 '14 at 12:03
  • No. If you want to use D3 in CDe, take a look at http://pedroalves-bi.blogspot.pt/2014/05/d3-pentaho-component-gallery_17.html or check the new Visualization API component for CDF/CDE. If you download the TRUNK version of CDE there's a sample there that uses the Visualization API component to load a d3 chart. – Pedro Vale Oct 16 '14 at 21:27