MySQL Column Type
4 posts by 2 authors in: Forums > CMS Builder
Last Post: April 14, 2014 (RSS)
By ht1080z - April 10, 2014 - edited: April 12, 2014
Hi,
I have a table with ~16000 record and in this table a field that i want to use the "get option from database (advanced)" list option with related data from another field.
When the related record "num" is bigger than 999, i cannot see anymore the selected "title" label but only the record num that cannot be associated with the label. Of course the records with this unchained record nums are exists. Please see attached screenshots for details.
I presume this problem is somehow related to the MySQL column type and the way data is stored in the db.
How can i fix this issue?
PS: new screenshot (table_5.jpg attached)
Please advise,
Karls
By Chris - April 11, 2014
Hi Karls,
If you open up cmsAdmin/lib/database_functions.php in a text editor and search for 999, you can change the limit that CMS Builder imposes on "get option from database (advanced)" list fields:
$query = "SELECT `$valueField`, `$labelField` FROM `$selectTable` $where $orderBy LIMIT 0, 999";
If you do make this change, I highly recommend you create a file called CUSTOM_CHANGES.txt in your cmsAdmin/ directory and take notes about what you've changed so that you can re-apply your changes after upgrading CMS Builder in the future.
Hope this helps!
Chris