Quantcast
Viewing all articles
Browse latest Browse all 2586

Insert into select statement where condition

Hello,

New member here and need some advice. Basically, what I need to do is to copy a set of records from one table to another table based on value of field -- insert into select statement where condition

INSERT INTO table2 (column1, column2, column3, ...)
SELECT column1, column2, column3, ...
FROM table1

WHERE table1.column1 = 'TEXT';

I'l like to execute this from a custom button.Does PHPR have an existing function in the API that supports this or would I execute a stored procedure?

Please advise.
Thank you,
Robert

Viewing all articles
Browse latest Browse all 2586

Trending Articles