This topic is locked
[SOLVED]

 Insert into select statement where condition

5/31/2019 2:08:14 AM
PHPRunner General questions
rdsanford author

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