Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

Display db data in graph

Hi everyone, i'm trying to import data from database and display it in graph. database output will be in variant. I want it to show the data in graph. I think it need some conversion, i'm struggling here in conversion, i attached vi upto till i did and also attached the pic of data i'm getting from database. Please help me to get the data in graph.

Thanks

Download All
0 Kudos
Message 1 of 6
(2,645 Views)

You should be able to just use Variant To Data to convert directly into a floating point.  But do you know what the actual data type in the variant is (SGL, DBL, etc)?


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 2 of 6
(2,634 Views)

I earlier used variant to data node but sometimes it displays an error "unsupported data format" that's why i moved to trying another nodes. And another main problem i'm facing that, I written query to read the data in descending order , it accept the query but still it displays ascending order data. Can you share me where i'm making mistake?.

 

This is the query i'm using to read the data    "select * from NImeter order by datecreated desc"

Thanks for your response.

0 Kudos
Message 3 of 6
(2,632 Views)

@praveenrajk wrote:

I earlier used variant to data node but sometimes it displays an error "unsupported data format" that's why i moved to trying another nodes.


That tells me there was an error in your reading of the database.  Either the data stored was a different data type than you expected or there was no entry and you therefore got an empty variant returned.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 4 of 6
(2,629 Views)

Thank you sir, Now i'm able to see the data in graph but still the descending order query is not working , as well as in graph it shows wrong time, Can you tell me how to synchronize graph time and system time.

 

0 Kudos
Message 5 of 6
(2,626 Views)

@praveenrajk wrote:  Can you tell me how to synchronize graph time and system time.

Have your DAQ/Simulator output a waveform and the T0 will tell the chart what time to put in the x-axis.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 6 of 6
(2,613 Views)