Tag Archive for 'Oracle'

Oracle KEEP function Order By Keyword

Add a comment

I found something funny with the Oracle Keep / { First – Last } analytic function, on 11.0.0.6 & 11.0.0.7.
Same thing occurs also on Oracle 10g XE.
For those who don’t have a clue about this function, I wrote a small post on this subject.

Is Distinct A Synonym To Order By In MS SQL Server ?

1 Comment

This afternoon, I was chatting with Antoine Gémis about T-SQL, and this subject came on the table.
He was asking if, in my opinion, using both a distinct and an order by in the same statement would make the query worst due to the fact that distinct is already performing a sort on his own.
Working mostly [...]

I Dislike Guid As Primary Keys

Add a comment

Damn, I’m currently pushing a small SQL Server application database to an Oracle datawarehouse.
There are guids everywhere, even for a two rows reference table.
This is just so unreadeable and unconfortable to work with.
Try co-working on that kind of database, where you have to dig into the datas to understand them, the design flaws, the weird [...]

Using Analytics To Handle Breaks

Add a comment

When trying to solve last T-SQL Challenge I did find a query which fits well in both SQL Server and Oracle (with some syntax tweaking) and seems quite effective to me even on a ten millions rows table.
I said I’ll try to use the more advanced analytics function of Oracle to solve the problem, and [...]

Say Hello To Partitioned Outer Joins

Add a comment

Recently, I was helping someone to improve a procedure which fills a table with zero where there is no value for some days.
Instead of cursoring and inserting, I wrote a single query using a partitioned outer join to achieve this. Later in the conversation, I was asked to explain how this was working and I posted about. You [...]