My Oracle Code Conference Experience


This was my first time attending an Oracle Code conference. The conference was a one day free conference held in Washington, DC at the Sheraton Metro Center. The conference included two keynote addresses followed by several breakout sessions. This is an overview of the sessions I attended.


The first session on ChatBots was presented by Siddhartha Agarwal. I had never heard of ChatBots so I was very interested to hear more about them.

A ChatBot is basically interfacing with a messenger application (Facebook Messenger, Text Messages, etc) to do a task for you and it may include some Artificial Intelligence (AI).

A demo was done from a mobile app. The user sent a message asking if any tickets were available for a sporting event. The ChatBot used AI to determine that the user’s query for available seats, meant the user really wanted to purchase seats. Through a series of messages, the ChatBot walked the user through buying tickets to the game, including a food/drink package and keeping the user within a predefined budget.

After seeing this demo, I was intrigued by ChatBots so I searched on Udemy for ChatBot courses. It turns out they have lots of courses on building ChatBots. This one seemed the most interesting to me: Build Incredible Chatbots.

SQL Pattern Recognition

In this next session, presented by Hermann Baer, the discussion was on how to use SQL to identify patterns is a set of data. The premise for this is using SQL to search rows of data for certain specified patterns and once a pattern is found, Oracle returns results for that pattern. To achieve this in an efficient manner Oracle developed a new SQL statement: MATCH_RECOGNIZE. This statement is available in Oracle 12c. Here’s an example of the statement:

FROM v_archived_log MATCH_RECOGNIZE (  
ORDER BY completion_time  
MEASURES to_char(FIRST (A.completion_time),'yyyy-mm-dd hh24:mi:ss') AS start_time,to_char(LAST (A.completion_time),'yyyy-mm-dd hh24:mi:ss') AS end_time,sum(A.blocks*A.block_size/1024/1024) as mbytes  
SUBSET A = (Y, Z)  
        Y AS (Y.completion_time - FIRST(Y.completion_time)) <= 1,
        Z AS (Z.completion_time - FIRST(Y.completion_time)) <= 1 and sum(A.blocks*A.block_size)/1024/1024 >= 30000

Since you’re searching for patterns in rows of data, it’s important the rows are ordered. The MEASURES clause defines the value that will be calculated for each match found. For each match found in the sequence of rows, MATCH_RECOGNIZE can return either all rows (“ALL ROWS PER MATCH”) within the match or a single row summarizing it. The “ONE ROW PER MATCH” says only give me one summary row per match. The PATTERN clause is specified as a regular-expression but in terms of rows: “Y+ Z“, which means “one or more rows that match the Y condition, followed by one row that matches the Z condition”, where Y and Z are the conditions specified in the DEFINE clause. The SUBSET clause defines the set A as the union of all Y‘s and Z‘s.

In the session, the presenter show a real world example where a SQL statement was used to detect fraud in stock trading. Right now, it appears the statement is only available in Oracle, but it was added to ANSI SQL 2016 so it may eventually be available for other databases. If you ever need to search for patterns in your data, it may be a handy tool to be aware of.


This next session, presented by Hans-Henry Sandbaek and Florian Kirmaier, was the most exciting to me as a Java developer. JPRO offers the ability to have your Java application run in browsers and mobile devices without any plugins. It runs Java’s latest UI product JavaFX (Oracle’s replacement for Swing) on the server and maps its scenegraph directly into the browser. It also uses GLUON. Here's a diagram showing how the technologies fit together:

Here’s a diagram of the JPRO architecture:

JPRO provides renders for each platform or you may develop your own renderer. Here's a digram showing the relationship between the various platforms, renders, and JPRO:

JPRO is still in closed beta stage but if you want to check it out you may sign up for an account.

Unfortunately, right now the product is owned by a German company and not supported by Oracle. Once it’s ready for public release, I hope Oracle takes it over and incorporates JPRO into the standard Java product.

JSON Data Type

The next session I attended, presented by Morgan Tocker, talked about MySQL 5.7.8 new native datatype, JSON (JavaScript Object Notation). He said the JSON data type is useful if your data’s attributes vary between data sets. For example, if a company sold various products like dresses, pants, shoes, coffee pots, computers, vacuum cleaners, etc. Each of their products has different attributes. JSON may be used to store each product with it’s own set of attributes. Here’s an example of the CREATE TABLE statement with the attributes defined as JSON:

CREATE TABLE products(  
attributes JSON NOT NULL  

To insert JSON, just enter valid JSON into the table as shown in these examples:

INSERT INTO products(attributes)  
VALUES({“id”: 123, "name": "dress", "size": "12", "color":”black”, “length” : “mini”});

INSERT INTO products(attributes)  
VALUES({“id”: 124, "name": "computer monitor" , "screen": "30 inch", "resolution": "1600 x 900 pixels", "ports": {"hdmi": 1, "usb": 1}, "speakers": {"left": "10 watt", "right": "10 watt"}}'  

The main search functions are JSON_EXTRACT, JSON_CONTAINS, and JSON_SEARCH. The JSON_EXTRACT function is efficient, in the sense that it looks for values at a specific path. The path is similar to a CSS selector. Here’s an example: SELECT * FROM products WHERE JSON_EXTRACT(attributes, "$.color") = 'black'; Here are some functions for modifying parts of the JSON document:

Java EE 7 and WebSockets

In my last session, presented by Reza Rahman, Reza discussed using Java EE 7’s support for WebSockets to handle applications where you need to maintain state between the client and the server. If you want to find out more about WebSockets check out the code at Reza’s github


I learned quite a bit at the free one day conference. Since Sequoia gives us time to attend conferences like this, I recommend you check Oracle Code out next year.