Hello everyone, I need help with creating php function, procedural php, or MySQLi for update or insert data. I have 3 tables. Table PRODUCTS contain all the information that i want to transfer into other two tables. Table PRODUCTS: id, name, serial, description Table List: id, name, serial Table View: id, name, description I need script that read table PRODUCTS and data from this table inesert or update values in the other two tables. 1. After call function 2. Read Table PRODUCTS 3. Read table LIST, if in "list" table have record with same serial as in table PRODUCTS update name with that serial from table products and if don't have insert id, name and serial with data from products 4. Read table View, if have record with same name as in table PRODUCTS update description with data from table PRODUCTS or insert id, name, description In table products I have over 4000 records. Thank you