Okay
  Public Ticket #2418697
How do I get a table with both the active filters and the edit function?​
Closed

Comments

  • spounch started the conversation

    HI,

    I created a 'view' taking your advice into account. Already, it is a 'view', no sort, no limit. However, if I activate the edit mode, the 'Enable server-side processing' function is automatically activated in the 'data source' tab. However, this function prevents the filters from working. How do I get a table with both the active filters and the edit function?

    Best regards.

  •  2,572
    Aleksandar replied

    Hello spounch

    The server-side processing is being automatically activated for entries above 2.000 rows. Either way, without server-side you won't be able to edit the table.

    How does your query look like? If it's anything other than this:

    SELECT * FROM viewName

    it can cause issues with filtering, sorting and search.

    Can you show me how the table was created (SQL query)?

    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

  • spounch replied

    Hello Aleksandar, 

    The query is as follows, and it's a view 

    SELECT PK_user_validation, ident, Service, Metier, Identifiant, Nom, Prenom, NB_lignes
    FROM evrp3.v_users_valid WHERE ident <> 0;

    Best regards.


  • spounch replied

    Hello Aleksandar, 

    I found the problems.

    1)

    When in Phpmyadmin we copy a request in this form:

    SELECT * FROM `name_table`

    Well this is an obstacle to the proper functioning of Wpdatatables because of this kind of quotes surrounding the name of the table. These are not the quotes of the 4 key on a French keyboard (azerty). These are used to signify the character string. But those of key 7, which delimit the name of the table and which are not compulsory. Because `` is different from ''.

    So it is essential to remove this kind of quotation mark and use only this stripped formula as you advise yourself:

    SELECT * FROM name_table

    2)

    I have several databases, but I found that for Wpdatatables to work properly, the tables processed by Wpdatatables must be in the first database created. Can you modify Wpdatatables so that we can work independently on various databases? Because it can be practical.

    By taking care to eliminate these 2 small problems, I managed to find the solution. I haven't tested the editing function on these tables, but I think it shouldn't be a problem.

    Best regards.

  •  2,572
    Aleksandar replied

    Hi again spounch

    I'm glad to hear you were able to make it work.

    From version 2.3 we've implemented a feature that you can use multiple separate DB connections for MySQL, MSSQL and PostgreSQL. For MySQL engine we are dynamically adding the accent grave ( ` ), so there's no need to use it around the table name in the query.

    wpDataTables can create tables from separate databases, but it can't combine them. Meaning if you select one table from database1, all columns and possible JOINS need to come from the same database. You wouldn't be able to add database2 in the query.

    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