Viewing 5 posts - 1 through 5 (of 5 total)
Sorry, i thought this was to "easy"..
Anyway here is the whole trigger:
CREATE OR REPLACE TRIGGER dodaj_prispevek_trigger AFTER INSERT ON PRISPEVKI
FOR EACH ROW
DECLARE
st_prispevka NUMBER;
st_odobritve NUMBER;
max_clan NUMBER;
st_clana NUMBER;
BEGIN
-- dobimo id...
January 13, 2008 at 11:28 pm
Thanks for help! Yep, TOP invokes an error, so I'm sure Oracle doesn't support TOP... Nevertheless, I solved a problem... Thank again!
January 8, 2008 at 12:20 pm
Ok i managed it with ROWNUM = 1 😉
QUREY:
SELECT UDE_IDUDELEZENCA FROM
(
SELECT UDE_IDUDELEZENCA
FROM PRISPEVKI
WHERE ODOBREN = 0
GROUP BY PRISPEVKI.UDE_IDUDELEZENCA
ORDER BY COUNT(PRISPEVKI.UDE_IDUDELEZENCA) DESC
)
WHERE ROWNUM = 1;
Maybe is the problem with Oracle?
Thanks again...
January 8, 2008 at 11:28 am
Thanks for advice, but in line 1 (SELECT TOP 1 UDE_IDUDELEZENCA)
[UDE_IDUDELEZENCA is X in upper table] I get an error:
SELECT TOP 1 UDE_IDUDELEZENCA FROM
...
January 8, 2008 at 11:23 am
Viewing 5 posts - 1 through 5 (of 5 total)