Home » SQL & PL/SQL » SQL & PL/SQL » Window Functions = Analytic Functions in Oracle RDBMS? (Oracle 11g)
Window Functions = Analytic Functions in Oracle RDBMS? [message #621214] Mon, 11 August 2014 12:51 Go to next message
rc3d
Messages: 191
Registered: September 2013
Location: Baden-Württemberg
Senior Member
Hi

http://www.postgresql.org/docs/9.1/static/tutorial-window.html

Quote:

A window function performs a calculation across a set of table rows that are somehow related to the current row.


Window Functions = Analytic Functions? True?
Re: Window Functions = Analytic Functions in Oracle RDBMS? [message #621216 is a reply to message #621214] Mon, 11 August 2014 12:59 Go to previous messageGo to next message
Michel Cadot
Messages: 59775
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator

Yes and is reporting functions in other places...

Re: Window Functions = Analytic Functions in Oracle RDBMS? [message #621217 is a reply to message #621216] Mon, 11 August 2014 13:12 Go to previous messageGo to next message
rc3d
Messages: 191
Registered: September 2013
Location: Baden-Württemberg
Senior Member
Michel Cadot wrote on Mon, 11 August 2014 12:59

Yes and is reporting functions in other places...



Thank you Michel. I didn't learn Analytic Functions during SQL Expert course. Any good books?
Re: Window Functions = Analytic Functions in Oracle RDBMS? [message #621219 is a reply to message #621217] Mon, 11 August 2014 13:27 Go to previous messageGo to next message
Michel Cadot
Messages: 59775
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator

You can have a look at:
Database Data Warehousing Guide
Chapter 22 SQL for Analysis and Reporting

Re: Window Functions = Analytic Functions in Oracle RDBMS? [message #621221 is a reply to message #621219] Mon, 11 August 2014 14:38 Go to previous messageGo to next message
Littlefoot
Messages: 19786
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
I don't speak Postgres (link in the first message suggests that rc3d talks about it) so I have no idea whether its implementation is the same as Oracle's (which is contained behind Michel's link).

So - in order to avoid confusion, which database do you work with now, rc3d? Because, reading your previous messages, you remind me of a bee (user) which visits many flowers (databases), but can't decide which one suits you the best.
Re: Window Functions = Analytic Functions in Oracle RDBMS? [message #621222 is a reply to message #621221] Mon, 11 August 2014 15:10 Go to previous messageGo to next message
BlackSwan
Messages: 23048
Registered: January 2009
Senior Member
If they were called FUBAR functions, how would you behave differently.
Why does it matter what label is attached to them?
Re: Window Functions = Analytic Functions in Oracle RDBMS? [message #621225 is a reply to message #621221] Mon, 11 August 2014 15:15 Go to previous messageGo to next message
rc3d
Messages: 191
Registered: September 2013
Location: Baden-Württemberg
Senior Member
Littlefoot wrote on Mon, 11 August 2014 14:38

So - in order to avoid confusion, which database do you work with now, rc3d? Because, reading your previous messages, you remind me of a bee (user) which visits many flowers (databases), but can't decide which one suits you the best.


production environment is still Oracle RDBMS. I guess till end 2015. I am experimenting (trying to migrate) with MySQL and a little PostgreSQL. But that has nothing to do with prod.

[Updated on: Mon, 11 August 2014 15:16]

Report message to a moderator

Re: Window Functions = Analytic Functions in Oracle RDBMS? [message #621226 is a reply to message #621222] Mon, 11 August 2014 15:18 Go to previous messageGo to next message
rc3d
Messages: 191
Registered: September 2013
Location: Baden-Württemberg
Senior Member
BlackSwan wrote on Mon, 11 August 2014 15:10
If they were called FUBAR functions, how would you behave differently.
Why does it matter what label is attached to them?


when you use $SEARCHENGINE you need to know correct terms. Else you will find rubbish and SPAM.
Re: Window Functions = Analytic Functions in Oracle RDBMS? [message #621227 is a reply to message #621222] Mon, 11 August 2014 15:21 Go to previous messageGo to next message
Littlefoot
Messages: 19786
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
BlackSwan

If they were called FUBAR functions, how would you behave differently.
Why does it matter what label is attached to them?


Because they might behave differently.

A quick Google search for differences between Oracle and PostgreSQL returned Porting from Oracle PL/SQL (PostgreSQL documentation). Here's one of them:Quote:

Integer FOR loops with REVERSE work differently: PL/SQL counts down from the second number to the first, while PL/pgSQL counts down from the first number to the second, requiring the loop bounds to be swapped when porting. This incompatibility is unfortunate but is unlikely to be changed.

So: it appears that both Oracle and PostgreSQL support integer FOR loops with REVERSE, but these are implemented differently.

These could have been named FUBAR loops with UPSIDE_DOWN, but they would still work differently.

That's, more or less, what I was thinking of when mentioning possible differences. If there are none, fine with me.
Re: Window Functions = Analytic Functions in Oracle RDBMS? [message #621229 is a reply to message #621227] Mon, 11 August 2014 15:35 Go to previous messageGo to next message
BlackSwan
Messages: 23048
Registered: January 2009
Senior Member
>Because they might behave differently.
They might behave differently even if they had the same name.
Re: Window Functions = Analytic Functions in Oracle RDBMS? [message #621230 is a reply to message #621229] Mon, 11 August 2014 15:39 Go to previous message
Littlefoot
Messages: 19786
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
That's what I'm trying to say all the time.
Previous Topic: number to date format ?
Next Topic: Find the number 3 in the third and last digits of an SSN
Goto Forum:
  


Current Time: Tue Nov 25 19:54:43 CST 2014

Total time taken to generate the page: 0.09590 seconds