Page 1 of 1

Adding data from a database query

Posted: Wed Dec 02, 2020 9:47 am
by 17789313
Hi,

What is the recommended was of adding the results of a database query to a Tee.PointXY?

Thanks,

Bruce

Re: Adding data from a database query

Posted: Fri Dec 04, 2020 12:38 pm
by yeray
Hello,

You may want to take a look at the Database tutorial here:
https://steema.com/docs/TeeChartVCLDatabase.htm

Re: Adding data from a database query

Posted: Fri Dec 04, 2020 3:15 pm
by 17789313
This is VCL. I'm talking about Javascript.

Re: Adding data from a database query

Posted: Mon Dec 07, 2020 12:30 pm
by yeray
Hello,

Ouch, excuse me.
Check the "Data Sources" section in the demos.
If you still find problem with it, please specify what format does the data have after running the query.

Re: Adding data from a database query

Posted: Tue Dec 08, 2020 8:59 am
by 17789313
The demos do not include a database example.

I am currently using PHP to get the data, converting it to a Json array and on a row by row basis adding it to the chart. Is this the only way of doing it?

Re: Adding data from a database query

Posted: Wed Dec 09, 2020 12:43 pm
by yeray
Hello,

An alternative would be to convert the data to a JSON structure that can be loaded as in the From JSON example.