February 26, 2013 at 2:57 am
I have a loader application that loads rows into a database with one column in the form: aaa/bbb
The end user will query based on bbb, so to allow an indexed search on bbb we are creating an additional column holding just bbb.
My question is about best practice. Should we do this by editing the loader to send in the additional column directly, or should we use functionality within SQL Server (trigger or calculated field etc) to populate the new row, leaving the functionality of the loader app unchanged?
I feel that the first method is more elegent and easier for all to understand, but the second method is faster to implement and reduces the volume of data flow from loader to database.
Thanks
http://90.212.51.111 domain
February 26, 2013 at 4:55 am
I would suggest you to change logic of loader to load data to database as they should be.
Triggers run every time when the database fields are updated and it is overhead on system. It makes system run slower. Calculated fields make the loads to database slower too.
In addition, using triggers and calculated fields can add some restrictions on processing data.
Viewing 2 posts - 1 through 1 (of 1 total)
You must be logged in to reply to this topic. Login to reply