Quantcast
Channel: SCN: Message List - SAP HANA Developer Center
Viewing all articles
Browse latest Browse all 9165

Re: Modification of subject table in trigger not allowed--

$
0
0

Instead of explicitly writing an update statement, you would simply assign the new values via the transition variables NEW.

 

Check the documentation, there's an example in there, if I remember correctly.

 

Besides that, my recommendation around triggers would be: don't use them.

If you want to ensure clean data entry to your tables - there are other and better methods to achieve this.

With triggers in place, you've build yourself a maintenance nightmare that not even you as the creator have a good grasp on, let alone the poor next guy who has to support the application in years to come.

Also, the required logic typically is not limited to just a single table (e.g. checking cross references, totals, etc.) and so you end up with a high level of barely visible dependencies.

Last but not least, triggers slow down your transaction processing and nobody wants that, right?

 

- Lars


Viewing all articles
Browse latest Browse all 9165

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>