We're Moving to a New Support Platform – Starting June 1st!

We’re excited to let you know that starting June 1st, we’ll be transitioning to a new support system that will be available directly on our product websites – Amelia, wpDataTables, and Report Builder. In fact, the new support platform is already live for Amelia and wpDataTables, and we encourage you to reach out to us there.

You'll always be able to reach us through a widget in the bottom right corner of each website, where you can ask questions, report issues, or simply get assistance.

While we still do not offer live support, a new advanced, AI-powered assistant, trained on our documentation, use cases, and real conversations with our team, is there to help with basic to intermediate questions in no time.

We're doing our best to make this transition smooth and hassle-free. After June 1st, this current support website will redirect you to the new "Contact Us" pages on our product sites.

Thanks for your continued support and trust – we’re excited to bring you an even better support experience!

Okay
  Public Ticket #2940463
MySQL Query Table
Closed

Comments

  • Justin Buckley started the conversation

    Hello,

    I have a table that with a status column, and want to count the number of rows with particular statuses, using the MySQL Count( ) function.

    For example:

    SELECT agency_owner AS 'Agency Owner',
        COUNT(IF(onboarding_status = 'Pending', 1, NULL)) 'Pending',
        COUNT(IF(onboarding_status = 'Registered', 1, NULL)) 'Registered',
        COUNT(IF(onboarding_status = 'Applied', 1, NULL)) 'Applied',
        COUNT(IF(onboarding_status = 'Approved:AO', 1, NULL)) 'Approved',
        COUNT(IF(onboarding_status = 'Approved:Corp', 1, NULL)) 'Onboarded'
    FROM
        6PfZ6A_reporting
    GROUP BY
        agency_owner

    Initially, my query produces the table I want - but when I attempt to save it, I get an error. See attachment for details. 

    Is this an issue with my query or the plugin?

  •  2,576
    Aleksandar replied

    Hello Justin

    Thank you for your purchase.

    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.

    Filtering, sorting, and search may not work properly if you include:

    • Accent graves ( ` ) around the table name
    • JOIN functions
    • UNION functions
    • CONCAT functions
    • sub-queries

    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″.

    Kind Regards, 

    Aleksandar Vuković
    [email protected]

    Rate my support

    wpDataTables: FAQ | Facebook | Twitter | InstagramFront-end and back-end demo | Docs

    Amelia: FAQ | Facebook | Twitter | InstagramAmelia 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