"Database examples"
Hi There,
I would like to iterate through rows in an SQL table, process each row and insert the results into a new row in a different table.
我没能找到好的examples for playing with a database like this, any suggestions?
Regards,
Sean.
I would like to iterate through rows in an SQL table, process each row and insert the results into a new row in a different table.
我没能找到好的examples for playing with a database like this, any suggestions?
Regards,
Sean.
Tagged:
0
Answers
what do you have so far? Did you already manage to setup the connection to the SQL server? Then the next step will be to play around with the Read Database operator. If your data is fits into memory, the easiest way will be to download it with the aforementioned operator, transform it, e.g. with Generate Attributes if that fits your needs, and then write it back into the database with Write Database. Please note the different options on how to deal with existing tables in that operator.
I think if you experiment or half an hour with these operators on a sample database (don't use your production database for experiments!), you should be fine.
Happy Mining!
~Marius
Thanks for the feedback. I have been able to read a row from a table from a database and clean the data. How to automatically write that data back to the database is still a mystery to me. I am also unsure how to implement loops or a way of iterating through a number of rows.
If I can do this it will be great as I really like Rapidminer and would prefer to use it moving forward if possible.
Any suggestions would be appreciated.
Regards,
Sean.
The input of the operator is an example set, whose rows will be written to the database in the way explained above.
Regards,
Marius