Okay
  Public Ticket #3666382
Relacionar tablas // Relate tables
Closed

Comments

  • Ignacio de la Torre started the conversation

    Tengo que relacionar 5 tablas para que me muestren información, no tengo idea de como hacerlo, estuve buscando entre los artículos pero no encontré nada, podrán ayudarme, por favor?

    I have to relate 5 tables to show me information, I have no idea how to do it, I was searching through the articles but I didn't find anything, can you help me, please?

  •  1,805
    Miloš replied

    Hi Ignacio,

    If you need to 'merge' data from multiple tables into one - You can do this in our SQL Query tables.

    You can either manually create the SQL Tables directly in your Database;

    or you can import data from a Spreadsheet using our Plugin.

    You can also update existing Manual tables via file upload.


    Then, to make an SQL Query Table from imported Manual tables - here is an example :

    3791094982.png

    Now, to make a new SQL Table from it,

    first, check in the Editing Tab/MySQL table name for editing:

    6795720227.png

    in my example, the Manual table name is wp_wpdatatable_39,

    so i make a new SQL table that will pull data from it;

    and we can choose all columns like :

    SELECT * FROM wp_wpdatatable_39

    or just specific columns;

    we can also have completely different settings/filtering/sorting and limitations for front-end users on each table;

    and you can make multiple SQL Query tables that pull the same data from the "main table".

    SELECT  column_name1,
            column_name2,
            column_name3
    FROM table_name


    In order to join data from multiple SQL Tables - you can search various tutorials online how an SQL JOIN can be done, or SQL UNION, for example, that should work.


    Let us know how it goes and if you encounter any issues.

    Thanks.

    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