How an Oracle error can send you the wrong way…



By Patch ~ January 6th, 2016. Filed under: Oracle, SQL.

At my current assignment I needed to create an update statement to copy data from one table to another. Quite a simple task, I would say, but an error or actually a constraint violation sent me the wrong way in finding my solution.

Continue reading »

Update multiple columns



By Patch ~ December 23rd, 2015. Filed under: Oracle, SQL.

This is something I knew somewhere in the back of my head, but had forgotten about until now.

When you want to update multiple columns in a single SQL statement based on a sub query you can of course duplicate this query for every column you want to update. But this violates the SPOD (Single Point Of Definition) ‘rule’.

Continue reading »

Autonomous transaction to the rescue



By Patch ~ August 25th, 2015. Filed under: Oracle, PL/SQL, SQL.

Today, at my current project, I came across an issue where autonomous transactions came in handy.

The situation: I need to create a query to perform an export. A couple of the fields to be selected come from a global temporary table, nothing fancy so far except this global temporary table is filled by a (rather complex) procedure. Another problem is this table is emptied for every row, i.e. it will contain only one row at a time. ‘Just build a wrapper table function for this procedure and have that function call the procedure’ was my first idea.

Continue reading »

What’s this ‘WHERE 1=1′?



By Patch ~ March 22nd, 2015. Filed under: Oracle, Plugins, SQL.

Since some time I have been adding WHERE 1=1 to all my queries.
I get queries like this:

SELECT *
  FROM emp e
 WHERE 1=1
   AND e.ename LIKE 'A%'
   AND e.deptno = 20

Lots of people ask me what’s the use of this WHERE 1=1.

Continue reading »

Write My Essay For Me Com



By Administrator ~ March 9th, 2015. Filed under: Uncategorized.

This write my essay for me com will allow you to recognize what technique you must decide to try tackle a marketplace that is more substantial. Third rate desires follow so forth, and second level ones. In regards to advertising his idea can be beneficial. While nearing a write my essay for me com person through a sales that is cool, nevertheless, you’ve extremely little details about them. The point will not be unaware of how you can help the consumer decide that your product is needed by them. Discuss the elements, activities, or family lifestyle - anything apart from the product you’re selling.

Continue reading »

Our partners: buy essay