{"id":10050,"date":"2017-05-12T07:04:42","date_gmt":"2017-05-12T05:04:42","guid":{"rendered":"https:\/\/www.dbi-services.com\/blog\/apex-connect-2017-day-3\/"},"modified":"2017-05-12T07:04:42","modified_gmt":"2017-05-12T05:04:42","slug":"apex-connect-2017-day-3","status":"publish","type":"post","link":"https:\/\/www.dbi-services.com\/blog\/apex-connect-2017-day-3\/","title":{"rendered":"APEX Connect 2017 &#8211; Day 3"},"content":{"rendered":"<p>For the last conference day, after the Keynote about &#8220;JavaScript: The next Language YOU should learn&#8221; by Dan McGhan , I decided to attend presentations on following topics:<br \/>\n&#8211; Upgrade your APEX app with zero downtime by using EBR<br \/>\n&#8211; Understand and make use of CSS(3)<br \/>\n&#8211; Best Practices for APEX Administrators<br \/>\n&#8211; APEX Version Control and Team Working<br \/>\n&#8211; Database Cloud Services with APEX<br \/>\n&#8211; Date, Time, Calendar and Co with APEX<br \/>\nI also got the chance to have a 1:1 talk with Marc Sewtz to expose some wishes about APEX and talk about some customer issue.<\/p>\n<p><strong>JavaScript programming language<\/strong><br \/>\nJavaScript allows asynchronous programming: main thread can make calls to asynchronous API which return there result via an event\/callback queue.<br \/>\nWhen the web browser parses the page to be rendered the DOM tree is built. That build process is stopped whenever JavaScript is found, until the JavaScript execution is completed. That means the JavaScript can only address the the element that where already put  into the DOM tree, not the full page. That explains why people would want to put the JavaScripts at the bottom of the page definition.<br \/>\nFortunately, there is the JQuery DOM manipulation library which allows developer to abstract from that constraint.<br \/>\nWhat you also need to keep about JavaScript is:<br \/>\n&#8211; functions are the first class<br \/>\n&#8211; functions provide scope and closure<br \/>\nIn APEX you can make use of JavaScript for AJAX calls by using apex.server.process.<br \/>\nJavaScript is definitely a language that APEX developer should master beside PL\/SQL to embrace customer requirements. <\/p>\n<p><strong>Upgrade your APEX app with zero downtime by using EBR:<\/strong><br \/>\nEBR (Edition Based Redefinition) is a tool in the Oracle database to support online application upgrades.<br \/>\nYou can find details about EBR in following Oracle documentation: <a href=\"http:\/\/www.oracle.com\/technetwork\/database\/availability\/edition-based-redefinition-1-133045.pdf\">Technet Edition Based Redefinition<\/a><br \/>\nEBR allows you to have your DB looking like 2 DBs, each identified in the normal way by a service (Just like 2 CDBs in the same CDB).<br \/>\nHot rollover will be enabled by using a traffic director (load balancer).<br \/>\nThis introduces end user session to application version affinity.<br \/>\nIn APEX you need to create a copy of your application with the changes for the new version. The application version switch is managed with APEX_UTIL.SET_EDITION setting the value of the current application in the APPLICATION_PREFERENCES table.<\/p>\n<p><strong>Understand and make use of CSS(3):<\/strong><br \/>\nCSS defines the layout design. The basic structure is: selector { attribute : value }<br \/>\nThere are numerous selectors which can be combined. Also pseudo classes and elements can be used as reference.<br \/>\nYou need to be careful about the cascading order, some strong rules are set to define them. The &#8220;!important&#8221; tag which overrules should be used as less as possible.<br \/>\nThe definition of objects to be rendered is based on the Box Model (Margin &#8211; Border &#8211; Padding &#8211; Content).<br \/>\nThere are 2 levels for the definitions:<br \/>\n&#8211; Block<br \/>\n&#8211; Inline (mainly for the text)<br \/>\nPositions also have multiple definition references:<br \/>\n&#8211; static<br \/>\n&#8211; relative<br \/>\n&#8211; fixed<br \/>\n&#8211; absolute<br \/>\nMedia queries will allow the definitions for responsive design.<br \/>\nYou can verify if some elements your want to use are supported by your web browser by checking the following web site:<br \/>\n<a href=\"http:\/\/www.caniuse.com\/\">http:\/\/www.caniuse.com\/<\/a><br \/>\nI can also recommend you to visit W3C site: <a href=\"https:\/\/www.w3schools.com\/css\/\">https:\/\/www.w3schools.com\/css\/<\/a><\/p>\n<p><strong>Best Practices for APEX Administrators:<\/strong><br \/>\nFollowing best practice rules were presented based on presenter&#8217;s experience:<br \/>\n&#8211; Create a dedicated folder to store the APEX installation package (e.g. under the Oracle &#8220;product&#8221; folder)<br \/>\n&#8211; Create a dedicated tablespace for APEX<br \/>\n&#8211; Put every worspace on it&#8217;s own schema with dedicated tablespace<br \/>\n&#8211; Build your own workspace delivery system<br \/>\n&#8211; Restrict access workspace administration<br \/>\n&#8211; Use a version dedicated folder instead of \/i\/<br \/>\n&#8211; Rename ords.war based on application using it<br \/>\n&#8211; Setup automated export and backup of the workspaces and applications<br \/>\n&#8211; When patching also keep a copy of the full install package<br \/>\n&#8211; Manage downtimes during update operations (only required while sql is running)<br \/>\n&#8211; Set ACLs to give only required acces<\/p>\n<p><strong>APEX Version Control and Team Working:<\/strong><br \/>\nThere are different ways to manage team work and version control for APEX development, but none are identical to what is done for other programming languages due to the way APEX works.<br \/>\nWhat is common in the exposed ways is that the development cycle is about 3 weeks and there is always a Development, an integration, a test and a production environment. Code related to the database (DML, packages, &#8230;) is stored and managed with a version control system like GitHub and APEX application exported and pushed to the version control system on a daily basis.<br \/>\nSome people use CI (Continuous Integration) engine to generate a VM with the full test environment from the committed development work.<br \/>\nTo manage the deployment of selective features developed you need to use conditional build.<br \/>\nThere are different way to export\/import APEX applications:<br \/>\n&#8211; ApexExport java class<br \/>\n&#8211; &#8220;apex export&#8221; and &#8220;apximp&#8221; in SQLcl<br \/>\n&#8211; &#8220;Application Archive&#8221; packaged application<br \/>\n&#8211; manual export\/import<br \/>\nOracle provides some white paper describing best practices to manage APEX development process:<br \/>\n<a href=\"http:\/\/www.oracle.com\/technetwork\/developer-tools\/apex\/learnmore\/apex-life-cycle-management-wp-3030229.pdf\">http:\/\/www.oracle.com\/technetwork\/developer-tools\/apex\/learnmore\/apex-life-cycle-management-wp-3030229.pdf<\/a><\/p>\n<p><strong>Database Cloud Services with APEX:<\/strong><br \/>\nThe requirements were about the setup of a private cloud to host about 200TB of data over 300000 schemas.<br \/>\nIn order to be able to properly manage the infrastructure following tolls have been created in APEX:<br \/>\n&#8211; DB service portal (request management, password reset, reporting, cost tracking, approvals,&#8230;)<br \/>\n&#8211; DB metadata manager (reporting, interfacing, measurement of space, cpu, aso)<br \/>\n&#8211; DB service automation (order management, log management, messaging, maintenance management)<br \/>\nThis allowed to raise customer satisfaction, enhance DBA efficiency and metadata maintenance.<\/p>\n<p><strong>Date, Time, Calendar and Co with APEX:<\/strong><br \/>\nDates can be represented in different ways in the Oracle DB:<br \/>\n&#8211; DATE<br \/>\n&#8211; TIMESTAMP<br \/>\n&#8211; TIMESTAMP WITH TIME ZONE<br \/>\n&#8211; TIMESTAMP WITH LOCAL TIME ZONE<br \/>\nIf you dump those data types you will see the details of there implementation and how the Oracle DB stores them.<br \/>\nIf you subtract a number to a DATE it will return a decimal number and if you add a number to a DATE you get a DATE.<br \/>\nThere are function to manipulate dates like ADD_MONTHS (for DATE) and INTERVAL (for TIMESTAMP).<br \/>\nThe EXTRACT function allows to get specific elements of a timestamp.<br \/>\nAPEX items are always of VARCHAR2 type, so any date manipulation with implicitly use TO_CHAR and TO_DATE conversion.<br \/>\nThe date format is to be set in the APEX application globalization parameters. Most of those parameters map to the DB NLS values by default.<br \/>\nIn APEX 5.1 there were some additions to the Calendar like:<br \/>\n&#8211; ability to define Dynamic Actions<br \/>\n&#8211; JavaScript initialization on parameters<br \/>\n&#8211; &#8230;<br \/>\nI would recommend to play with the Calendar Sample application to see all new capabilities.<\/p>\n<p>Enjoy APEX!<\/p>\n","protected":false},"excerpt":{"rendered":"<p>For the last conference day, after the Keynote about &#8220;JavaScript: The next Language YOU should learn&#8221; by Dan McGhan , I decided to attend presentations on following topics: &#8211; Upgrade your APEX app with zero downtime by using EBR &#8211; Understand and make use of CSS(3) &#8211; Best Practices for APEX Administrators &#8211; APEX Version [&hellip;]<\/p>\n","protected":false},"author":17,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[368],"tags":[515,304,135,1095,1096,1090,1097],"type_dbi":[],"class_list":["post-10050","post","type-post","status-publish","format-standard","hentry","category-development-performance","tag-administration","tag-apex","tag-cloud","tag-css","tag-ebr","tag-javascript","tag-timestamp"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v27.2 (Yoast SEO v27.2) - https:\/\/yoast.com\/product\/yoast-seo-premium-wordpress\/ -->\n<title>APEX Connect 2017 - Day 3 - dbi Blog<\/title>\n<meta name=\"description\" content=\"Blog about APEX Connect 2017 Day3, focused on JavaScript, CSS, EBR, timestamp, administartion\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.dbi-services.com\/blog\/apex-connect-2017-day-3\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"APEX Connect 2017 - Day 3\" \/>\n<meta property=\"og:description\" content=\"Blog about APEX Connect 2017 Day3, focused on JavaScript, CSS, EBR, timestamp, administartion\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.dbi-services.com\/blog\/apex-connect-2017-day-3\/\" \/>\n<meta property=\"og:site_name\" content=\"dbi Blog\" \/>\n<meta property=\"article:published_time\" content=\"2017-05-12T05:04:42+00:00\" \/>\n<meta name=\"author\" content=\"Alain Lacour\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Alain Lacour\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"6 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/apex-connect-2017-day-3\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/apex-connect-2017-day-3\/\"},\"author\":{\"name\":\"Alain Lacour\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/acabba2b6ca473b44b098c2de61294b0\"},\"headline\":\"APEX Connect 2017 &#8211; Day 3\",\"datePublished\":\"2017-05-12T05:04:42+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/apex-connect-2017-day-3\/\"},\"wordCount\":1145,\"commentCount\":0,\"keywords\":[\"administration\",\"APEX\",\"Cloud\",\"CSS\",\"EBR\",\"JavaScript\",\"Timestamp\"],\"articleSection\":[\"Development &amp; Performance\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/www.dbi-services.com\/blog\/apex-connect-2017-day-3\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/apex-connect-2017-day-3\/\",\"url\":\"https:\/\/www.dbi-services.com\/blog\/apex-connect-2017-day-3\/\",\"name\":\"APEX Connect 2017 - Day 3 - dbi Blog\",\"isPartOf\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/#website\"},\"datePublished\":\"2017-05-12T05:04:42+00:00\",\"author\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/acabba2b6ca473b44b098c2de61294b0\"},\"description\":\"Blog about APEX Connect 2017 Day3, focused on JavaScript, CSS, EBR, timestamp, administartion\",\"breadcrumb\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/apex-connect-2017-day-3\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.dbi-services.com\/blog\/apex-connect-2017-day-3\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/apex-connect-2017-day-3\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Accueil\",\"item\":\"https:\/\/www.dbi-services.com\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"APEX Connect 2017 &#8211; Day 3\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/#website\",\"url\":\"https:\/\/www.dbi-services.com\/blog\/\",\"name\":\"dbi Blog\",\"description\":\"\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.dbi-services.com\/blog\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/acabba2b6ca473b44b098c2de61294b0\",\"name\":\"Alain Lacour\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/secure.gravatar.com\/avatar\/455c4c7743e192ae868a6f9e6ed875415c5887567577eccbbbf2d65012cd976a?s=96&d=mm&r=g\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/455c4c7743e192ae868a6f9e6ed875415c5887567577eccbbbf2d65012cd976a?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/455c4c7743e192ae868a6f9e6ed875415c5887567577eccbbbf2d65012cd976a?s=96&d=mm&r=g\",\"caption\":\"Alain Lacour\"},\"description\":\"Alain Lacour has more than 15 years of experience in application development with Oracle technologies. He is specialized in APEX, Java, and PL\/SQL development. His expertise also includes middleware technologies such as Oracle Weblogic and EMC Documentum. He also has a broad experience in business analysis and architecture solutions as well as in service and project management. Prior to dbi services, Alain Lacour was Senior Consultant at IMS Health in Basel. He also worked as a Software Engineer for M&amp;H Informatics in Basel. Alain Lacour holds a Master of Science in Industrial Computing from the University of Mulhouse (F). His branch-related experience mainly covers the pharma industry, with an in-depth knowledge of the drug development process as well as drug distribution.\",\"url\":\"https:\/\/www.dbi-services.com\/blog\/author\/alain-lacour\/\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"APEX Connect 2017 - Day 3 - dbi Blog","description":"Blog about APEX Connect 2017 Day3, focused on JavaScript, CSS, EBR, timestamp, administartion","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.dbi-services.com\/blog\/apex-connect-2017-day-3\/","og_locale":"en_US","og_type":"article","og_title":"APEX Connect 2017 - Day 3","og_description":"Blog about APEX Connect 2017 Day3, focused on JavaScript, CSS, EBR, timestamp, administartion","og_url":"https:\/\/www.dbi-services.com\/blog\/apex-connect-2017-day-3\/","og_site_name":"dbi Blog","article_published_time":"2017-05-12T05:04:42+00:00","author":"Alain Lacour","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Alain Lacour","Est. reading time":"6 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.dbi-services.com\/blog\/apex-connect-2017-day-3\/#article","isPartOf":{"@id":"https:\/\/www.dbi-services.com\/blog\/apex-connect-2017-day-3\/"},"author":{"name":"Alain Lacour","@id":"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/acabba2b6ca473b44b098c2de61294b0"},"headline":"APEX Connect 2017 &#8211; Day 3","datePublished":"2017-05-12T05:04:42+00:00","mainEntityOfPage":{"@id":"https:\/\/www.dbi-services.com\/blog\/apex-connect-2017-day-3\/"},"wordCount":1145,"commentCount":0,"keywords":["administration","APEX","Cloud","CSS","EBR","JavaScript","Timestamp"],"articleSection":["Development &amp; Performance"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.dbi-services.com\/blog\/apex-connect-2017-day-3\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.dbi-services.com\/blog\/apex-connect-2017-day-3\/","url":"https:\/\/www.dbi-services.com\/blog\/apex-connect-2017-day-3\/","name":"APEX Connect 2017 - Day 3 - dbi Blog","isPartOf":{"@id":"https:\/\/www.dbi-services.com\/blog\/#website"},"datePublished":"2017-05-12T05:04:42+00:00","author":{"@id":"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/acabba2b6ca473b44b098c2de61294b0"},"description":"Blog about APEX Connect 2017 Day3, focused on JavaScript, CSS, EBR, timestamp, administartion","breadcrumb":{"@id":"https:\/\/www.dbi-services.com\/blog\/apex-connect-2017-day-3\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.dbi-services.com\/blog\/apex-connect-2017-day-3\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.dbi-services.com\/blog\/apex-connect-2017-day-3\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Accueil","item":"https:\/\/www.dbi-services.com\/blog\/"},{"@type":"ListItem","position":2,"name":"APEX Connect 2017 &#8211; Day 3"}]},{"@type":"WebSite","@id":"https:\/\/www.dbi-services.com\/blog\/#website","url":"https:\/\/www.dbi-services.com\/blog\/","name":"dbi Blog","description":"","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.dbi-services.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/acabba2b6ca473b44b098c2de61294b0","name":"Alain Lacour","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/455c4c7743e192ae868a6f9e6ed875415c5887567577eccbbbf2d65012cd976a?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/455c4c7743e192ae868a6f9e6ed875415c5887567577eccbbbf2d65012cd976a?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/455c4c7743e192ae868a6f9e6ed875415c5887567577eccbbbf2d65012cd976a?s=96&d=mm&r=g","caption":"Alain Lacour"},"description":"Alain Lacour has more than 15 years of experience in application development with Oracle technologies. He is specialized in APEX, Java, and PL\/SQL development. His expertise also includes middleware technologies such as Oracle Weblogic and EMC Documentum. He also has a broad experience in business analysis and architecture solutions as well as in service and project management. Prior to dbi services, Alain Lacour was Senior Consultant at IMS Health in Basel. He also worked as a Software Engineer for M&amp;H Informatics in Basel. Alain Lacour holds a Master of Science in Industrial Computing from the University of Mulhouse (F). His branch-related experience mainly covers the pharma industry, with an in-depth knowledge of the drug development process as well as drug distribution.","url":"https:\/\/www.dbi-services.com\/blog\/author\/alain-lacour\/"}]}},"_links":{"self":[{"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/posts\/10050","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/users\/17"}],"replies":[{"embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/comments?post=10050"}],"version-history":[{"count":0,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/posts\/10050\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/media?parent=10050"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/categories?post=10050"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/tags?post=10050"},{"taxonomy":"type","embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/type_dbi?post=10050"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}