Seminar: “What’s your choice for Oracle Forms” – recap

A great turnout for the seminar: more than 40 interested attendees, a mix audience of IT managers, project managers and developers.
Hof ter Delft was a nice location!

Grant Ronald, Oracle Senior Group Product Manager for the development tools division, opened the seminar with a keynote presentation.
He started with the Oracle Statement of Direction: Oracle has no plans to desupport Forms and Reports.
After this he gave an high level overview of what is possible with an Oracle Forms application: modernize, upgrade, integrate and migrate.
Grant ended with an overview of ADF.

My session was next, same subject as Grant, but a bit deeper into detail with demos and customer cases.
I showed how you could modernize an application using Pluggable Java Components and JavaBeans.
Upgrade will bring you some nice features, eg. javascript integration and external events in 11g.
Those new features were shown in the integration demo, together with web service calls from Forms.
I ended with migration:  reasons to migrate, strategy(eg. a customer case of  redesign/rebuild in Apex), tools that  can be used(eg. JHeadstart ), …
One lesson: migration is not an easy path…

The following session walked this path of migration, the one of a phased migration.
Wilfred van er Deijl(Commit Consulting)presented OraFormsFaces.
A presentation about where OraFormsFaces can fit in and how it works.
When you choose for a migration and you don’t want a big bang, OraFormsFaces can help you in doing new development in a new technology(eg. Oracle ADF) and keep your Forms investment.
OraFormsFaces let you integrate a form in a webapplication and passes info between those two technologies.

To show that OraFormsFaces works with other technologies, Tom Bauwens(SmartApps) showed the integration of Oracle Forms with Eclipse RCP using OraFormsFaces.

After a nice lunch Grant Ronald gave an introduction training to ADF:

  • Building ADF Business Components
  • Business validation
  • Shaping your data
  • Application Flow
  • Building UI pages

This really showed the power of ADF to Forms developers.

Oracle Service Bus : Agility in Action

Yesterday I followed a session regarding OSB given by Jeff Davis, it was an interesting session with a lot of demo’s regarding using business services and proxy services.

Topics that we’re interesting to me during the session and I would like to share with the community:

  • Coherence ships with OSB/Weblogic which gives you the possiblity to cache service results to speed up performance. As Jeff mentioned a case could be that your users need to get the latest financial results each day which is a long running business process. This process can be launched asynchronously when the user is logged on in the background. The result of the process is then put in the service cache so when the user needs the information it’s shown to him without delay. The Service Result Caching functionality is integrated within OSB 11G, Release 1.
  • OSB 11g, Release 1 is also fully integrated with Enterprise Repository which gives you the possiblity to index all your existing services using your metadata such as XML, XSD, WSDL, … Using Enterprise Repository the impact of changes made to individual services is clear which makes your release management process a lot easier! Make sure to check out the features and functionality delivered by the Enterprise Repository to be able to govern your services throughout the enterprise.
  • OSB12C (C stands for Cloud) is the next upcoming release of OSB which holds a lot of new interesting functionality such as templating/prototyping services, development is integrated within Jdeveloper, … The fact that the development will be integrated within Jdeveloper gives your development team the possibility to use one and only one IDE to have E2E development from database to business components, to services such as bpel, osb, external services, business rules untill the end-user interface

During the demo Jeff showed how you can expose functionality of an EJB 3.0/2.1 module as a service using business services and proxy services. You can transform from an EJB 3.0 business service to an EJB 2.1 Proxy Service using XQuery and the JEJB protocol.

Handling request-response message in ESB Routing Services

Ever wondered how to define routing services based on soap services or database stored procedures where you could define routing rules on the request-and response-message.

Let’s say you want to define the following scenario:
- Call an existing stored procedure that takes as input parameter ‘’ and as output parameter the employee-information (firstname, lastname, address, …)
- Define routing rules on this stored procedure so you can send the response-message, the employee information to a 3-party application when the response-message isn’t empty. In other words, when employee information is found for the given you will send this xml-message to the 3-party application.

This isn’t rocket science right … this should be a piece of cake …

Well let’s start building up the scenario in ESB, using our IDE Jdeveloper:
1) Create a new esb project
2) Create a new esb system
3) Create a DB Adapter calling the stored procedure we’ve defined to extract employee information using the as input parameter
4) Create a routing service based on the DB Adapter

=> We stumble upon the first problem => we’re not able to define a routing rule on the response message, only the request-message (which is the input-parameter can be used in our routing service.

Well let’s try to create an empty routing service and use the xsd’s generated by the db adapter, use the request-parameter as request-message and the response-parameter as response-message.

=> Nope, still not the right path to follow, we still can’t define a routing rule on our response message.

Having a look at OTN doesn’t provide me any answers, using the ESQREQUEST parameter is much to complicated for my basic scenario.

Now let’s have a look at how this could be accomplished in a much more straigth-forward manner:
1) Define DB Adapter (as in the scenario defined above)
2) Define a routing service using the request-parameter of the xsd (don’t fill in the response-message)
3) Define a routing service using the response-parameter of the xsd as the request-parameter of the routing service

In other words :
Define 2 routing services in which you will define the first to handle the request message and the second one to handle the response-message.

4) Link the 1st routing service, handling the request message, to the second routing service and now you can start using your services as needed.

I will provide screenshots for this scenario ASAP.

Tips & Tricks – ODTUG (chapter 2)

Today I had the opportunity to attend loads of interesting sessions as well, the tips & tricks I’ve picked up regarding ADF, SCM, OWB, JDeveloper.

Some of these tips are very obvious, but worth reminding ;o)

Tips & Tricks when building applications (with JDeveloper):

  • Use 1 source control system, preferably Subversion ;o)
  • For Continuous integration you can use maven/ant which is tightly integrated, supported within Jdeveloper
  • Use Unit Testing througout your project phases, you can use our QA-tool for APEX-development and use JUnit, HTTPUnit, … for JEE based web development such as ADF Faces
  • Define a seperate lib-directory to handle the external libraries you’re using within Jdeveloper, so you’re able to version them efficiently and to manage your dependancies
  • Watch out when you’re refactoring BC4J or ADF applications, because configuration files, pageDefinition files aren’t refactored completely

Tips & Tricks on versioning in Jdeveloper 11g:

  • SCM can be any versioning system such as Subversion and CSV (supported by default), clearcase, serena, …
  • You have the possibility to create a repository within Jdeveloper 11g but this is for development purposes only and not well documented either, so no best practice
  • When you check in your project at a certain child-level, say for example the ViewController-project, Jdeveloper will automatically start from the root level (commit the whole working directory) and drill down to only commit those files that have been changed.
  • Version at application level
  • Define files you want to exclude from being versioned
  • The conflict-resolution is xml-aware which is a great future because most of the time you would be changing configuration files that are defined in XML

A term that will pop-up more and more ‘CLOUD Computing’ or ‘CLOUDS’ … another paradigm ;o)

This just means that clouds are up in the sky, floating around and the IT-world these clouds would hold different services made available to the outside world.

The services would be put inside the cloud to open up business, to start integrating … in other words now the sky has definitly become the limit!

Tips & Tricks from ODTUG

The tips & tricks I’ve learned so far at different ODTUG sessions I’ve attended:

When you’re thinking about moving to fusion middleware:

  • Use a small subset of tools, no big bang approach: ADF + BC + BPEL
  • ADF Faces is still evolving, so you need to consider the rewrite that’s needed when using Faces as your UI
  • Use templates to introduce a common look-and-feel by using af:region-tags which will centralize the layout so you don’t need to go through each page when layout changes
  • Use Enterprise Business Objects, EBO’s, as they are being used in AIA, one common business object that will be the facade-layer between your web layer and model layer
  • Use Grid Control to monitor your fusion-based applications
  • Set up datasources and pooling on the Application Server not on Application Tier
  • Prevent SQL-Injection by using bind variables
  • Use black- and white-lists for defining the security-rules and do’s and donts of your application
  • Don’t define nested roles when defining security in ADF Applications, use flat structures because not all JEE Servers support nested roles

More high-level, pragmatic:

  • Concentrate on business drivers, not on technology: on the ‘what’ not the ‘how’
  • Business Services are your hub, not the database anymore

A great paradigm Basheer Khan uses:

When your moving to a new home you will tap into existing services such as electricity, phone, internet, cable-tv, water, … => this is the same approach that you will be using when moving to SOA. You will tap into existing services.

Webcenter Development – SRDemo

When you want to start learning Webcenter, getting a grasp of the technology, the features … have a more practical view, you can download the SRDemo application to get you started.

When you’re going through the installation-guide to set everything up, following tips can help you step-through this installation:
- modify the oc4j.cmd before installing the standalone OC4J in the SRDemo directory and make sure to define the JAVA_HOME, ORACLE_HOME and J2EE-home.
- modifications you need to perform in the adf-config.xml are setting the mds-file location correctly, which is available under your application-folder in OC4J

JDeveloper Tips & Tricks

In the different projects I’ve worked on the past few years, I’ve always worked in an Oracle-Java environment. This means I’ve always used an Oracle Database, mostly JDeveloper as my IDE environment and deploying to an OC4J instance or an Oracle IAS instance.

During these projects different issues arose regarding business requirements we needed to implement using JSF/ADF or deployment-issues when porting a 9i application to 10g environment, …

I’ve tried to keep my own cookbook regarding these different issues we’ve faced and how we resolved them.

In this post you will find different challenges we’ve addressed regarding working in an Oracle-Java environment. Please feel free to comment and add challenges/issues to the list !

You want to open up documents in a new screen, such as pdf-documents or word-documents
Use ‘targetFrame=_blank’ for a goLink to open the link in a new window

Refresh a table-component when a dropdown-component is changed, a filter.
To refresh a table given a pre-defined filter you can use the following components ‘selectOneChoice’ with a table-component and this table-component holds a partial-trigger which listens to the ‘selectOneChoice’-component. This means you will use the partial-page-rendering feature of jsf which only render the table-component on the page and no other components.

Buttons aren’t shown correctly on a linux environment when using a custom skin
ADF Faces generates images on the fly for the different widgets (buttons, tabs, …), in the different languages, if it’s a multi-lingual application. The buttons, f.ex. are not standard HTML buttons, but GIF images. They are created in a cache directory
(\public_html\WEB-INF\temp\adf\images\cache\\) and then reused for the next runs.

The generation of the image may fail, f.ex. because the physical font is not available on your OS.
In the case of a button, it will then be generated as a standard HTML button, instead of an empty image, with no text.

Change font to “Dialog” instead of using “Arial, Helvetica’ because “Dialog” is a special font, a virtual font, that doesn’t depend on any physical font installed on your machine.
If the application runs in a Linux environment, you need to use either a virtual font, f.ex. Lucida, or a font physically installed on your Linux system

Navigation between pages without validation-exceptions being thrown
You want to be able to navigate away from a creation-page but the validation-exceptions are always triggered => use ‘immediate=true’ attribute on the command-link or the menutab-component so validation isn’t fired
You’re getting ‘current rowkey has been modified’-exceptions, set the enableTokenValidation-attribute on the pageDefinition-file to false so rowkey-validation isn’t performed

Delete files from Jdeveloper or exclude files from the Jdeveloper project
If you want to delete files from your project make sure to use the ‘File-menu’ ‘Erase from disk’ instead of the delete icon in your application navigator. If you use this delete-icon this means an exclude-option is added to your project-properties so the files aren’t shown anymore, but they still exist.

Your application does not work as expected
Try stopping OC4J, clean up the workspace (go to run-menu and choose clean-up), rebuild the entire workspace and run again.

When running the page, the browser remains empty
Apply the same steps as for the previous problem: ‘Your application does not work as expected’
Delete the WEB-INF/temp folder from the view-project and test the application again

The JSPX Design Editor looks strange

If you see this in the JSPX Design Editor:

Then JDeveloper does not properly recognize the Faces tag libraries.
You can try to click the refresh button (indicated by the arrows in the screen shot above).

If that does not work:
1. Close all JSPX’s in JDeveloper.
2. Go to the ViewController Project, to the Project Properties, and then to the JSP Tag Libraries category.
3. Remove all JSP Tag Libraries. When asked to remove other Tag libraries, click OK, but when asked to remove Java libraries click Cancel.
4. Close JDeveloper and open it again.
5. Add the tag libraries
o JSF Core
o ADF Faces Components
o ADF Faces HTML
6. Rebuild the ViewController project
7. Open the JSPX again.

Exporting table-date (master or master-detail) to Excel in an ADF-Faces application
Using your ‘FacesCtrlRangeBinding’ the table-component in your pageDefinition-file, you can export the data to an Excel-file. If you have a table that needs to be exported to Excel and when there are columns that you don’t want as a part of the export, create a new table binding in the pagedef with the right columns and use the name of the new table binding as a parameter of the ExportToExcel method in the backing bean of your page.

This could be the case when a calendar object is displayed in the table, typically you will want to use a dateAsString field in the exportToExcel.

You will find the code to support this functionality below; if you have any questions please comment.

You’re getting the following error when trying to connect to an Oracle Database via JDBC:
Error initializing connection: ORA-00604: error occurred at recursive SQL level 1 ORA-12705: invalid or unknown NLS parameter value specified

When you take a look at this URL:
The next topic is very important regarding this issue:
ORA-604/ORA-12705 Error on Some Unsupported Locales in JDBC (4704421)
Make sure you’re not defining a Locale that isn’t supported by JDK 1.5, have a look at the ‘supported locales’ in the JDK 1.5 specs:

Classpath-issues when deploying an application to OC4J or IAS
When you have a look at the OC4J DeveloperGuide (, more specifically at chapter Executing Queries at Runtime Through the ClassLoading MBean (page 53). You will find EM has all the needed functionality to have an in depth view of the class loading of your specific project.

An example mentioned in the developer guide:

Executing Queries at Runtime Through the ClassLoading MBean
Queries can be
executed on a running OC4J instance by calling the executeQuery operation on the
ClassLoading MBean.
This MBean is accessible through the Web-based
Application Server Control Console interface. See the Oracle Containers for J2EE
Configuration and Administration Guide for details on accessing and using the
MBeans packaged with OC4J.
1. Click the Administration link in the
Application Server Control Console.
2. Click System MBean Browser.
Expand the ClassLoading node in the navigation pane, then select the singleton
MBean instance.
4. Click the Operations tab in the right-hand pane, then
click the executeQuery operation.
5. Enter the name of the query you want to
execute as the value for queryClassName. For example, LoaderTree.
6. Click
the queryArguments icon, then add a new row for each argument you want to
specify. Do NOT enclose arguments in parentheses; these are added automatically
when the operation is invoked. Click OK when finished specifying
7. Click the Invoke button to call the operation.

In the chapter ‘Troubleshooting Class-Loading-Related Problems in OC4J’ an explanation is given about the different exceptions that may occur and how to solve them.

Compiler-errors when checked “Use Javac” Compiler option in the Project Properties dialog
This problem has been reported asBUG 6311285 – OJC ALLOWS CASTING OF GENERIC OF IMPL CLASS TO GENERIC OF INTERFACE CLASSA fix is already included with JDeveloper 11.1 Developer PreviewAs a workaround you can use javac instead of ojc for compilation. javac will report such wrong assignments. You need to compile with ojc only if you want to use JDeveloper profiling or code coach.
For more information have a look at the following forum-thread:

Memory Leaks in Jdeveloper:

1)Check the Virtual Memory used by Jdev: edit jdev.conf and increase the JVM memory ( tag AddVMOption).

2)Don’t load technologies you don’t need ( Jdev Preferences – Extension Manager- Extension to Use ).

3)Uncheck the “bells” in Jdev Preferences:Environment: splash scren, silenty reload, decrease undo level;Diagrams: automatically straighten lines

4)Split the project up into different modules: User Management – Reporting – Administering Site – …

No tip but just fun: SOA Facts.

Buzzing about Adobe Flex

I’ve heard a lot of rumours and buzzing around Adobe Flex … so what’s the catch ;o)

For one of my projects I need to get acquanted with Adobe Flex to see what it has to offer and how fast you can learn and implement a real-time application (small test case). I’ve already created a small test case in ADF and now I need to have a look at Adobe Flex .

With my Oracle Fusion Middleware background, ADF for example, I can make a comparison with Flex, how intuitive is the IDE (it’s based on Eclipse), what about J2EE-requirements such as bindings between the different tiers, …

One major drawback of Flex is that it’s again another proprietary code you have to learn, using basic xml tagging but yet another format, another language. If I have a look at ADF it’s much more standardized and if you have a J2EE background it’s comprehensive and you just use the existing knowledge and experience to build on.

But that’s enough talking wright … let’s create a Flex playground =>

First I’ve installed a trial version of flex builder 3 and then I went to search the internet for some sort of a ‘Adobe Flex for dummies’-guide ;o)

I’m using the quickstart guide, which you can find on to get started with Adobe Flex.

The first impressions are … sexy and vivid applications with the same look & feel as flashplayer applications. Let’s try and create one myself:

  1. The first section in the Quickstart-guide : Coding with MXML and ActionScript works very well, and if you want to use the TIP

Tip: To see the intermediary ActionScript files that Flex generates, add the
–keep-generated-actionscript option to your mxmlc command.

Just use this command in the developer-prompt of adobe flex:

C:\adobe_flex\QuickStart>mxmlc –strict=true –keep-generated-actionscript MyFirstExample.mxml

After you’ve done the first chapter you were able to define and compile a flex application using the Adobe Flex 3 SDK Command Prompt.

In the second chapter : Creating your first application , you perform almost the same exercise but now you’ll use the Flex Development Environment which uses the Eclipse IDE. So J2EE Developers which are used to Eclipse should recognize this immediatly, it’s the same IDE you’re working with, only the needed plug-ins for Flex are added/used.

Steps you need to perform to build a ‘hello world’ (sounds familiair) application:

  1. Create a new Flex Project (accept all the defaults)
  2. Copy/paste the code from chapter 2 and choose to run the application
  3. Start playing around yourself

Let’s compare the IDE I’m used to, which is JDeveloper, with Adobe Flex Builder 3 using the sample application from the 2nd chapter.

  1. :( => I can’t re-organise my components in the outline-view which can be compared to the structure-view in JDeveloper. I have to use the design-or source-view in Flex to re-organize the components, let’s say for instance I want to move my components (textarea, panel and label) from the tile into a VDividedBox, I need to do this in the source-or design-view and can’t rearrange using the outline-view.
  2. :( => I don’t have a look-up of the existing functions that are defined in the mx:
    Script tag. To avoid erroneous referring of functions in the CDATA-part you could have a drop-down or look-up of the existing functions in the properties that can use these, e.g. the onclick-event could have such a drop-down. This is usefull code insight when working with the ‘Flex Properties’-panel in the IDE.
  3. :) => The code-insight on each component (each component you’ve defined an ID for, such as myText or myLabel) is very helpfull to have a look at the available methods on these objects.
  4. :) => different ways of specifying eventHandlers which gives each developer the choice between different approaches and if you’re referring to a non-existant label/field/method a compile time error will be shown.
  5. :) => when you’ve messed up the mxml file, meaning the tags aren’t constructed properly anymore for a mx:application, the design-tab won’t work anymore. This is a very handy feature because it will point you to the code that produces the exception. You have the possibility to check what’s wrong with your source code without having to search inside your mx:application for tags that aren’t closed properly etc. In the following screen-shot you can see the behaviour:

That’s it for playground time today, I have to get back to business with JDeveloper but untill now I’m still curious.