The last few weeks I’ve made quite a few improvements to my TAPI generator which I thought I’d share. I’ve also added an Apex API generator which generates code suitable for interfacing between simple Apex applications and my TAPIs. This reduces the volume of PL/SQL required within Apex to a bare minimum.
- Templates are now defined in a package spec, so they are easier to edit in a tool with syntax highlighting (more or less)
Sometimes it’s the simple little things that can add polish and make your Apex application shine. One simple little thing that you can do is add a Refresh button to improve the usability of your Apex 5 calendar. This makes it easy for the user to see recent changes on the database, e.g. if events had been added or changed since the page had last been loaded.
- Set the Static ID on the Calendar region (e.g. (more...)
One of the things that used to bug me about the Apex developer toolbar was that it sometimes obscured the content I was trying to test at the bottom of the page; you could turn it off but then next thing you want to access it you have to jump through the hoops to turn it back on again.
I just noticed it now has some new display options which solves this problem perfectly:
I needed to generate a random string with an exact length consisting of numeric digits, that I could send in an SMS to a user as a temporary account “pin”.
DBMS_RANDOM.string is unsuitable for this purpose as its supported modes all include alphabetic characters. So I used
DBMS_RANDOM.value instead. I call
TRUNC afterwards to lop off the decimal portion.
from (select 6 digits from dual);
Just a quick note that (as mentioned by Christian Neumueller earlier) Apex 5 now populates an Application Context
APEX$SESSION with the session’s User, Session ID and Workspace ID:
Using the above should be faster in your queries than calling v() to get these values. Note that the alias
'SESSION' won’t work like it does with v().
The context is managed by the database package
APEX_050000.WWV_FLOW_SESSION_CONTEXT which is an undocumented (more...)