Can I generate an sql insert statement from an array returned by find methods?
Thanks.
Can I generate an sql insert statement from an array returned by find methods? Thanks. |
|||
|
Yes, You can. After performing the find() operation iterate your data using foreach loop and make a string based insert query with ";" as separator after each insert query. Create a file with extension as .sql and use force download component to download it. I have some sort of code that can help you. I'll try to give you the code soon. |
|||
|