List field no looking up details

5 posts by 3 authors in: Forums > CMS Builder
Last Post: September 28, 2013   (RSS)

By pault - September 26, 2013

I have a list field which is set up to 'Get options from database (advanced)'.

I've then selected a table name and the field for options values is set to 'num' and the field for option labels is a descriptive field.

This seems to work for a number of the records but doesn't include all of them, only the first 1000 as far as I can tell.

Is there a way around this? 

Thanks, Paul.

By pault - September 27, 2013

Hi Jason,

Thanks for the reply.  In this instance it's not really possible to filter the list based on other parameters, the table in question is storing customer enquiries and there's a list field on this table for 'Customer' which refers to the customer table where there are 1500 customers.

Are you able to point me in the direction of the 1000 limit within the code or is it in a lot of places?  We don't anticipate the customer database growing much more now so even if I could increase the limit to 2000 then that would solve the problem.

Thanks, Paul.

By gregThomas - September 27, 2013

Hi Paul,

There is a way to get around the 1000 limit issue without having to update any of the CMS Builder code. If you go to edit your section, and then edit the list field. Then change the list options option to Get options from MySQL query (advanced). Then you just need to change the provided mysql call text in the text area to use the variables you were using before. 

The Get options from MySQL query (advanced) doesn't have any limit on the number of records it retrieves.

Let me know if you have any questions.

Cheers

Greg

Greg Thomas







PHP Programmer - interactivetools.com

By pault - September 28, 2013

Thanks Greg, that works perfectly.

Regards, Paul.