My goal is to create a "tag" column with multiple filterable attributes. At the current time, I can configure a MySQL table with a SET column, then explicitly apply the same options in the data tab of the wpDataTable column to provide a proper list of individual filters that can be combined like a tagging system while still displaying a comma-separated list of tags in a single column. T
This also functions when trying to add an entry, allowing me to select multiple options for the SET tag column; however, submitting more than one tag in the SET column results in a truncated error, likely due to spaces between the comma-separated list of SET items in the INSERT statement or a lack of surrounding quotes. If there is a way to properly update MySQL SET columns using multi-select dropdowns please let me know!
If there is not, as I expect, it would be extremely useful to have proper rules applied when composing MySQL queries for SET columns so they can be added/updated. With limited ability to manage multiple tables, using a SET column is the only way I could find to apply an arbitrary number of tags to a row while still providing individual tags in the filter dropdown.
You can try preparing a MySQL view (which will return the data that you need, call it e.g. “view1” and then build a wpDataTables based on a simple query like "SELECT * FROM view1″.
For this case, you can only use Defined Values list in the column settings. When you edit a column, and go to the Data tab, you can choose what's going to be loaded in the column to "Defined values list", where you will define tags one at a time, which will then become available as individual values (tags) in edit and filters.
My goal is to create a "tag" column with multiple filterable attributes. At the current time, I can configure a MySQL table with a SET column, then explicitly apply the same options in the data tab of the wpDataTable column to provide a proper list of individual filters that can be combined like a tagging system while still displaying a comma-separated list of tags in a single column. T
This also functions when trying to add an entry, allowing me to select multiple options for the SET tag column; however, submitting more than one tag in the SET column results in a truncated error, likely due to spaces between the comma-separated list of SET items in the INSERT statement or a lack of surrounding quotes. If there is a way to properly update MySQL SET columns using multi-select dropdowns please let me know!
If there is not, as I expect, it would be extremely useful to have proper rules applied when composing MySQL queries for SET columns so they can be added/updated. With limited ability to manage multiple tables, using a SET column is the only way I could find to apply an arbitrary number of tags to a row while still providing individual tags in the filter dropdown.
Hello Chris
Thank you for your purchase, and your suggestion.
Our logic is based on a PHP SQL parser which has full support for the SQL dialect for the following statement types
SELECT, INSERT, UPDATE, DELETE, REPLACE, RENAME, SHOW, SET, DROP, CREATE INDEX, CREATE TABLE, EXPLAIN and DESCRIBE.
Some of them are disabled for security reasons.
You can try preparing a MySQL view (which will return the data that you need, call it e.g. “view1” and then build a wpDataTables based on a simple query like "SELECT * FROM view1″.
For this case, you can only use Defined Values list in the column settings. When you edit a column, and go to the Data tab, you can choose what's going to be loaded in the column to "Defined values list", where you will define tags one at a time, which will then become available as individual values (tags) in edit and filters.
Kind Regards,
Aleksandar Vuković
[email protected]
Rate my support
wpDataTables: FAQ | Facebook | Twitter | Instagram | Front-end and back-end demo | Docs
Amelia: FAQ | Facebook | Twitter | Instagram | Amelia demo sites | Docs | Discord Community
You can try wpDataTables add-ons before purchasing on these sandbox sites:
Powerful Filters | Gravity Forms Integration for wpDataTables | Formidable Forms Integration for wpDataTables | Master-Detail Tables