Home » SQL & PL/SQL » SQL & PL/SQL » Select Statement
Select Statement [message #195142] Wed, 27 September 2006 03:14 Go to next message
nickey.smith@gmail.com
Messages: 1
Registered: September 2006
Location: South Africa
Junior Member
When running the following code under oracle 817......

SELECT account,
trans_code,
COUNT(*) over(partition by trans_code)
FROM acount_info
ORDER BY 3 DESC

It returns:

ORA-00923: FROM keyword not found where expected

I suppose 817 is not capable of using this.Is there any thing else I can use to do this under 817?
Re: Select Statement [message #195144 is a reply to message #195142] Wed, 27 September 2006 03:29 Go to previous message
Littlefoot
Messages: 21151
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
My 8.1.7.4.1 supports it; no error.

You could, however, try with something like this:
SELECT a.account, x.trans_code, x.cnt
FROM account_info a, (SELECT trans_code, COUNT(*) cnt
                      FROM account_Info
                      GROUP BY trans_code
                      ) x
WHERE a.trans_code = x.trans_code;
Previous Topic: return array through a procedure
Next Topic: Unable to access DBMS_PIPE from a procedure
Goto Forum:
  


Current Time: Wed Aug 23 22:16:34 CDT 2017

Total time taken to generate the page: 0.14181 seconds