update field in (left) joined table ?

update field in (left) joined table ?

crush123crush123 Posts: 417Questions: 126Answers: 18

I have a page with 2 tables, company & member details with a left join

is it possible to update data in the joined (members) table, as anything i try to change is ignored

http://www.test3.forthwebsolutions.com/admin/contacts/plugins/corporate_resultstest.php

the 'expires', 'complimentary' and 'premium' fields are all in the linked table, the others, which update ok, are in the main table

This question has an accepted answers - jump to answer

Answers

  • allanallan Posts: 63,498Questions: 1Answers: 10,471 Site admin
    Answer ✓

    Should be quite possible - it should really just be a case of adding the fields for the left join as you have done. The one additional thing that I think might be need is to submit the joined table's primary key value, which you can do in a hidden field, so there is something to perform the join on - but it depends on how the PHP is setup.

    Thanks,
    Allan

  • crush123crush123 Posts: 417Questions: 126Answers: 18
    edited April 2015

    Thanks Allan.

    Stupidly, I HAD added the linked table id value (as a foreign key from the parent table) to the Editor ajax page, but not to the editor instance itself.

    Sweet.

This discussion has been closed.