Category Archives: Helper SQL

How to replace multiple replace functions?

Recently in OTN, some one posted below question. using 11.2.0.4 EE. How can I replace the following: “replace(replace(replace(config_item,’COLLATERAL’,’COLLAT’), ‘AGREEMENT’,’AGREE’),’VALUE’,’VAL’);” with a single regular expression or something simpler ? The reason is I need something simpler since more strings will be … Continue reading

Rate this:

Posted in Helper SQL, Oracle Internal | Tagged , , , , , | Leave a comment

Putting special character in middle of string.

Recently in OTN someone posted below SQL requirement. “In one of my column having value of string like ‘12345678’. Now i want not all of these value would be visible. So i would put * on some characters. After updating … Continue reading

Rate this:

Posted in Helper SQL | Tagged , , , | Leave a comment

Get Difference between two date, as Year Month Day Correlated.

Recently in a forum someone posted below problem statement. How to calculate years with months and day between two dates. Eg. 17-6-2013 – sysdate Expected Output: 1 Year 5 Month 0 Day Note: Sysdate: = 17 Nov 2014. So Year, … Continue reading

Rate this:

Posted in Helper SQL | Tagged , , | Leave a comment