Hi,
I am using TChart Pro ActiveX V5.0.3 - with VB6 against a MySQL database using ODBC 3.51.07.
When I get the data using the following query "SELECT Date, P1 from mytable" all is ok, but as soon as I use a summary function to get average values as "SELECT CONCAT(SUBSTRING(Date,1,13),'.00.00') as Date, AVG(P1) AS P1 FROM mytable group by Date order by Date", I get the following error: "'2004-05-24 15.00.00' is not a valid floating point value". I cheked the recordset and the first record 'Date' field value change from "24/05/2004 15.16.00" to "2004-05-24 15.00.00".
Here is the code I use to plot the data.
With .Series(0)
.DataSource = rs
.XValues.DateTime = True
.YValues.ValueSource = "P1"
.XValues.ValueSource = "Date"
End With
I tried to use "SELECT DATE_FORMAT(Date, '%d/%m/%Y %H.%i.00') as Date ...." without success as well.
I would be grateful for any suggestions.
Kind regards,
Paolo