I have a MySQL insert request that should pull one data field from another table, and I was wondering if this can be done using the select subquery
INSERT INTO resources ( client_account_id, date_time, resource_name, resource_description_id, ) VALUES ( {0}, '{1}', '{2}', {3}, )
and I need a select query to get resource_description_id from another table
SELECT resource_description_id FROM resource_descriptions WHERE resource_description = '{0}'
I saw examples of duplication of whole tables, but I'm not sure how this can be done when only one field from another table is required, and the remaining fields from the form.
Thanks!
source share