Okay
  Public Ticket #3351380
display and filtering
Closed

Comments

  • Chris Brooks started the conversation

    I set up a simple table, selected only certain columns to display, the table data comes up as expected - see URL.  

    Not working: If you put anything in a filter box, you get everything or you get nothing with message "showing 1-10 of 22 records". Always says 22, but the filtering just does not work. I tried with a search box as well, searching never worked either. Am I missing something in the setup?

    Finally, the filter says it can be in the table header or footer, but it only shows in the footer. How do you make it in the header (assuming it gets working)

  • Chris Brooks replied

    ANy suggestions on how to make simple filtering work ?

  •  1,689
    Miloš replied

    Hi, Chris.

    I see this is an MySQL Table.

    The filtering sometimes does not work with server-side processing due to our SQL Parser;

    but there is a solution, i will elaborate.

    -

    Could you show me the SQL Query that was used for this table - and I can advise if maybe some small modification/correction is needed to get the search to work?

    -

    But you can also check these points to save time if you wish.

    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

    -

    So, first you can check for accent graves around the table name, if you have this, remove it...

    Then, see if you used CONCAT to create any column.

    If so, go into this column setting, and disable it from "global search" in the Filtering tab.

    -

    7138515403.png

    -

    If none of that helps,

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

     If you need help with that, you can see our video, where we show an example of using View in our plugin.

    -

    Let me know If that helped, and i can take a look at the Query, as well.

    Thank yousmile.png

    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

  • Chris Brooks replied

    Hi 

    There are none of the concerns. The table is simple columns:

    8765896039.png

    The query was SELECT * from SEIDogList

    I also tried selecting from a view, which is defined on the database as 

    select
      SEIDogList.DogID      AS DogID,
      SEIDogList.LastName   AS Lastname,
      SEIDogList.FirstName  AS Firstname,
      SEIDogList.AKCRegNo   AS AKCRegNo,
      SEIDogList.AKCRegName AS AKCRegName,
      SEIDogList.Breed      AS Breed,
      SEIDogList.Callname   AS Callname
    from SEIDogList

    Same problem, will return all data but nothing if trying to filter.

  •  1,689
    Miloš replied

    Hi, Chris.

    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.


    1. In regards to filtering/search issues, I can't seem to reproduce this issue on the page table.

    I have tried each column filter, and they all seem to work.

    You can see my Video here - https://watch.screencastify.com/v/18qsPzSsz2MKEqKZ5BrV.

    Can you tell me which column filter is not working from your end;

    or maybe you did something to fix this in the meantime?

    If you can still reproduce the issue for filtering/ or search; could you show me some screenshots or a Video,

    and elaborate a bit more about this issue?



    2. In regards to moving the advanced filtering to render in table Header, sorry I forgot to answer that question initially.

    You can do this in main plugin settings/Render advanced filter.

    1321039590.png

    You can also move filters above the table, in a Form;

    in table settings/Sorting and Filtering/Filters in a Form.

    5073911065.png


    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

  • Chris Brooks replied

    Milos,

    Thank you for the response. I can't exactly explain what may have been going on prevously. I kept playing around with the settings etc and now it does seem to be working ok. Sometimes it seems like it take two times entering a filter value for the filtering to take effect, but generally then it works as expected.

    I may have questions as I delve into header detail setup but for now all seems well.

  •  1,689
    Miloš replied

    Hi, Chris.

    I am happy to see that now it seems to generally work well, as needed for your use-case,

    but we will be on stand-by, let me know if you notice this issue reoccur at any point;

    and also you can open new tickets in the meantime, if anything else comes up.

    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