• Hello Fabrik Community

    Fabrik is now in the hands of the development team that brought you Fabrik for Joomla 4. We have recently transitioned the Fabrik site over to a new server and are busy trying to clean it up. We have upgraded the site to Joomla 4 and are running the latest version of Fabrik 4. We have also upgraded the Xenforo forum software to the latest version. Many of the widgets you might have been used to on the forum are no longer operational, many abandoned by the developers. We hope to bring back some of the important ones as we have time.

    Exciting times to be sure.

    The Fabrik 4.0 Official release is now available. In addition, the Fabrik codebase is now available in a public repository. See the notices about these in the announcements section

    We wish to shout out a very big Thank You to all of you who have made donations. They have really helped. But we can always use more...wink..wink..

    Also a big Thank You to those of you who have been assisting others in the forum. This takes a very big burden off of us as we work on bugs, the website and the future of Fabrik.

Slow form caused by the generation of the database join field

paolo.tateo

Member
Hi Fabrik people!

Joomla 2.5.24
Fabrik 3.0.5.2

My problem is this: I have a form with in many databasejoin fields like this:
Render join as: Drop-down
Connection: site database
Table: jos_app_order_status
Value: id
Label: order_status_name
Joins where and/or order by statement (SQL): WHERE id_contest="{$my->id}"


I enabled fabrikdebug (?fabrikdebug=1) and look what happens when Fabrik trying to render the field.

Strangely Fabrik perform two queries to create the array of values:

Code:
Array
(
    [SELECT DISTINCT(`jos_app_order_status`.`id`) AS value, order_status_name AS text FROM `jos_app_order_status` AS `jos_app_order_status`  ORDER BY text ASC ] => Array


And after

Code:
    [SELECT DISTINCT(`jos_app_order_status`.`id`) AS value, order_status_name AS text FROM `jos_app_order_status` AS `jos_app_order_status` WHERE id_contest="1835" ORDER BY text ASC ] => Array

The first query takes out thousands of results, then the second only three results. Since I have dozens of similar fields, the time taken to open the form is over 60 seconds.

Today I can't still update Fabrik, then I would prefer to change only the code necessary. I planned a major update in a couple of months, but I have to go slow: This site consists of 180 lists with a database of 120 GB. We are entering the Guinness Book of Fabrik?

Thanks
 
I'd have to see the site and enable Fabrik debug mode to see what's happening. It looks like the join's buildQuery() is being called a second time but without "incFilters" set, which doesn't happen in 3.1, and I can't immediately see why it would happen in 3.0.

Note that we really don't support 3.0 development any more, so if this needs some custom coding, we would have to charge on an hourly basis for that.

-- hugh
 
We are in need of some funding.
More details.

Thank you.

Members online

Back
Top