Hi,
I’ve figured out how to import multiple rows into one table with one
sql statement, using the syntax
Table.import columns, values
I make a list of column names, and I make a list of lists of data to
import into each column.
It works great. Inserting 100 rows in one statement appears to be
way, way faster than inserting one row at a time. But how do I do
this using a join?
I have two tables, product_lines and products. I want to import a lot
of new products at once, hopefully using the above method.
product_lines has a column called product_id, and products has a
column called id, which is a standard rails auto_increment column. I
guess I want to join the two tables, then import as described above.
How do I do this?
Charlie