Tuesday, April 16, 2013

The problem of strings with more than 4000 chars in different regions

When you create an object (item, process, validation, ...) in APEX with the application builder there are properties like messages, conditions and comments. These properties using a string with more than 4000 characters will encounter an error like that:

Even when you use an item Value like


 and the value of this item is longer than 4000 characters, it will result in runtime in this error:

In my case i had to print out a message for the user which could be longer than the 4000 characters.
One solution for my case was to use jQuery and Dynamic Actions to print out the content of an item.
I created the Dynamic Action on the Global Page (Page 0) with these attributes:
The JavaScript Code is:  $('.uMessageText').append($v('P0_TEST'));
Of course there are other ways like described in my oracle-forum thread, but i hope the next apex versions will solve these problems.

Thursday, March 7, 2013

Gründung der APEX UserGroup Düsseldorf

Um im Raum Düsseldorf allen APEX Interressierten eine Möglichkeit des Austausches zu geben habe ich die APEX UserGroup Düsseldorf ins Leben gerufen. Diese in XING organisierte Gruppe soll unabhängig der Firmenzugehörigkeit jeder Person eine Plattform zum Thema APEX bieten.
Das erste Treffen ist für den 06.05.2013 geplant. Innerhalb dieses Treffens sollen 2-3 Vorträge, im Zeitrahmen von 20Minuten vorgetragen werden. Jeder der einen Vortrag dazu beisteuern will, kann sich gerne an mich wenden.
Das Treffen findet in lockerer Atmosphäre statt und soll neben der Vorträgen den Austausch zwischen der Personen anregen. Bei Fragen zum Treffen oder zur Aufnahme in die XING-Gruppe bitte einfach an mich wenden.

Tuesday, March 5, 2013

Oracle VirtualBox experiences

As an APEX developer it's always interesting to have a small environment on your laptop for demonstrations or tests.
Many people in our company used VMWare as a primary virtual system platform. In nower days oracle has it's own virtual technology named Oracle Virtual Box.
You can find the client tool for using a virtual system on www.virtualbox.org. The last version is from 28th. of february in the version 4.2.8 and has 96MB. When installed it needs about 132MB on your local storage took 10minutes to install. As usual the installation needs admin rights, because a virtual network adapter and some other stuff will be installed.

One big advantage of using virtual box instead of vmware is, that oracle has predifined some images with nearly all current versions of software. You can find the images on http://www.oracle.com/technetwork/community/developer-vm/index.html. If your focus is developing apex applications the first image called "Database App Development VM" would be the right one. The download "Oracle_Developer_Day.ova" is 4.2GB huge and contains the Oracle Enterprise 11gR2 database with APEX 4.2. (even if there stands APEX 4.1 the APEX version in the image is "4.2.0.00.27")

After you have installed the client and downloaded the image it has to be imported into the client. This importing process takes 15-30minutes and extracts 2 files with 12GB out of you 4.2GB download files. These files will be placed per default in "C:\Users\<user>\VirtualBox VMs\Oracle Developer Days". As far as i can see, there is no option where i can change this default extract destination. That could be a problem for people who have a small first partition, only for your os.
After the extraction it's possible to move the files into another directory. Close your client before and move the folder "\Oracle Developer Days" to another directory. After restarting the virtual box client you have to remove the old image and add the new folder. Now you choose the extracted "*.ovf"-file and after that you can use the image.

The two image files are not completly used in the image (7.5/12GB and 4/12GB).
This image uses apex listener 1.1.4 on port 8888 for APEX. So you can start developing apex under http://localhost:8888/apex. Log in under Workspace internal/ user: admin/ password: oracle and configure your own workspace.

If you are interested in using the last version of apex, this blogposting (Ronald van Dijk) can be interesting how to patch to apex 4.2.1.
Further on if you wanna configure your virtual machine, that you can call the apex url from other systems this blogposting (german description how to configure the network) might be interesting.

Conclusion:
Overall it's an easy way to develope apex on a local system, even for people who havn't big knowledge with linux machines.
Keep in mind that installing virtual box beside vmware will cause problems with the different images and the network adopters. So deactivate the other network when using your virtual device.
And as always the command line is configured to american english, so for german developer it might be interesting to adjust that configuration.
As last note: The command "ifconfig" has to be called with /sbin/ifconfi

I hope you will enjoy developing on this machines and let me know if there are any more tricks or interesting points while using virtual box or apex :)

Wednesday, February 13, 2013

Error when updating Static File Comment in APEX 4.2.1

Today i played around with updating static files in APEX. Using apex.oracle.com with version 4.2.1 i got an error when updating a static file comment. I simply uploaded a file and afterwards i tried to change the comment. The comment which was initially submitted was saved, but any change results in:
Error updating file.
ORA-06502: PL/SQL: numeric or value error: invalid LOB locator specified: ORA-22275 ORA-06512: at "SYS.DBMS_LOB", line 884 ORA-06512: at "APEX_040200.WWV_FLOW_HTML_API_PRIVATE", line 144 ORA-06502: PL/SQL: numeric or value error

APEX Expertenseminar in Berlin

Vom 09.04.-10.04.2013 findet in Berlin ein Expertenseminar mit Niels de Bruijn und Mir statt. Inhaltlich ist es für fortgeschrittene bzw. Profis im Bereich APEX Entwicklung. Es beschäftigt sich schwerpunktmäßig mit der aktuellen Version 4.2 und der mobilen Webentwicklung.
Neben den APEX eigenen Werkzeugen werden auch die Integration von Hudson, FOEX für komplexe Dialoge, sowie automatisierte QS-Unterstützung vorgestellt. Das Seminar besteht sowohl aus Workshopkomponenten als auch Vorträgen.
Alles weitere findet man auf den Seiten der DOAG "Berliner Expertenseminar: APEX für Experten mit Niels de Bruijn und Oliver Lemm".

Friday, February 1, 2013

APP_PAGE_ID=0 in OnDemandProcess

In APEX we have many Substitution Strings. One of these is :APP_PAGE_ID. Be careful with this String in an OnDemandProcess. I have called an OnDemandProcess by using JavaScript/AJAX and the result was, that :APP_PAGE_ID was always 0.
To solve this problem i have created an Application Item (AI_APP_PAGE_ID). This item will be filled every time a page is rendered in APEX.

*Update*
Due some good tips the problem can be solved by calling the OnDemandProcess with the correct full syntax from JavaScript.
var ajaxCall = new htmldb_Get(null,$v('pFlowId'),'APPLICATION_PROCESS=IS_HANDLE_VALID', $v('pFlowStepId'));
With this call especially the last parameter $v('pFlowStepId') the pageId will be the actual ApexPageId where the Javascript is used.
Thanks to Peter and Roel for your tips.

Monday, January 7, 2013

Highlighting in full-text search works case sensitiv


If you search for something in APEX you can use in version 4.x or later the full-text search.
It's a great feature, but the the word is only highlighted, if you write it completly the same way, even if you don't check "case sensitive".

Keep in mind that the result always finds all the correct words and only misses the red highlighted string.
Result when searching for P1600_AEU_WHRG_KEY
Result when searching for P1600_aeu_whrg_key