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

Community Tip - New to the community? Learn how to post a question and get help from PTC and industry experts! X

If i execute any query service it will take long time respond.

sarathi
12-Amethyst

If i execute any query service it will take long time respond.

If i execute any query service it will take long to respond , Thingworx Server is Configured with postgresql,   So i need to check postgresql health checkup and do i need to run any database Maintenance service separatly?

 

1 ACCEPTED SOLUTION

Accepted Solutions
mnarang
17-Peridot
(To:sarathi)

Hi ,

 

I think you also opened a support case with the same issue .Still if you have huge data in data tables and frequent update/delete operations on the data table .There might be dead tuples occurred in the schema side .That will cause data fetch very slow from the DB .Kindly see this doc for more understanding and to run VACUUM process on the table .

https://www.ptc.com/en/support/article?n=CS261063

 

Hope it helps 

 

Thanks ,

Mukul Narang 

View solution in original post

5 REPLIES 5
mnarang
17-Peridot
(To:sarathi)

It seems you have postgresql connected as external DB to ThingWorx .And there might be many reasons for long run as the Schema will be prepared by you manually .So if there are select on a large data ,index should be there .Or even there is frequent update/delete on the table ,you should run VACUUM (FULL/VERBOSE/ANALYZE) to check and removal for the possibility of dead tuples .

 

I hope my understand is correct according to your question ,if the issue is something else then elaborate the use case to understand it better .

 

Thanks ,

Mukul Narang 

sarathi
12-Amethyst
(To:mnarang)

Hi @mnarang , Thank for your information but Postgressql is defalut thingworx persistance provider, am using default thingworx default schema

mnarang
17-Peridot
(To:sarathi)

So that means you are querying ThingWorx schema in PostgreSql as persistence provider .Can you please elaborate ,what kind of query you are firing ? What is the use case here ?

I thought you are trying a SQL query service on a DB thing (Connected to external Postgresql DB) .  

sarathi
12-Amethyst
(To:mnarang)

Hi @mnarang 

it is big application, day by day application performance was too slow, Very specific if run service getdatatableentry service on any data table it will take long time service invoke. In our Application there are so many data tables are there, but in the postgres db all the data table are stored in single table named like data_table, Thingworx Data Table are differentiated based on entity id.....we are running more than five projects in single instance,

based on my understanding application side i didnt feel any problem but i thing postgres data table was bloated , please give me suggestion how to avoid table float in postgres, we are using postgres 9.4V, How do we check postgres health checkup continously from thingworx....

mnarang
17-Peridot
(To:sarathi)

Hi ,

 

I think you also opened a support case with the same issue .Still if you have huge data in data tables and frequent update/delete operations on the data table .There might be dead tuples occurred in the schema side .That will cause data fetch very slow from the DB .Kindly see this doc for more understanding and to run VACUUM process on the table .

https://www.ptc.com/en/support/article?n=CS261063

 

Hope it helps 

 

Thanks ,

Mukul Narang 

Top Tags