This topic is locked

Slow performance

2/22/2019 6:41:30 AM
PHPRunner General questions
S
sadisticmagician author

Hello,

I have a mysql Db with about 10000 records.

I had problem with phprunner 8.1 and now with phprunner 10.
If I set 10 or 1000 records for page, is same, very slow for load, seems that phprunner always load all the db.
I resolved problem using a custom query like: https://mysite.com/list.php?q=(data~between~2019-01-23~date13~2019-02-22) //last 30 days
Is there a way for resolve without use a custom query?
thanks

P
Penultimatum 2/22/2019

Maybe under the 'Search and Filter settings' set 'hide data until search' so that it does not query the data until you have specified the search parameters?

S
sadisticmagician author 2/22/2019



Maybe under the 'Search and Filter settings' set 'hide data until search' so that it does not query the data until you have specified the search parameters?


I have "additional WHERE tabs" like these: today (22) - yesterday (122) - last 30 days (1233).

If I set "Search and Filter settings" my tabs will all with 0 counts, so is not best way for me.

Sergey Kornilov 2/22/2019

Your database misses some indexes. You need to figure out what queries run slow and add indexes that will speed up your application. PHPRunner never "load all the db" unless you specifically tell it so. If you use WHERE tabs - this is the first place where you need to look.
More info:

https://xlinesoft.com/blog/2011/04/08/improving-perfomance-of-phprunnerasprunnerpro-applications/

S
sadisticmagician author 2/25/2019



Your database misses some indexes. You need to figure out what queries run slow and add indexes that will speed up your application. PHPRunner never "load all the db" unless you specifically tell it so. If you use WHERE tabs - this is the first place where you need to look.
More info:

https://xlinesoft.com/blog/2011/04/08/improving-perfomance-of-phprunnerasprunnerpro-applications/


My db have index on timestamp.

I have in 'WHERE TABS' this query for '2018' year:

my_timestamp_data >= '2019-01-01' AND my_timestamp_data < '2020-01-01'
But it is already slow.

Sergey Kornilov 2/25/2019

You need to post your project to Demo Account and contact support directly. We'll assist you with this.

A
acpan 4/1/2019

Hi,
Another way which i will normally do.
Your should create a hidden field called "year_updated" and create indexe on the year_updated.
Than update "year_updated" in the backgroud whenever new data is entered.

eg. at after record added event, set the value to current year for $values["year_updated"]
Than search by the year_updated in your where condition: WHERE year_updated = YEAR(NOW()) "
ACP



My db have index on timestamp.

I have in 'WHERE TABS' this query for '2018' year:

my_timestamp_data >= '2019-01-01' AND my_timestamp_data < '2020-01-01'
But it is already slow.