Hey there, Awesome Customers!

Just a heads up: We'll be taking a breather to celebrate International Workers' Day (May 1st and 2nd - Wednesday and Thursday) and Orthodox Easter from Good Friday (May 3rd) through Easter Monday (May 6th). So, from May 1st to May 6th, our team will be off enjoying some well-deserved downtime.

During this time, our customer support will be running on a smaller crew, but don't worry! We'll still be around to help with any urgent matters, though it might take us a bit longer than usual to get back to you.

We'll be back in action at full throttle on May 7th (Tuesday), ready to tackle your questions and requests with gusto!

In the meantime, you can explore our documentation for Amelia and wpDataTables. You'll find loads of helpful resources, including articles and handy video tutorials on YouTube (Amelia's YouTube Channel and wpDataTables' YouTube Channel). These gems might just have the answers you're looking for while we're kicking back.

Thanks a bunch for your understanding and support!

Catch you on the flip side!

Warm regards,

TMS

Okay
  Public Ticket #3493073
query sql not working
Closed

Comments

  • Ian Gorayeb started the conversation

    Hello, I have this query that i use on a php shortcode on worpdress, and it works fine, but when i use it on the charts it only shows the last record of uniques records

    9083264917.png

    Instead of returning the max time of 'hora_interupcion' (11:01) it gives back the last record (10:02)


    Thos is the query generated by the tables wizard and modified by me.


    SELECT coordinador_electrico.`id_evento_cen`,
           coordinador_electrico.`id_comuna`,
           coordinador_electrico.`comuna`,
           coordinador_electrico.`id_region`,
           coordinador_electrico.`hora_interrupcion`,
           coordinador_electrico.`clientes_cortados`
    FROM coordinador_electrico
    WHERE 1=1    AND coordinador_electrico.`id_region` = '9'
       AND coordinador_electrico.`hora_interrupcion` <= CURRENT_TIME()
    GROUP BY coordinador_electrico.`id_comuna`
    ORDER BY coordinador_electrico.`id_comuna`,
    coordinador_electrico.`hora_interrupcion` ASC


  •  1,693
    Miloš replied


    Hi Ian,

    Firstly, I would like to sincerely apologize for the delayed response as we have been experiencing an unusually high number of tickets. I am sorry that it has taken longer than usual to respond to your concern and your patience is highly appreciated.

    -

    This is a Custom use-case, if i understood you are using the Table shortcode through a PHP code on your WordPress?

    Could you elaborate a bit more how are you implementing that PHP shortcode,

    and if you can show us some screenshots or even better record a Video how you configured all of this,

    and also how doe the table look at the back-end,

    i presume it looks as on your image?


    9083264917.png

    And if I understand, on the Table itself, it looks OK with these 3 rows,

    but on a Chart it just loads the last record ID 138 , the time of 10 : 02, right?

    -

    Can we also take a look at the back-end of the Table and the Chart?

    Please provide me a temporary WP-admin (administrator) user for your site where this happens, so we could log in and take a look ‘from the inside’ as that’s the most efficient way to see and resolve the issue. 

    We do not interfere with any data or anything else except for the plugin (in case that’s a production version of the site), and of course, we do not provide login data to third parties. 

    You can write credentials here just check PRIVATE Reply so nobody can see them except us.

    And please point me to this Table ID,

    and the Chart ID,

    if you can also show me a front end Page where you placed the Chart,

    or maybe the issue shows on the Chart back-end?

    If you can clarify if it's perhaps just front end, or the same as on the back-end of the Chart.

    Thank you.


    Kind Regards, 

    Miloš Jovanović
    [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