Wednesday, April 20, 2016

New to APEX? These KScope 16 sessions are for you!

The APEX Community is amazing.

It's a credit to Joel Kallman and the APEX Dev Team. It's a credit to the Oracle ACE's and ACE Directors specializing in APEX. It's a credit to those companies like Insum who challenge the stereotypes and demonstrate exactly what APEX is capable of. It's a credit to every APEX developer everywhere.

As President of ODTUG I worked with all of the communities, but I can tell you there's nothing..nothing like the APEX Community.

While many of us have been using APEX for years, we must remember the current popularity of the tool means that new developers are arriving daily - which is the subject of today's post.

A quick look at the this year's KScope16 APEX lineup and it's clear to see there's something for everyone. I took a stab at building a session list I feel would have particular appeal to someone looking at APEX for the first time, or someone without much experience with the tool. In addition to the expected APEX intro sessions, you'll see a pretty wide range of topics - everything from hands-on labs, to panel discussions, to mobile development, to SQL and PL/SQL. That's because to be that solid APEX developer, you need a solid Oracle foundation to stand on.

The list below should keep you plenty busy. Make sure to drop by the Insum booth to let me know what you think.

Oh, and you MUST plan to attend the Sunday Symposium and Thursday Deep Dive.

Click here to see the session list!

In a future post we'll assemble a session list for those more experienced APEX developers.

...our journey continues

Thursday, March 10, 2016

KScope16 Hands On Labs Announced!

ODTUG has released the APEX Hands On Labs for KScope16. There seems to be something for everyone. For the advanced APEX user, I expect Anton's session on IoT would be of interest as would Dan McGhan's session on Oracle JET. If you are just looking at APEX, David and Marc's sessions will pay dividends. Finally, no one should pass up an opportunity to hear Alex's little buddy, Shakeeb talk about migrating to the Universal Theme.

There you have it...the APEX Hands On Labs for KScope16. Save me a seat!

Application Express

Build Something! IOT = Internet + Oracle + Things

Anton Nielsen, C2 Consulting

This Hands-On Lab will introduce you to the the Internet of Things by allowing you to build your own thing and connect it to an Oracle APEX application. You will select a circuit board, wires, capacitors, a WiFi device, LEDs, and a sensor. Then you get to wire them together into a real THING, connect to the Internet, and start communicating with an Oracle Database. Finally, you will build an APEX application to control your thing and report on its data. Please note there are two scheduled times to see this session.

Productive JavaScript Development: Oracle JavaScript Extension Toolkit

Dan McGhan, Oracle Corporation
JavaScript-based, single-page applications (SPAs) are incredibly popular these days – and for good reason! This style of application provides developers with a great deal of flexibility and control, and end users enjoy the responsiveness and speed that comes with fewer full-page reloads. To empower developers working on SPAs, Oracle developed the JavaScript Extension Toolkit (JET), a collection of open-source JavaScript libraries along with a set of Oracle-contributed JavaScript libraries that make it as simple and efficient as possible to build applications that consume and interact with Oracle products and services, especially Oracle Cloud services.

In this Hands-On Lab, attendees will learn how to get started building applications with Oracle JET. We’ll jumpstart a new application with the QuickStart template and then extend it out with a few of the components that Oracle JET provides, including a data visualization component.

Building a Basic Demo Application Using Oracle Application Express

David Peake, Jason Straub, and Patrick Wolf, Oracle Corporation

This one “double” session (two-plus hours) is designed to take you through building a comprehensive application using Application Express. It is designed for people with no prior knowledge or very little experience developing with Application Express. You will learn how to develop a large number of different application components and walk out with the confidence and understanding of how to start building your own applications using Oracle Application Express.

Transitioning to Oracle Application Express 5 Universal Theme

David Peake and Shakeeb Rahman, Oracle Corporation

Oracle Application Express 5 introduces many new features that enable you to quickly build modern and beautiful HTML5 applications. The new Universal Theme implements current design trends and utilizing the new declarative template options, and puts powerful CSS3 techniques at your fingertips. In this session, you will walk through transitioning your existing application to the new Universal Theme. Using some of the packaged apps included with Oracle Application Express 4.2 as examples, we’ll demonstrate step by step how to transition these apps to Oracle Application Express 5.

Creating Mobile Applications Using Application Express 5

David Peake and Marc Sewtz, Oracle Corporation

Learn how you can declaratively build a compelling mobile application that uses some of the latest HTML5 capabilities, with Application Express. No hand crafting or in-depth knowledge of JavaScript or AJAX is required. Instead, bring your SQL knowledge and discover how quickly you can build web-based mobile applications using the Oracle Application Express declarative framework.

Monday, January 4, 2016

ODTUG APEX Gaming Competition - How'd They Do It? (Part 10)

At Kscope 15 this year we launched the first ever ODTUG APEX game competition. The APEX community responded with 15 entries! Each and every one of them left me thinking "How'd they do that?" So, let's find out more about the games and those who wrote them.

Our third place entry comes from Matt Mulvaney.

First off, tell me a little about yourself.
I’m Matt Mulvaney, a Senior Consultant who works at Explorer UK. 
You can follow me on Twitter @matt_mulvaney
How many years of APEX experience do you have?
Since version 4.1
What motivated you to participate in the APEX Gaming Competition?
It's a funny story. I had this computer game when I was a kid, I thought it was called Rescue42 or Rescue, something similar – I even forgot what it was called. 
Well I was reunited with it again earlier this year after about 267 google searches over many years. I discovered it was available for the Spectrum (even though I’ve never owned a Spectrum – yes I have no clue how I even managed to play it) and it emulated well. 
When I started to play it, I immediately remembered how you had to read and hold a load of information in your head before you even started the game and how some of the levels where really annoying and uncontrollable. I actually found some magazine scans of this game from the 80’s and after reading through those it appears as though this game is mediocre at best and it was a largely forgettable title. 
Does this even matter to me? Hell no! This was my childhood game and I loved it.

Fast forward a few months and I read about the ODTUG gaming competition and this game was just ripe for a make-over APEX style.
What is the name of your game?

The game is called Rescue42 which is what I thought the original game was called. 
I thought it might have been rescue42.exe or rescue42.bas (yup, Basic) but I wasn’t sure. The original game was actually just called Rescue (or sometimes Resqué - due to a misprint). 
Since there are 41 locations with the Castle as the 42nd location the new name kind of makes sense.

Briefly describe your game.
The game's plot is a pretty old school video gaming one – you have to rescue the princess from the castle and then return her to the safety of your base. 
The game is spread over two levels. The first level you have to dodge the guards and find items which leads to the discovery of the castle. Once you find the castle, in level two, you have to play a series of mini-games before you find the princess and then return her to your base. Simple. 
The original game had about 12 pages of text to read – my version has a minimized Guided Tour.
How long did it take you to develop your games?
Because a couple of decades had passed since I last played it, I had to re-learn the entire game again through an emulator (I'm so grateful for save states) so a few hours were spent scribbling down notes on the game. 
I started this game on my lunch hour and when the deadline approached I also worked on it during the evening in front of TV shows like The Apprentice and Better Call Saul. 
I didn’t track my time but I do remember a painful hour spent typing in coordinate data.
What was the most challenging element of your game design and how did you overcome it?
I realized early on that the game had to work with dynamic actions rather than page submissions as it had to run quick and feel like a game. However due to the large amount of dynamic actions required, a problem I found was that the game's performance ran like light speed on my laptop but ran like potatoes on 
This ran especially slow on the Reversi mini-game. I included a single player Reversi mini-game because I really like the game but oh-my-days was the mathematics & AI difficult to implement. 
The whole AI is written as a single SQL statement (isn’t that neat?) and is based on my style of play. The AI kept beating me so it was really difficult to write the ‘hey you’ve won’ screen – because, you know, that didn’t happen very often... how dare my creation beat me at my own game! 

Back to the main game, the nail-biting stuff was when I got a large component to work, for example the Guard Movements, I had to deconstruct it and remodel it so that it also worked when the player moved, looked, picked, etc. I also kept to my rule that I didn’t want to include any server side tables, objects, etc. – I wanted this to be totally APEX based. Without server-side code I therefore had a lot of dynamic actions which I needed to run over and over again - like a module, which isn't available in APEX. I achieved this by representing these as hidden items which included a select dynamic action and ran them on demand using apex.event.trigger. 
Monty, you wanted me to get technical; so you can read more on this approach here. 
Another grueling issue I had was transferring the player score when you are returning the princess back to your base when you beat the game – it would not work and it occurred just before the deadline too. I tried everything, the score would not set in session. In the end I used some of the techniques in this blog to force the score to session.

The artwork is inspired from the original cassette inlay and I used a silhouette theme throughout to keep it consistent. 
By the way, I really like some of the images in Level 2... if you make it that far.
Alright, how can I play?
Adrian Png is hosting the game for me. You can play it at 
Anything else you'd like to add?
Hope you enjoyed reading and you enjoy playing the game – to read more about this game click the link above and then click 'About this Game'. I won 3rd place in this competition so thank you to ODTUG for my membership and the Chromecast.

If anyone is reading this and hasn't used APEX yet, I encourage you to get started. Its a fantastic tool with a superb community which organises great competitions such as this one.

Thanks, Matt. There's no school like old school!! Great work!

...our journey continues

Thursday, December 31, 2015

I Beg Your Pardon

In June of 2012, my first action as President of ODTUG was to relieve Edward Roske of any and all duties related to Conference Chairman.

It seems fitting that my last act as ODTUG President is to issue the full and complete Presidential pardon Edward has sought these many years.

Therefore, ...

By the President of ODTUG a Proclamation
Edward Roske became the KScope Conference Chairman on July 1, 2010 and was reelected in 2011 for a second term by the ODTUG Board of Directors. His term in office continued until his dismissal on June 25, 2012.
Edward Roske was found to be guilty of increasing the popularity, prestige, and profitability of the 2011 and 2012  KScope Conferences without prior consent of the ODTUG President and Board of Directors.  
Now, THEREFORE, I, MONTY L. LATIOLAIS, President of ODTUG, pursuant to the pardon power conferred upon me, have granted and by these presents do grant a full, free, and absolute pardon unto Edward Roske for all offenses against ODTUG and the KScope Conference which he, Edward Roske, has committed or may have committed or taken part in during the period from July 1, 2010 through June 25, 2012.
IN WITNESS WHEREOF, I have hereunto set my hand this thirty-first day of December, in the year of our Lord two thousand and fifteen.

... our journey continues

Wednesday, December 23, 2015

ODTUG APEX Gaming Competition - How'd They Do It? (Part 9)

At Kscope 15 this year we launched the first ever ODTUG APEX game competition. The APEX community responded with 15 entries! Each and every one of them left me thinking "How'd they do that?" So, let's find out more about the games and those who wrote them.

Our winning entry comes from Anderson Rodrigues Ferreira.

First off, tell me a little about yourself.
My name is Anderson Rodrigues Ferreira.
I am from Brasilia, the capitol of Brazil! I am a Computer Engineer at Brazilian Court of Audit (Tribunal de Contas da União - TCU). 
I am Oracle Apex Developer Expert Certified; Oracle Database SQL Expert Certified and Professional Scrum Master Certified. 
I am Apex speaker in Latin American events. 
I am the coordinator of the Apex Tour Latinoamérica, the greatest Apex-only event of Latin America. 
If you want to reach me.
My twitter: @andersonrf81 
My blog: (Only in Portuguese! Sorry!)
How many years of APEX experience do you have?
6 years of Apex experience. I started in Apex 3.2
What motivated you to participate in the APEX Gaming Competition?
I love Apex, so developing a game in Apex would be great!
I like challenges and as we are upgrading Apex to version 5, I wanted experience in Apex 5. 
We decided enter the competition seven days before the submission limit, when we noticed that they changed the submission date.
This game is my first Apex 5 application! 
What is the name of your game?

The name of the game is APEX Hold'em Truco.

Briefly describe your game.
It is a multiplayer game based on Truco, the most played card game in Brazil. If you want to play alone, robots will play against you. 
This game is for four players in fixed partnerships, partners sitting opposite. 
A game consists of a series of rounds, in each of which a partnership may win one or more points. The first partnership to collect 12 (or more) points over many rounds wins the game.
How long did it take you to develop your games?
It took me 7 days! This shows us how quickly we can develop in Apex 5!
What was the most challenging element of your game design and how did you overcome it?
The discard in a multiplayer game. To solve the problem, we used a Dynamic Action that submits the discharged card and saves the cards in a table and every player refreshes periodically the page to get the cards in the game.
Alright, how can I play?
The game can be reached in the following link:
You only need to create a player (name and avatar) and select/create a game table!

Anything else you'd like to add?
Our game is a 100% Apex application and it was developed in only 7 days. It works on desktop or mobile devices. 
I loved this competition and I am planning on participate next year again!
I'd like to add that I learned a lot of Apex painting a bathroom with Monty in Kscope!

Thanks, Anderson. I remember that day well. ODTUG KScope12 Community Service Day in San Antonio.

In fact, I was able to scare up a picture or two.
We were so innocent.

It was a pleasure working beside you that day and I'm happy to call you my friend.

...our journey continues

Tuesday, December 22, 2015

A Case for Reference Models

I've used the SQL Model Clause on occasion. I've spoken on the topic as recently as last Friday to our internal development staff. I tried to stress to them that it's something that belongs in the toolbox, but it's not a tool you will pick up frequently.

One of the topics mentioned during the preso was REFERENCE MODELS. While I was aware of reference models, I never had the need to employ them.  I have no real world experience utilizing them.

Afterwards, Martin D'Souza asked for an example using REFERENCE MODELS. I was more than a little suspicious. I figured he had a requirement somewhere that he thought could best be implemented using a model clause and REFERENCE MODELS. I was right to be suspicious.

What he asked for was multiple Top-N queries within the same result set. Put another way, using the EMP table, in col A he wants the 5 highest salaries, while in col B he wants the 5 oldest dates of hire. THERE IS NO CORRELATION BETWEEN COLUMNS.

Using the MODEL clause and two REFERENCE MODELS, we were able to give him precisely what he was looking for.

select top_salary,
from dual
reference t_salary on (
   select rn,sal 
     from (select ROW_NUMBER() OVER (ORDER BY sal DESC) rn,
             from scott.emp) 
    where rownum <=5)
   dimension by (rn)
   measures (sal)
reference t_dates on (
   select rn,hiredate 
     from (select ROW_NUMBER() OVER (ORDER BY hiredate) rn,
             from scott.emp)
    where rownum <=5)
   dimension by(rn)
   measures (hiredate)
main t_main
   dimension by (rownum as x)
   measures (0 as top_salary, SYSDATE as recent_dates)
   rules iterate (5) (
     top_salary[iteration_number+1]   = t_salary.sal[iteration_number+1],
     recent_dates[iteration_number+1] = t_dates.hiredate[iteration_number+1]

I'm sure there are other ways to satisfy Martin's requirement - there always are.

The reason I wanted to share this is that my perception of REFERENCE MODELS has changed. Whereas before, I figured REFERENCE MODELS would best be used to access supplemental or complementary information to the main model. I expect they could also improve readability. I now understand that REFERENCE MODELS can be used to pull together information that is completely our case associated only by row number.

Thanks, Martin. You made me look at things differently.

...our journey continues.

Monday, December 21, 2015

ODTUG APEX Gaming Competition - How'd They Do It? (Part 8)

At Kscope 15 this year we launched the first ever ODTUG APEX game competition. The APEX community responded with 15 entries! Each and every one of them left me thinking "How'd they do that?" So, let's find out more about the games and those who wrote them.

Marcelo Burgos...would you please stand and address the class?.

First off, tell me a little about yourself.

My name is Marcelo Burgos, co-founder of Argentina Oracle Users Group and the Apex Tour Conference. Also I work for the Universidad de Buenos Aires and I'm a self-employed Apex developer.
How many years of APEX experience do you have?
I've more than 8 years working with Apex.

What motivated you to participate in the APEX Gaming Competition?
My wife is a Math teacher and asked me for a solution for get their students put a little enthusiasm in the classroom. I thought I could kill two birds of one shot, developing a game for help the students to study geometry with fun, and if possible, for winning the Apex gaming competition.
What is the name of your game?

The name of the game is Leonhard, which is a tribute to Leonhard Euler, the Graphs theory father.

Briefly describe your game.
The game consists of multiple graphics, and you have to "draw" over all the lines of each figure without "lifting the pencil from the paper". You cannot pass the "pencil" twice for the same line. 
For draw a line you have to click at both ends.
How long did it take you to develop your games?
I  developed the app in five stages. Each stage took us a week for thinking and a couple days for coding. The game have a lot of artwork that took other two days to transform from analog (paper) to digital (database).
What was the most challenging element of your game design and how did you overcome it?
Technically, the app works drawing lines and points over a html5 canvas element.

An Ajax callback pl/sql process works dynamically building javascript code each time you clic a point. We had to resort to a lot of Oracle techniques such as functions and Apex collections, and we had to resort a special canvas library for facilitate the identification of the points you clic during the game.
Alright, how can I play?
You can play the game at the url and uses open authentication although is mandatory to enter your name.
Anything else you'd like to add?
After the competition we follow working in the program due is expected to be used for my wife's students. After removing a couple bugs, now we get to include 3D shapes in the game, and now also we translated the app to spanish. That sounds simple, but we had to work a lot to fix an unexpected problem: numeric format after language localization brokes all the code inside the javascript.  
You learn something new every day.

Thanks, Marcelo. In the coming days we'll share more insight into a few of the remaining games that were part of the contest.

...our journey continues