Thursday, August 17, 2006

The requested URL was not found on this server

I was trying out APEX function "Z", a so-called shorthand version of function HTMLDB_UTIL.COUNT_CLICK, an API tool that enables an APEX developer to easily count clicks that users make to external sites (links that lead the user to different web sites), when i got the following message from the server:

the requested URL /pls/htmldb/.z was not found on this server

At first i was puzzled because i remember that i already got this function running previously, so how could it be that "Z" was no longer there?

After checking all possible views, dropping and re-creating synonyms in all possible manners, invoking it with or without the schema prefix, function Z was still baffling me with its tedious "URL not found" message.

To make it more frustrating, i tried out its "verbose" equivalent HTMLDB_UTIL.COUNT_CLICK and it worked like a charm!

Then, suddenly and unexpectedly, there was a light at the end of the tunnel.
A thought came through my mind and it was telling me: "check out the parameters!"

Even if the very same parameters were working correctly with HTMLDB_UTIL.COUNT_CLICK, a quick review of Z's parameters showed that p_workgroup wasn't existing at all, being replaced by its "equivalent" p_company.

Needless to say, as soon as i renamed the wrong parameter, Z started working too.

Most likely the reason behind the parameter names inconsistency is what is normally called "backward compatibility problem".

There was a time when probably only function Z was existing, a sort of jurassic htmldb.
Then, in a subsequent release or era, a packaged version of the API was provided, but for some reason, the parameter was renamed (or evolved...).
Then, HTMLDB was made available to the public and it was too late to change it.
And now you know what a typical "backward compatibility quirk" looks like.

Happy counting!

1 comment:

Anonymous said...

thank very much for this information
i resolved my probleme by procede with your solution but i modified a user APEX_030200 bacause i use database11g with apex

regard sihem

yes you can!

Two great ways to help us out with a minimal effort. Click on the Google Plus +1 button above or...
We appreciate your support!

latest articles