Category Archives: Application Express

My Oracle Openworld APEX Sessions

Oracle Openworld 2014 is just around the corner (it’s still not too late to register) and I’m going to be presenting a couple of sessions –

  • Oracle Application Express + Node.JS: A Primer [UGF5222] – Sunday, Sep 28, 2:30 PM – 3:15 PM – Moscone South – 300
  • Testing Oracle Application Express: Removing the Boring from Testing [CON5219] – Thursday, Oct 2, 2:30 PM – 3:15PM – Moscone South – 303

I presented these sessions at KScope14 and got great feedback from both sessions (I’m very proud to say I got a Top Speaker Award for the Testing session).

Hope to see you there!

Charting the rise of Application Express

A recent post by Dimitri on whether APEX is still worth looking at (read the article to see the context!), and in particular the comment by David Peake

For some proof points look at the number of APEX sessions at Oracle Openworld 2008 = 38

reminded me that I still had an old post sitting in my drafts folder regarding the numbers of sessions related (directly or indirectly) to Oracle Application Express at the conference I’ve attended in the last couple of years, so I’ve dusted off the post (this one now!).

So since a picture is worth a thousand words, here’s the chart –

APEX Presentations Totals

Note: I have just included the Collaborate, ODTUG, OpenWorld and UKOUG events as those were the ones I attended. There were many other events during those periods where there were Application Express topics being presented. Also note that there are no released figures for OpenWorld 09 and UKOUG 09 yet.

There are a few different ways to interpret these figures, firstly cynics might say, “ahh but look how the number at Collaborate 09 is less than 07”, or “look how the number at UKOUG 08 was less than 07”, well remember that the APEX abstracts are competing with lots of other abstracts to make the final cut into the accepted presentations.

Looking at 2008, it was a huge increase (not far off double) the number presentations that were given in 2007.

Currently in 2009, even with just the ODTUG and Collaborate figures to go off, we have around as many as there were in 2007 and almost half as many as there were last year (and remember we still have the OpenWorld and UKOUG figures to add to that).

So…in my opinion, yes Application Express is definitely growing, it’s certainly a good time to be involved with it.

UPDATE: I created a small APEX application on top of the data behind that chart, so you can see the session details, break by presenter etc.

You can access the application here, if you are aware of any omissions, errors or additional conferences that should be included drop me a mail/comment and I’ll try and update it.

Carl Backstrom – A great loss

I woke up to the news this morning that Carl Backstrom has been killed in a car accident.

I’m not going to post a link to the news article directly, as it contains some distressing details that some people might not wish to read, however the news has been confirmed by various Blogs and (reliable) people on Twitter.

For those who didn’t know him, Carl was “Mr AJAX & Javscript” in the Application Express World, he was responsible for some incredibly cool features in the APEX tool and was always helpful with the APEX community.

However more than that, Carl was a really cool and great guy. I’ve had the pleasure of meeting Carl at many of the Oracle events in the last few years and would often send him “hey dude, what’s up with my javascript here?” messages on MSN in the small hours and he would always answer them, without fail.

Carl was definitely a good friend, I’ll miss him a lot and I’ll never have another whiskey without checking for flies first!

One of my fondest memories about Carl (and I have a lot) was the day he took Dimitri and me for a guided tour around San Francisco and showed us sights that we never would have seen otherwise.

My thoughts are with Carl’s family and friends at this difficult time.


Pro Oracle Application Express

Well it’s been a long time in the making, but the Pro Oracle Application Express book that I wrote (with a chapter on Themes and Templates contributed by Scott Spendolini) is finally shipping!

I started working on the book way back and it seems barely a week has gone by since when I haven’t been asked the question (quite rightly!) “when is the book coming out?”.

This is the first technical book (or any book for that matter) that I have written, so the whole thing was very much a learning experience for me, although obviously I like to think I know about the content side of it, the logistics of writing the chapters, the review process, the amount of time it consumes was all very new.

When I agreed to write it, I contacted a few people who have already published Oracle technical books just to get some opinions on what I’d just agreed to. The comments all had a very similar theme of “Prepare to put your social life on hold because writing a book takes a lot longer than you imagine”.

I really did enjoy writing the book, but I totally agree with how much time it can take, there is nothing quite looking at a blank screen for an hour, or spending three hours reworking a single page and ending up with what you had original, or the joy of laying out at example only to find that you want to completely change it and have to start again from scratch.

Now, those who know me know I’m not a very ego-driven person, however, I have to say that it did raise goose-bumps actually seeing the book selling on Amazon.

Pro Oracle Application Express

Even weirder was seeing where the book was positioned in Amazon’s sales figures.

Pro Oracle Application Express

Fleetingly, the book was in the top 1000 books being sold on Amazon and was the number #1 seller in the Databases section (and the Oracle section). Of course the cynic in me would say that’s partly due to all the back-orders being satisfied from it being late, but it’s still nice to see that people are actually buying it.

I certainly don’t expect to please everyone with the book, since I was limited in terms of pages what I could write, I already went way over the original 400 page estimate (to over 700 pages) and could have easily carried on for another 500 pages or so. Also the way I’ve structured the book is to cover a different area of development in each chapter, things that are typical to encounter when designing production applications in Application Express, so there are certainly topics that I don’t talk about since I needed to talk about other areas in much more detail.

I certainly expect a lot of emails along the lines of “Why doesn’t it contain XYZ?”. Well the answer to that is that it is not intended to be a complete guide of everything you can do in Apex, more an in-depth guide on certain key areas.

So that’s that one done…is it time to start thinking about another one? Hmm maybe after a short “rest” 😉

Application Express 3.1.2 Upgrade – Session Zero and Redirects

I was glancing through the list of fixed bugs in the Apex 3.1.2 release and noticed that one of my long time ‘annoyances’ has been fixed.

Many people have had problems getting their Apex applications indexed by Google and other search engines. One of the reasons for this was that Google (and other search engines) would often index the page using a different session id each time, since Google (and others…ok, let’s just say Google from here on in?) does not ‘understand’ the format of Apex style URL’s and would therefore consider each URL unique.

In short, you could end up with the same page in your application indexed multiple times, with a different session id in each and therefore Google would not treat it as the same page.

The Apex team introduced the idea of Session 0, specifically for the purpose of being able to provide a link without having to specify a valid session id (or rather 0 is considered a valid session id, however when the user requires a ‘real’ session id then one is generated at that point).

So instead of links being indexed like this –

The link can be –

Where the 0 represents the session id, so all the links in Google would reference the same URL.

So, that’s all great isn’t it? Well…almost…unfortunately there was a problem with using Session 0, and it was to do with redirects.

First, let’s look at what happens when a user (or really a browser) requested a page using session 0 in Apex 3.1.1 and earlier (note that in the following code I’ve removed certain identifying things like IP addresses etc).

[jes@MBP ~]$ GET -d -e "http://dbvm/pls/apex/f?p=101:1:0"
Connection: close
Date: Fri, 29 Aug 2008 05:00:26 GMT
Location: f?p=101:1:0
Content-Length: 0
Content-Type: text/html; charset=UTF-8
Client-Date: Fri, 29 Aug 2008 05:00:26 GMT
Client-Response-Num: 1
Client-Warning: Redirect loop detected (max_redirect = 7)
Set-Cookie: WWV_PUBLIC_SESSION_101=1074339690918688

Here I am using the GET command from the libwww-perl toolkit to simulate a browser request for the page. The parameters I use tell the command to only show me the HTTP Response details (the -e parameter) and that I’m not interested in seeing the actual response (the -d parameter).

The key thing here is the ‘Redirect loop detected’ message, this is the GET command telling you that it has found a redirect back to the same URI. The message is a little misleading since it sort of implies an infinite loop (which you’d think would make your browser hang). However if we simulate the same URL request using plain old telnet, you’ll see the real response:

[jes@MBP ~]$ telnet dbvm 80
Connected to
Escape character is '^]'
GET /pls/apex/f?p=101:1:0 HTTP/1.1
<p>HTTP/1.1 302 Found
Date: Fri, 29 Aug 2008 05:00:56 GMT
Location: f?p=101:1:0
Set-Cookie: WWV_PUBLIC_SESSION_101=507304029881630
Content-Type: text/html; charset=UTF-8
Content-Length: 0
Connection: close

The line with “Location: f?p=101:1:0” is the killer line here, as it tells the browser to redirect back to the same page (using a relative link rather than an absolute one), however also notice that a cookie is being set.

So the sequence of events is:

  1. Browser requests a page using session 0.
  2. Server responds with a redirect location and a cookie
  3. Browser requests the redirect location

So, essentially whenever a browser requested a URL using session 0 your webserver would actually be hit at least twice. For a small website this might not be a problem, however for a large site with lots of users who bookmarked a link to the home page with a Session 0 link, or people who used a link from another site etc, this could potentially add a big overhead to the number of requests your webserver had to handle (whilst the redirect response is not a large amount of content to server, it is still nonetheless a web request that needs to be handled).

This was also a potential problem for search engines, since many search engines do not always handle redirects nicely, since they may assume that when they try to access (and index) a page that if you’re sending them somewhere else with a redirect that something is ‘not quite right’. It’s certainly a factor in getting Google to nicely index Apex applications.

So, let’s take a look at how it works after patching to 3.1.2, running the same request for the same session 0 URL we get:

[jes@MBP ~]$ GET -d -e "http://dbvm/pls/apex/f?p=101:1:0"
Connection: close
Date: Fri, 22 Aug 2008 05:02:01 GMT
Content-Length: 13352
Content-Type: text/html; charset=UTF-8
Content-Type: text/html; charset=utf-8
Client-Date: Fri, 29 Aug 2008 05:02:01 GMT
Client-Response-Num: 1
Set-Cookie: WWV_PUBLIC_SESSION_101=8141285575191180

Notice how this time there is no redirect at all, the content is returned directly (note the Content-Length response header) and the cookie is automatically set.

If you’ve never had first hand experience of the problems the previous Session 0 behaviour could cause, then this might not look that interesting, however the fact it is now patched has huge consequences for most Apex applications out there, in two key areas:

  • Your webserver will now not need to handle all those additional redirect requests, meaning the the webserver is freed up to support even more ‘real’ end user requests.
  • Search engines can now more easily index Apex applications, without you having to do a single thing (well besides installing the patch).

In short, by applying this patch you have taken another step forward in making your Apex infrastructure much more scalable and I also expect to start seeing many more Apex applications ranked higher in Google (and other search engines….had to say it, sorry).

I’ll hopefully post some more on the other implications in some of the patches if I get a chance…

Apex 3.1.2 Released

Hot off the press, Application Express version 3.1.2 has just been released.
The link to the direct download is here, if you’re upgrading via the patchset on Metalink then the patch number is 7313609.

You can find more details about the patch here.

There looks like quite a few fixed bugs (it’s always hard to say that without it sounding like a bad thing!) in this release, definitely worth the upgrade!