Adding data to tables using the ColdFusion <cfinsert> tag is simpler and helps prevent the creation of multiple similar templates.
So why would you ever not use <cfinsert>? Is there ever a reason to use SQL INSERT instead of <cfinsert>?
The truth is that both are needed. <cfinsert> can be used only for simple data insertion to a single table. If you want to insert the results of a SELECT statement, you can’t use <cfinsert>. And you can’t use <cfinsert> if you want to insert values other than FORM fields—variables or URL parameters, for example.
These guidelines will help you decide when to use which method:
For simple operations (single table and no complex processing), use <cfinsert> to add data.
If you find that you ...