cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

How does Thingworx store data in H2 database?

Level 1

How does Thingworx store data in H2 database?

I just try to view some data out of my Thingworx instance through the H2 Console. Does anyone know in which table I can find something?

Tags (1)
6 REPLIES 6

Re: How does Thingworx store data in H2 database?

Hi, I also like crawling the database tables, but ThingWorx has so many great API functionality, that ir realyl makes no sense to directly crawl the DB. Additionally it is also not really recommended to do, because for example deleted data get only flagged and afaik deleted afterward in a cleanup job. API is aware and will give you always the right answers. Crawling DB must have this deep inside to understand really every aspect.

Re: How does Thingworx store data in H2 database?

Thanks for your quick response. I just wanted to show it for a small Demonstration. Which API functionality do you mean exactly? For example REST calls to delete data?

Re: How does Thingworx store data in H2 database?

Do u find the thingworx data in H2 database? I also have the same problem.

Re: How does Thingworx store data in H2 database?

Hi Li, could you please elaborate on your use case? Is there specific reason why you need to directly access H2 data?

Re: How does Thingworx store data in H2 database?

I finally found the solution:

Instead of connecting to the directory

jdbc:h2:E:\ThingworxStorage\database

you need to connect to the database name. The name of the db file is data.h2.db So you need to connect to

jdbc:h2:E:\ThingworxStorage\database\data

and you will see all the tables (your absolute path will differ):

2018-05-17 18_59_34-H2 Console.png

 

Now you can query all the tables!

 

Regards,

Nico

Re: How does Thingworx store data in H2 database?

And leave the user and password blank