New Apex Blog

Denes Kubicek | Sep 3, 2010 06:24 +0000
My colleague and friend Linh Dinh from Munich recently started to post about his experience with APEX. You can find his blog here http://www.dinh.de. Linh is a knowledgable and smart person with a lot of Java background. His first contact with APEX was in March this year when we started with a project for one of my customers. He immediately liked it and has made a huge progress since. Linh is blogging in German and therefore his postings are especially interesting for the German APEX community.




Apex Post Calculation Computations

A warning - perhaps my musings are different as I wrote this sitting in Melbourne airport, my mind exhausted after a few days of conducting training with not much sleep in the hotel bed.

Once upon a time I was a regular Oracle Forms programmer (and sometimes still current). These days I spend most of my time with Application Express. This makes me happy as I did enjoy mod_plsql - an ancestor (of sorts) of Apex.

Occasionally I notice some parallels between the two, even more occasionally I get around to writing an entry for the world to see - a strange urge for some but it seems that people read even more mundane topics.

There are many attributes available within the Apex environment. By attributes I mean little boxes in the various wizards ready for my to type something in. Sometimes it seems overwhelming. Then I remind myself how flooded with settings the Forms environment must seem. Of course I snap myself back to normal when I think about what I've seen of JDeveloper.

Have you ever wondered what some of these settings do?

Recently I was creating a copy of a data entry form within Apex so I could present a cut-down / read-only version of the page. There were some fields that instead of being Select Lists, I needed to display their descriptive value - not the return value that is stored in the column.

There are a number of solutions to this problem, as with most problems. One solution I came to involved utilising the "Post Calculation Computation" attribute of the item. This means that after I source the item from the database column, I can transform it's value into something else. The obvious solution here would be to pass the value to a function that determines the descriptive form of the value - from some sort of reference code table.
my_pkg.get_label(:P1_VALUE)

I mentioned forms programming before, right? Immediately I thought of post-query triggers and the pros and cons behind various coding techniques in these triggers. First and foremost was the very same practice of taking a value and converting it to a description. This was an expensive task as not only did it require an extra hit on the database, you needed another round trip from Forms runtime to the application server. The better solution was to incorporate the request within the query - perhaps via a key-preserved view.

The same rings true within Application express. Sure, we don't have another round trip between servers since all the action is happening on the database; however it still requires another select statement to be executed. For a dinky (a Aussie/British colloquialism meaning small and insignificant) little Apex page, what's an extra hit on the ever powerful Oracle database? Perhaps try see what happens when scaling your request to thousands of users.

So perhaps some of our old habits can carry on to this modern day programming tool? I'm certainly not saying this post calculation attribute is not useful. I have another field populated via a list manager with a popup lov. This means the values are separated by a colon. In my application, this field holds a list of e-mail addresses. When I want to present this list to the user in a pretty format, I can use this attribute to convert it to something suitable for a HTML page:
REPLACE(:P1_EMAIL_LIST, ':', '<br>')

Of course if you wish to do this, you may need to ensure your item type does not convert special characters.

It seems my plane is about to call for boarding, so I'll save you all from further ramblings... for now. Enjoy your weekend.

Going to Oracle OpenWorld 2010?

Joel R. Kallman | Sep 2, 2010 12:55 +0000
Are you going to Oracle OpenWorld 2010, which starts on September 19, 2010? If so, be sure to attend the "APEX Meetup" on Tuesday night. Dimitri has more information on his blog.

Automatic Time Zone support in Application Express 4.0

Joel R. Kallman | Sep 2, 2010 12:49 +0000
A feature of Application Express 4.0 which hasn't received a lot of press but is useful for those building applications that span time zones is the Automatic Time Zone application attribute.

The Oracle database has this wonderfully rich data type called TIMESTAMP WITH LOCAL TIME ZONE. The elegance of this data type is that the value stored in this column will be displayed in the user's current database session time zone. Having written a PL/SQL package to do time zone conversion, it is a non-trival exercise to develop this type of functionality let alone maintain it. Wouldn't it be great if we could put this burden of maintaining constantly evolving time zone rules and daylight saving time dates on the database? Well, you get this for free with TIMESTAMP WITH LOCAL TIME ZONE.

So if all we need to do is set the database session time zone, then:

  1. How do we elegantly derive this for each end user of our application?
  2. How do we ensure that every page view and page submission in Application Express has its database session time zone set correctly for a particular user?

There were numerous suggestions in the past, of storing a user's preferred time zone as a preference and then authoring a PL/SQL block in the VPD attribute of an application like:


execute immediate 'alter session set time_zone =''' || :MY_USER_TIMEZONE || '''';

Not exactly obvious. And this still doesn't answer question #1 of how do we elegantly derive this. This is where the new Automatic Time Zone attribute is useful.

In the Application Builder, if you edit the Application Properties and navigate to the Globalization subtab, you should see something like:




By default, Automatic Time Zone will be set to 'No'. When set to 'Yes', this will now change the behavior of your application:

  1. At the beginning of an Application Express session (which happens at the beginning each time a user runs your application ), the time zone offset will be calculated from their Web browser client.
  2. This time zone offset information will be sent to Application Express and recorded in the APEX session information for that user.
  3. Then, each and every page view for the duration of their APEX session, the Application Express engine will read this value and set the database session time zone to this value.

All you have to do is employ data types which are time zone aware (like TIMESTAMP WITH LOCAL TIME ZONE; DATE is not time zone aware) and check a box in your application definition. It couldn't be simpler!

To demonstrate this, I created a simple application using the following DDL:


create table tz_log(
id number primary key,
username varchar2(255) not null,
tz varchar2(512) not null,
created_ts timestamp not null );

create or replace trigger tz_log_trg1
before insert on tz_log
for each row
begin
if :new.id is null then
:new.id := to_number(sys_guid(),'XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX');
end if;
--
:new.created_ts := localtimestamp;
end;

Then, I just built an application with a SQL report on this table and added an on New Instance PL/SQL Process of:

insert into tz_log (username, tz) values(:APP_USER, apex_util.get_session_time_zone );
commit;


You can run this sample application here. Just keep in mind - it will require you to authenticate with your oracle.com credentials (the same credentials you use if you login to the OTN discussion forum) and it will record your visit in a log table, which others can view. Here's what it looks like - nothing fancy:





If you pay close attention, immediately after authentication, you'll see a URL like:

https://apex.oracle.com/pls/otn/f?p=27207:1:127976719236631&tz=-4:00

Obviously, your APEX session identifier and time zone value will be different than what I show above. But you'll see that there is a new parameter 'tz' to the 'f' procedure. And it is through this interface that you can create a URL to an APEX application and explicitly set the APEX session time zone to a different value. After you login, change the time zone value in the URL to something else (e.g., tz=0:00) and watch the values in the "Inserted into the Log Table (in your local time zone)" report column automatically adjust to that time zone. The underlying report definition didn't change - we're still simply selecting the TIMESTAMP WITH LOCAL TIME ZONE column out of the database, just now the database is automatically converting that value to display in the current session time zone.

You can also programmatically set and get the APEX session time zone setting using two new APIs in Application Express 4.0, namely APEX_UTIL.SET_SESSION_TIME_ZONE and APEX_UTIL.GET_SESSION_TIME_ZONE.

APEX Meetup @ OOW 2010

Dimitri Gielis | Sep 2, 2010 11:53 +0000
It's an annual tradition, so also this year we'll organize an APEX Meetup at the 4th Street Bar & Deli on the Tuesday (7.30 PM) during Oracle Open World.

Here you find some pictures of last year. As you can see, it's always fun with nice people, drinks and food.

Every year we get more people during the meetup, so we started to get sponsors to help to pay for the bills ;-)

Thanks so much to our sponsors of this year:
- Oracle Technology Network (OTN)
- Oracle Development Tools User Group (ODTUG)
- APEX Development Team

If you or your company wants to sponsor aswell, feel free to send me a mail or add a comment to this post. The current total to spend is $500 :-)

See you soon!

Silbentrennung (Hyphenation) in APEX (GER)

Tobias Arnhold | Sep 1, 2010 15:10 +0000
Viele Entwickler in APEX kennen das Problem professionelle gut strukturierte Reports zu entwickeln, deren Spaltenbreiten nicht über die gewünschten maximalen Breiten hinausragen.
Folgende Bedingungen erschweren die einfache Entwicklung von Reports:
- Bildschirmauflösung ist eingeschränkt (1024x768)
- Zu lange Texte in Reports (Spaltennamen, Spaltenwerte)
- Nutzung verschiedener Browser (Firefox, Internet Explorer 6, 7 und 8,Safari,...)
- Übersetzung in verschiedene Sprachen notwendig
- Nutzung unterschiedlicher Layouts mit verschiedenen CSS Eigenschaften

Vor einer Weile habe ich einen Tipp beschrieben der die Problematik ein wenig verbessern kann: Automatic linebreak if word breaks out of table element

Nun habe ich eine wirklich gut Lösung gefunden die mit ein paar einfachen Anpassungen erstaunliche Wirkungen in ihren APEX Reports hervorrufen kann. Das Zauberwort heißt Silbentrennung (Engl.: Hyphenation). Die Lösung besteht darin den dargestellten Text durch ein Javascript Plugin entsprechend der maximalen Feldbreite zu begrenzen.

Dazu wird nach jeder Aktualisierung eine Funktion gestartet, die die Felder entsprechend anpasst.
Die Anwendung heißt Hyphenator, kann in allen gängigen Sprachen dynamisch verwendet werden, ist ein Javascript Plugin und ist hier zu finden http://code.google.com/p/hyphenator/

Ein weiterer Entwickler hat ein passendes Jquery Plugin geschrieben: http://bitbucket.org/webvariants/jquery-hyphenator/wiki/Home

In dieser Kombination ist die Verwendung in APEX 3.2 oder 4.0 denkbar einfach.

Anleitung:
1. Datei downloaden
Downloaden Sie die aktuell stabile Version von hier http://hyphenator.googlecode.com/files/Hyphenator%202.5.0.zip und hier http://bitbucket.org/webvariants/jquery-hyphenator/get/v1.1.0.zip

2. Kopieren Sie das Jquery Plugin auf ihren Webspace (APEX /i/ Verzeichnis)
  /i/Hyphenator/Hyphenator.js (Umbennen von hyphenator.min.js)
  /i/Hyphenator/jquery.hyphenator.min.js">
3. Kopieren Sie den Ordner patterns aus dem Hyphenator Download in ihr Verz.
  /i/Hyphenator/patterns/de.js

4. Definieren des Plugins in ihrem APEX HTML Header

<!-- START: Hyphenator Plugin -->
<style type="text/css">
.hyph {
/* WIDTH Parameter wird erst ueber Spalte definiert */
display:block;
/* DISPLAY:BLOCK ist immer zwingend erforderlich */
overflow:hidden; float:left;
/* Schneidet alles Sichtbare über der max. Groesse ab, dadurch entstehen keine Fehler beim verkleinern, IE6 Fehlverhalten */
white-space:normal;
/* Darf niemals: white-space:nowrap als Einstellung in einer Tabelle haben */
word-wrap: break-word;z-index:999;
/* Fuer IE6 */
}
</style>
<script type="text/javascript" src="/i/Hyphenator/Hyphenator.js"></script>
<script type="text/javascript" src="/i/Hyphenator/jquery.hyphenator.min.js"></script>
<!-- ENDE: Hyphenator Plugin -->

5. Deaktivieren Sie in ihrem APEX Report Template folgenden CSS Einstellung
  white-space:nowrap mit white-space:normal;

<!-- Column Heading Template -->
<th ... style="white-space:normal;z-index:999;word-wrap: break-word;">#COLUMN_HEADER#</th>

<!-- Column Template 1 -->
<td ... style="white-space:normal;z-index:999;word-wrap: break-word;">#COLUMN_VALUE#</td>

6. Report Spalten Anpassen

<!-- Column Heading: -->
<span class="hyph" style="width:50px;text-decoration: underline;">Anwendungsname</span>

<!-- HTML Expression -->
<span class="hyph" style="width:50px;">#NAME#</span>

Info: Hier definieren Sie die maximale Breite und die Option Hyphenation zu verwenden.

7. APEX Dynamic Action für Report anlegen

After Report Refresh Trigger mit javascript Ausführung: $('.hyph').hyphenate();
Im Idealfall sollte sollte ein ähnlicher Report wie in meiner Beispielanwendung herauskommen:
http://ta-it-consulting.de/hyphenation.html

Info 1: Die LANG Option im HTML Tag definiert die Übersetzungssprache <html lang="de">
Info 2: Das Plugin kann auch in APEX 3.2 verwendet werden, außerdem ist der IE6 ohne Probleme verwendbar.

Das Ergebnis ist eine universelle Lösung die all ihre Reportprobleme lösen könnte.

Der einzige Haken ist eine erhöhte CPU Auslastung auf der Clientebene. Also Vorsicht vor verschwenderischer Übersetzung.

Mal was anderes: Inzwischen ist auch der AAW-DBMON ONLINE: http://ta-it-consulting.de/dbmon.html

APEX 4.0 New Feature Training in Deutschland

Tobias Arnhold | Sep 1, 2010 15:10 +0000
Falls ihr es noch nicht gehört habt, im Oktober 2010 geben Denes und Dietmar einen Oracle APEX 4.0 New Feature Kurs. Für alle die mehr Erfahren wollen, schaut doch einfach mal rein: OPAL-Consulting - Oracle APEX 4.0: New Features

Die nächsten Tutorials warten bereits…

Tobias Arnhold | Sep 1, 2010 15:09 +0000
In den nächsten Wochen und Monaten habe ich vor ein paar wirklich nützliche APEX Erweiterungen vorzustellen. In Form von Anleitungen und Beispielapplikationen soll jeder in die Lage versetzt werden, professionelle Anwendungen mit den neuesten Techniken zu entwickeln.

Die folgenden Themen stehen derzeit auf meiner Agenda:
- Tooltip Applikation: Viele Tooltip/Infobox Beispiele für APEX gibt es im Netz, nur keiner hat einen wirklichen Überblick darüber. Diese Applikation soll Abhilfe schaffen. Ein alter Post zeigt ein paar Möglichkeiten auf: All about Tooltips
- jExpand Report: Eine geniale Reportlösung mit der es möglich ist, Reports mit vielen Spalten auch auf kleinen Raum unter zu bekommen! Eine Implementierung als APEX Template wird das Ziel sein. Beispiel mit Testdaten
- JQuery Layouts: Ähnlich ExtJS ist es möglich bewegliche Seitenbereiche auch mit JQuery umzusetzen. Ein Ansatz der bisher kaum Gehör bei den APEX Entwicklern fand und endlich auch mit OpenSource Mitteln umgesetzt werden kann. http://fabrizioballiano.net/jquery-border-layout/ und http://layout.jquery-dev.net/ Bis dahin schaut doch mal in meine ExtJS Lösung rein: APEX-AT-WORK Developer Competition 2009 Edition

Ich denke das sind Themen die viele APEX Entwickler interessieren könnten. Deswegen gebt doch einfach mal ein kurzes Feedback zu meinen Ideen.

Anonymous Pro

Scott | Aug 31, 2010 06:31 +0000

Anonymous Pro is a fixed-width font developed specifically for developers by Mark Simonson. Best of all - it's free under the Open Font License.

From it's home page:  "Characters that could be mistaken for one another (O, 0, I, l, 1, etc.) have distinct shapes to make them easier to tell apart in the context of source code."

I installed it on my Mac and set SQL Developer's default font to it, and the text is a little crisper than Courier, my previous default.

Anyone else have a favorite "coding" font?

APEX Meetup @ OOW 2010

Just like last year and the year before that, there will be a (semi) official APEX Meetup during Oracle Open World 2010! And as the APEX Developers - just like every other human being - hang on to a good tradition, even the venue, the day and the time will be exactly the same as in previous years.

So write in your agenda / add to your schedule:

What : APEX Meetup
When : Tuesday September 21, 7.30 PM - ???
Where : Fourth Street Bar & Deli (very close to Moscone)

Another not-to-miss event...hope to see you all there!

Formatted Text with Dynamic Actions

Håvard Kristiansen | Aug 26, 2010 07:14 +0000
This is a quick note on how to use Dynamic Actions in Oracle APEX 4.0 to display unstructured and formatted text from the database based on user selection. This was a bit more cumbersome in the previous versions of APEX.
Image by Jesper Rønn-Jensen under Creative Commons License.

If you have ever let the users get at the Rich Text Editor items (HTML Editor in the previous versions), then you probably have som text with HTML-markup stored in the database. Below is a description on how to get and display the text based on browser events. The example below will display a description of a department when the user clicks department name in a SQL Report (quite stupid really, but serves the purpose).

Demo Application
I have updated my demo application with the example, see it in action here:http://apex.oracle.com/pls/apex/f?p=45420:5. Download the application here: http://apex.oracle.com/pls/apex/f?p=45410:DOWNLOAD.

Prepare the Report
Create a region of type SQL Report based on table DEPT:
select deptno, dname from dept
Modify the DNAME-column in the report:
  • Set Link Text to #DNAME#
  • Set Link Attributes to id="departmentName#DEPTNO#" (this will uniquely identify each anchor element, and give the ability of extracting DEPTNO from the department name)
  • Set Target to URL
  • Set URL to # (this really does nothing)

Add an item to the report region, this will eventually hold the DEPTNO of the chosen department from the report.
  • Right click the department report region and choose Create Page Item
  • Select Hidden
  • Give the item a name (P5_DEPTNO)
  • Leave the rest default (you might want to reconsider Source Used, if you set it to "Always, replacing any existing value in session state", and leaves Source Value blank, you ensure the item starts with no value when the page is displayed).

Create Region to Display Text
For the sake of simplicity, the text will be displayed in it's own HTML Region

Right click Regions and choose Create
  • Choose HTML
  • Choose HTML again
  • Give it a descriptive title: Department Description
  • Create a div to display the text, set Region Source to:
  • <div id="departmentDescription"></div>


Create the Dynamic Action
The first we need to do, is to create a Dynamic Action to get the DEPTNO from the chosen department name, and stuff it into P5_DEPTNO.

Right click Dynamic Actions and choose Create
Choose Advanced
Give it a name (onclick - Department Name)
Set the values as seen below, this means the Dynamic Action will fire when anchors with id's starting with departmentName is clicked

Set Action to Set Value, uncheck Fire on Page Load (we only want it to fire when clicked), set the Set Type to Javascript, and Javascript Expression to
this.triggeringElement.id.replace('departmentName','');

This will extract the DEPTNO from the id of the element clicked (by replacing departmentName with nothing).

Set Selection Type to Item(s), and transfer P5_DEPTNO to the right hand side

The final result should look something like this:



The next step is to get and display the desired text from the database. In order to do this we must create a new True Action to the same Dynamic Action.
  • Right click the Dynamic Action and choose Edit
  • Click Add True Action
  • Set Action: SetValue
  • Uncheck Fire on Page Load
  • Set Set Type: PL/SQL Function Body
  • Set PL/SQL Function Body to code below:
declare
   l_ret varchar2(32000);
begin
   for r in (select dep.*
               from dept dep
              where dep.deptno = :p5_deptno)
   loop
      l_ret := 'HTML formatted return value for <b>'|| r.dname ||'</b> located in <i>'|| upper(r.loc) ||'</i>.';
   end loop;
   return l_ret;
end;
  • Set Page Items to Submit: P5_DEPTNO
  • Set Escape Special Characters: No
  • Set Selection Type: jQuery Selector
  • Set jQuery Selector: div[id=departmentDescription]


Finally edit the Dynamic Action, and set Event Scope: live. This is to ensure the onclick event is attached to Department Name even after PPR refresh of the report.


A Word of Caution
Even though APEX takes care of escaping/encoding your HTML according to JSON specification, this will bloat your return message. There seems to be the standard PL/SQL 32k limit to the JSON-message (Large texts resulting in ORA-06502).

Take care what you return in your message, switching off escape special characters leaves it pretty much wide open to anything. HTML in JSON is a debated issue.

In short: Keep it small and neat :-)

Follow-up on comparing two Oracle schemas

Dimitri Gielis | Aug 25, 2010 13:58 +0000
Over 4 years ago I wrote a blog post about software that helps you to compare two Oracle schemas. That post is accessed a lot and I still get questions about it, so I decided to write a follow up on that post as things change over time.

Comparing two Oracle schemas is still something I have to do regularly, e.g. if I want to compare a development, test and production instance after a deployment of an application.

Alongside Oracle Application Express (APEX), I use Oracle SQL Developer daily. They have a built-in Database Diff tool which works, but I tend to use other tools as well, as it’s hard with SQL Developer to see exactly what has changed. We built our own tool in APEX that compares schemas based on dbms_metadata, which we use when we have access only through the APEX interface. But when I can run things from my own system, I like to use Schema Compare for Oracle.

The people of Red Gate wrote a nice post on how to use their software, with screenshots and steps you can follow, so I won't repeat that. Instead I’m going to compare it against the Diff Tool built into SQL Developer.

Simplicity

The older I get, the more I can appreciate user-friendly software. That is something I try to do in the software I write myself, follow the KISS principle = keep it simple stupid.

For me software has to look good, ’be easy to use and do what it’s intended to do in an efficient way. If I want to compare two schemas I just want to follow a couple of steps:
1. Select my source and target database
2. Select the schema(s) I want to compare
3. Optional - select what exactly it should compare (tables, packages etc.)
4. Get an overview of the results
5. Produce synchronization scripts

Schema Compare for Oracle (SCfO)

Here’s how it works in Schema Compare for Oracle.

When you open Schema Compare you have to create or open a project.


It asks you for the source and target database you want to connect to and which schema you want to compare. An advantage in SCfO is that you can compare multiple schemas at once.
Another thing I found interesting was the option to compare against a Snapshot. You basically take a “picture” of your schema at a certain moment in time and compare against that. Very handy when you can’t access both schemas from the same location. Or if you develop applications and want to generate upgrade scripts, I see the use of snapshots too.

But let’s get further with the normal schema compare.

In SCfO you don’t select the objects first, you just hit the Compare Now button and SCfO starts to compare the whole schema directly. At first I thought, I don’t really want you to do that as you are doing a lot of work for nothing, but the more I used the tool, the more I appreciated it. To start a comparison is very easy and quick...

One thing I found handy as well is the Options tab, which allows you to define if the tool needs to ignore white spaces, storage clauses etc.


When we are happy with the options, we click the Compare Now button and we get a screen with the progress.


Once it’s finished you have a complete overview of the differences in both schemas.


I like this screen a lot as it has many more functionalities than you would first imagine. The filter (find box) is very handy to find some specific objects quickly. You can also sort by different things and just from the way it looks it is so easy to understand what is different in which schema and database! But the nicest thing is when you click on a row where there are differences. It shows you both versions and highlights the differences. No need for an extra tool or text editor to get that information out. It’s just there.


If you want to create an upgrade script or make both schemas equal you just have to use the Synchronization Wizard...

The wizard asks you what it has to do and generates a script for you or automatically synchronizes both schemas based on the objects you selected.


I think Schema Compare for Oracle does it really well. So let’s compare it to the comparison tools that come with Oracle SQL Developer.

Oracle SQL Developer

In SQL Developer you go to Tools - Database Diff.

The first time it will tell you it’s using Oracle Change Management, a payable option of the Oracle database, and you have to acknowledge you have a proper license to use that.


Next, it will pop up with a screen that allows you to select a source and destination connection and immediately asks you what objects you want to compare.


Clicking on Next shows you a screen where you can select the individual objects.
You can view all objects at once, or change the select-list to only see tables, sequences and select the objects that way. This might be a good thing to do if you have many objects!


Once you click Finish it will compare the objects and present you the result in a Diff Report.


You can click on the green SQL button and it will generate the script for you based on the differences you selected.

So it’s rather straightforward to compare two Oracle schemas in SQL Developer, but there are some things I would prefer a bit different.

This is my wish list:
1. Not be forced to have the Change Management license for your Oracle database. The price depends your Oracle Database license, but it can be high if you just want to compare two schemas through SQL Developer.
2. Be able to compare multiple schemas at the same time.
3. Get a cleaner Diff Report, which allows me to add filters to it and allows me to see what exactly is different between the two versions. At the moment I just see a count there, when I click on the row. I get the script to generate that version, but I couldn’t find a way to see exactly the source and target and compare them side-by-side.

Point 3 is my biggest issue and that is why I searched for something else that made my life easier and finally came across Schema Compare for Oracle. Although Red Gate created a Windows only version of Schema Compare for Oracle, so as a Mac user I need to run it through a VM, I find it worthwhile to do it. The interface of SCfO is very clean, it’s easy to use and it gives me most features I’m searching for. There is even a SQL Developer plugin for SCfO (search for Schema Compare for Oracle in the SQL Developer Plugin repository).

So is Schema Compare perfect and is it better in every aspect than the Diff Tool in SQL Developer? Almost, but not completely. SQL Developer supports the comparison of Materialized Views (and their logs) and Database links, which SCfO doesn’t do in the release I tested (1.3).The version of SQL Developer I used was 2.1. I’m not sure the Diff Tool in SQL Developer 3 (which will be released in a few weeks/months) will be different...

Happy comparison!

Standard Screen Design Patterns

Scott | Aug 25, 2010 05:48 +0000
Very cool article, outlining some common & simple screen design patterns - for both web and desktop applications.  Be sure to check out the 2010 Update as well.

I always tell students in our training classes that they should not try to re-invent the design patterns used in most applications - especially since they are database developers and not graphic designers.  Users have come to expect specific things to be in specific places - login/logout in the upper left/right, a site map of sorts at the bottom of each page, tabs for navigation, etc.  Deviating from that expectation will likely create more confusion than anything else, and should be avoided at all costs.

OPP 2010

On October 27th and 28th the combined OPP (Oracle PL/SQL Programming) and APEXposed conference is coming to Europe. To Brussels to be exact. I have had the privilege to attend these conferences since the first one in 2005. The nice thing about this conference is that it is the only conference (at least that I know of) that is totally focused on PL/SQL. Three tracks with all kinds of ideas of what you can do in PL/SQL. From using collections (been around since Oracle 7) to Edition Based Redefinition (Oracle 11Gr2).
If there is a slot in the agenda that has nothing you like, you are welcome to switch to the APEXposed conference to see if there is something you like.
I know I am a big fan of PL/SQL since it has nothing to do with building a front-end but more with getting the job done, using as less resources as possible and applying the best techniques available in the version I am working with.
I am not much of a visual developer. But using APEX, even I can make nice applications that are easy to build and even look nice.
Shameless plug: I will also be doing a presentation on my favorite tool PL/SQL Developer. If you attend the conference, I hope you will come and see this.

OOW Advice

Scott | Aug 24, 2010 15:31 +0000

Jeff Smith offers up some excellent advice for those traveling to OOW 2010.

As a more-than-I-can-count-time attendee of OOW, here's a few additions to his list:

  • Don't eat dinner anywhere near Moscone.  
    Sure, it's easy, especially after a long day or sessions, but most of San Francisco's best restaurants are not adjacent to Moscone.  Head to North Beach or the Marina instead.
  • Attend a session or sessions on something that you have never heard of.
    You don't know what you don't know...
  • Talk to strangers.
    As Jeff said, this is one of the best places to network.  If you don't talk, then you may as well catch the sessions online.  No where else will there be as many people with similar technical interests than OOW.
  • Don't jaywalk.  Seriously.
    The SFPD was giving out jaywalking tickets around Moscone the last couple of years, and I know a couple people who were "lucky" enough to get them.  Not fun.
  • Come early or leave late.  
    Take a day to explore not just San Francisco, but the surrounding area.  Often, airlines will give you a better rate if you have a Saturday night stay included in your ticket.  See if your company travel policy allows for reimbursing your hotel Saturday night if you can get a fare that makes the overall cost of the trip less.
  • Download TripAdvisor or Yelp to your smartphone.
    Either of these sites offer decent opinions of local restaurants and the like, and it's handy to have when you get a recommendation from a concierge.
  • Visit the Union Square Hyatt's Grandviews Lounge
    For a drink, dinner of only for the view.  Try to get there around sunset - you won't be disappointed!

Less is More

Scott | Aug 24, 2010 06:39 +0000

Spent a few minutes yesterday building my schedule for OOW.  Lots of sessions, and unfortunately, some of the good ones are already booked.  That didn't matter, as there were plenty more to choose from.

There's not a whole lot of APEX sessions this year - or at least ones that I have not already seen.  Thus, I'm going to focus more on other database technologies, such as security & performance.  Lots of sessions under that category.

My only gripe is that the Schedule Builder UI needs a major overhaul.  First off, you need a 30" monitor just to view all of the content on one screen - especially when you have the Advanced Search option enabled.   Also, I kept getting a "Search Timeout" error when I tried to search for sessions.  The only way to resolve this is to log out and log back in again.  Such basic functionality for a database conference should NEVER break, at least in my opinion...

The Schedule Builder also tries to use a lot of Ajax-type controls; lots of popup boxes and asynchronous stuff going on.  Maybe it works better in IE, but in Safari, it's a bit clunky.

This is part of the danger of using jQuery or similar Ajax-based technologies - without thorough testing on multiple browsers, the user experience may vary greatly.  This can often be mitigated when building applications that are used internally, as most organizations can lock down which browsers are allowed.  However, this is obviously not the case on the public Internet.

While the Advanced Search is more sophisticated and allows you to search by day, for instance, there is no Google-like interface to search all fields for a specific string.  There are two text fields - Speaker/Company & Free Text - that each search different parts of the content.  But if you're searching for a string, the system will AND these two fields together, producing a different set of results than you may expect.

It seems like too much attention was paid to adding features vs. thinking of a logical design for this site.  Some common things - such as the aforementioned Google-like search, a weekly view of the agenda, and a map of where each session takes place - all seem to be left out.

Hopefully this tool will be enhanced for future events and be made simpler and better at the same time.

Oracle’s Broken Links

It seems that like me, people like Tim Hall are finding some of the changes regarding the amalgamation of sites within Oracle a little frustrating.

I've noticed many of the comments within OTN contain links to pages that just aren't there any more.

This OTN entry here mentions a vital link to
http://www.oracle.com/technology/products/database/application_express/howtos/how_to_create_custom_popups.html
which unfortunately redirects to the Oracle Apex overview page
http://www.oracle.com/technetwork/developer-tools/apex/overview/index.html

In an effort to find the contents of this page, I used my friend Google. I took a key part of the URL and used a special search facility that Google has:
inurl:how_to_create_custom_popups

This gave me three results

  1. The original document, which still redirects to the overview page. However, if you click the cached link next the described URL, you can open Google's cached version of the page - which should usually suffice.
  2. Some Xmarks widget, which didn't help me - but I do recommend Xmarks, by the way.
  3. A Japanese hosted version of this page. Google offered to translate it for me, which worked very well. This also solved my problem.

So until Oracle gets up to speed with all the older links, perhaps give the inurl: search option a go.

ScottWE

ps - congrats to Tim for his recent induction into the OakTable Network.

Pelotonia10

Joel R. Kallman | Aug 23, 2010 04:08 +0000

Sorry, this is not a post about anything Oracle-related. But as our dear, departed friend Carl used to say - it's my blog.

I had the privilege of participating in this year's Pelotonia bike tour. What is Pelotonia, you may ask? "Pelotonia is a grassroots bike tour with one goal: to end cancer. Pelotonia raises money for innovative and life saving cancer research at The Ohio State University Comprehensive Cancer Center - James Cancer Hospital and Solove Research Institute."

This event had special significance for me, as our next-door neighbor, Jacob Carlino, was diagnosed with a rare form of cancer earlier this year and is undergoing treatment now. Jacob is 12 years old. A child like Jacob or any person, for that matter, shouldn't have to suffer through this horrible disease. Jacob's father Dave organized a team in support of his son Jacob, and I had the privilege of being on this team. Above is the team - Dan, Matt, Scott, me and Dave. On the front of our shirts is a picture of Jacob who we were honoring with our team's tour.

Pelotonia was a most-impressive and well-organized event. There were over 4,000 riders and thousands of volunteers in addition to a great deal of corporate sponsorship. The estimate is that this one event will raise over $8 million, with 100% of this money going directly to fund cancer research at the Ohio State University Cancer Care Center and Solove Research Institute. The honorary chair of this year's Pelotonia tour was Ohio State football legend Chris Spielman, who he himself lost his wife to cancer just 9 short months ago.

My goal for this blog post? To simply raise awareness of this disease, and to also let the world know that there is an ever-growing army of people right here in Ohio who is contributing in ways small and large to the eradication of this disease. Lastly, I would like to recognize and thank the sponsors of me for this ride - I am grateful for your generous support: Sue, Sergio & Priscila, Jason & Shelley, Eric, Bob & Marge, Matt & Gretchen, Tim & Susie, Anton & Chris, Kathy & Terry, Neil & Margaret, Tom, Nada & Matt, Frank, Harry, and Mike & Anita.

New Patch available for ApEx 4.0

ApEx 4.0.1 is available for download, if you are running ApEx 4.0 then I suggest you upgrade as soon as possible.

- If you are already running ApEx 4.0 then download the patch from Oracle support, look for patch nr 9976149.
- If you are still running and older version then 4.0 then download ApEx from apex.oracle.com.

The new version nr of APEX is 4.0.1.00.03.


Oracle Technology Network Developer Day – Boston August 19th, 2010

Mike Hichwa | Aug 18, 2010 11:04 +0000
I will be in Boston on August 19th giving the database keynote for the OTN developer day at the Weston Copley Place hotel. The morning features a database 11g presentation targeted at database developers, then an overview of database development tools including SQL Developer, Oracle Application Express (APEX), Oracle Developer Tools for Visual Studio .NET, PHP and Oracle JDeveloper. The afternoon offers instructor guided hands on labs. It's a bring you're own laptop event; a VM is provided online as well as at the event. If your in the Boston area tomorrow Thursday August 19th it may be something worth checking out. The event is free, 8:00am to 5:30pm.