I have a data cursor loaded from a SELECT
a bit heavy,
at first I squeeze the 1st loop with a count and then I ride it again doing the internal procedures and showing on the screen The percentage of execution.
But this way doubles the execution time (Baianagem).
I need to know how to be some cursor function that returns the number of lines that will return to me.
Last cursor line
-
- Rank: Estagiário Sênior
- Posts: 8
- Joined: Thu, 19 Aug 2004 9:45 am
- Location: Angola
- Contact:
Charles Mafra
Oracle Developer
Oracle Developer
If your Oracle version is 9 or higher, you can in your cursor include a column with the total lines ... for example ...
WHERE etc ...
WHERE etc ...
- dr_gori
- Moderador
- Posts: 5024
- Joined: Mon, 03 May 2004 3:08 pm
- Location: Portland, OR USA
- Contact:
Thomas F. G
Você já respondeu a dúvida de alguém hoje?
https://glufke.net/oracle/search.php?search_id=unanswered
Você já respondeu a dúvida de alguém hoje?
https://glufke.net/oracle/search.php?search_id=unanswered
Hello Charlesmafra
ordered it!
Only this Count (*) Over () also works on 8i. But unfortunately, it is an analytical function that only has on the Bank Enterprise Edition. At Standard Edition does not work!
ordered it!
Only this Count (*) Over () also works on 8i. But unfortunately, it is an analytical function that only has on the Bank Enterprise Edition. At Standard Edition does not work!
- leobbg
- Rank: Programador Júnior
- Posts: 22
- Joined: Fri, 29 Oct 2004 10:25 am
- Location: PORTO ALEGRE - RS
Leo BBG Consultor Oracle
Bah, it's been a while since I do not enter the forum ein .. good face, so you do not need to open trocamentas times this cursor uses the down scheme that is done and you can continue using the other columns in a good.
Embrace! : Wink:
Select last_value( COLUNA ) over()
, COLUNA
, COLUNA2
, COLUNA3
FROM TABELA
-
- Rank: Estagiário Júnior
- Posts: 2
- Joined: Tue, 02 Feb 2010 7:20 am
- Location: Belo Horizonte - MG
Finally I found a topic about it!
Of the two forms functioned in Oracle 10g:
Thanks guys!
Of the two forms functioned in Oracle 10g:
select last_value(rownum) over() as total, campos from tabela
select count(*) over() as total, campos from tabela
-
- Information
-
Who is online
Users browsing this forum: No registered users and 12 guests