Some changes in Apex 4.1 are that minor that you wouldn't even notice them until you fall over it.
Something I found recently was the code generated when choosing to source your primary key from a sequence when building a form.
Previously, the code was a little ugly:
declare
function get_pk return varchar2
is
begin
for c1 in (select EMP_SEQ.nextval next_val
from dual)
loop
return c1.next_val;
end loop;
end;
begin
:P6_EMPNO := get_pk;
end;
Now it's somewhat simpler:begin
if :P6_EMPNO is null then
select "EMP_SEQ".nextval
into :P6_EMPNO
from dual;
end if;
end;
What they haven't done, however, is clean up the custom function example - and this is a little more noticable.I noted this in EA for 4.0 - I think they said they've logged the change, but it still hasn't come along. While it's not really promoting this sort of code, it doesn't really have a place anywhere except perhaps an article talking about how bad it is for concurrent user environments.
Perhaps sequence usage will change with 12c?
Idle musings... Scott

0 comments:
Post a Comment