tag:blogger.com,1999:blog-21328931361408482122024-01-03T18:34:42.517-07:00Martin Giffy D'Souza on Oracle APEXOracle APEX hints and tipsMartin D'Souzahttp://www.blogger.com/profile/06992954599899886499noreply@blogger.comBlogger239125tag:blogger.com,1999:blog-2132893136140848212.post-90098493775723865442016-08-24T06:01:00.000-06:002016-08-24T06:01:48.516-06:00APEX OOW 2016 MeetupEach year the Oracle APEX community gets together at Oracle Open World (OOW) to have a few beers and catch up. This is a great informal event and its your chance to network with a lot of people in the APEX community and meet some of the gurus and members of the core APEX development team.<br />
<br />
We'll be having the annual APEX OOW Meetup at <a href="http://www.johnnyfoleys.com/" target="_blank">Johnny Foleys</a> on Tuesday September 20th at 7:30 onwards. Please let us know if you're coming by signing up on the <a href="http://www.meetup.com/ODTUGers/events/233289975/?a=socialmedia" target="_blank">Meetup for this event</a>.<br />
<br />
If it's your first time attending, we're in the basement and there will be dueling piano's. Show up early as it gets packed pretty!<br />
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjMi7RZzgdDWYFoI-CXqvSZaLnJmsXkIn2H7zops3PyP0YQTGypr7jA5POqDQz01OxIlAZ0ofY_0aWT0Y9u51_H8S1qqjDqGyRnw5FYVS_zdzlf-ozKPeg4S5nZK4PCz3Ozpn7UceJWbJID/s1600/johnnyfoleys.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="203" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjMi7RZzgdDWYFoI-CXqvSZaLnJmsXkIn2H7zops3PyP0YQTGypr7jA5POqDQz01OxIlAZ0ofY_0aWT0Y9u51_H8S1qqjDqGyRnw5FYVS_zdzlf-ozKPeg4S5nZK4PCz3Ozpn7UceJWbJID/s1600/johnnyfoleys.jpg" width="400" /></a></div>
<br />
<a href="http://goo.gl/zgbr9m" target="_blank">243 O'Farrell Street</a><br />
<a href="http://goo.gl/zgbr9m" target="_blank">San Francisco, CA 94102</a><br />
<br />
<br />
Looking forward to seeing everyone there!<br />
<br />
MartinMartin D'Souzahttp://www.blogger.com/profile/06992954599899886499noreply@blogger.com0tag:blogger.com,1999:blog-2132893136140848212.post-5536140260713336872016-08-02T07:00:00.000-06:002016-08-02T07:00:01.929-06:00ODTUG Leadership Program<i>ODTUG has long been recognized as an outstanding source for the technical content Oracle professionals desire, but that’s only half of the story. We’re providing our members with yet another avenue to add to their skills and increase their value to their employer or client. ODTUG is pleased to open enrolment for the fourth class of the <a href="http://www.odtug.com/p/cm/ld/fid=127?utm_source=email&utm_campaign=leadership&cmp=1&utm_medium=HTMLEmail" target="_blank">ODTUG Leadership Program</a></i><br />
<br />
I've had the opportunity to work with some of the classes and individuals from the Leadership Program and have heard some amazing stories on how this program changed peoples lives and carriers!<br />
<br />
If you, or someone you know, is interested I encourage you to <a href="http://www.odtug.com/p/cm/ld/fid=127?utm_source=email&utm_campaign=leadership&cmp=1&utm_medium=HTMLEmail" target="_blank">submit an application</a>. Applications must be submitted by August 14th so hurry up!Martin D'Souzahttp://www.blogger.com/profile/06992954599899886499noreply@blogger.com0tag:blogger.com,1999:blog-2132893136140848212.post-49472435456826590622016-02-21T18:21:00.000-07:002016-02-21T18:21:30.728-07:00APEX and the Nest ThermostatAt ODTUG <a href="http://kscope15.com/" target="_blank">Kscope 15</a> last year I gave a presentation about APEX plugins. During the presentation I built a plugin from scratch to control my <a href="https://nest.com/" target="_blank">Nest Thermostat</a>. Everything went well until I did a live demo connecting the APEX plugin with my home Nest. I forgot to enable a service and unfortunately the demo didn't work.<br />
<br />
I recently gave a talk to the Vancouver Oracle User Group on <a href="http://martindsouza.github.io/pres-apex-ent-dev/#/">APEX and the Future of Enterprise Development</a>. During this presentation I pre-recorded a video of APEX controlling my home Nest to highlight that APEX can work with the Internet of Things (IoT).<br />
<br />
There has been some interest to see this in action so I have included a copy of the video below. On the right is a Nest plugin that I wrote for APEX, the left is the Nest app on an Android tablet, and in the center is the actual Nest.<br />
<br />
<div class="separator" style="clear: both; text-align: center;">
<iframe allowfullscreen="" class="YOUTUBE-iframe-video" data-thumbnail-src="https://i.ytimg.com/vi/dpsqVgE-WQg/0.jpg" frameborder="0" height="266" src="https://www.youtube.com/embed/dpsqVgE-WQg?feature=player_embedded" width="320"></iframe></div>
<br />Martin D'Souzahttp://www.blogger.com/profile/06992954599899886499noreply@blogger.com0tag:blogger.com,1999:blog-2132893136140848212.post-77498972139865208482016-01-04T07:00:00.000-07:002016-02-21T17:40:39.877-07:00Eh?PEX Unofficial TourThis year I will be taking some trips across Canada and have been given the opportunity to speak in various cities. Thus the unofficial Eh? PEX tour.<br />
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhVfqvDZu12NLnqxn0aQ64MGKmYsgPGdduAc4QgwOkBQlPgVvLJt0XtAwWBVCP48Rv4rVLYR12ZJ4GtwveLJwaP6vIwSIi2D3RJimrXJfUngEhyphenhyphen2ZaDKWmlD53pnRwmPSg_FNl2V1Pdm9r1/s1600/canada2.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="200" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhVfqvDZu12NLnqxn0aQ64MGKmYsgPGdduAc4QgwOkBQlPgVvLJt0XtAwWBVCP48Rv4rVLYR12ZJ4GtwveLJwaP6vIwSIi2D3RJimrXJfUngEhyphenhyphen2ZaDKWmlD53pnRwmPSg_FNl2V1Pdm9r1/s200/canada2.jpg" width="143" /></a></div>
<br />
Here are the different cities and links to each event:<br />
<br />
<ul>
<li><a href="http://www.meetup.com/GTA-Oracle-APEX-Development-Meetup/events/227780110/">12-Jan GTA/Toronto APEX Meetup</a></li>
<ul>
<li><a href="http://martindsouza.github.io/pres-apex-ent-dev/">Open Source and APEX</a></li>
<li>Q&A (bring your Oracle & APEX questions)</li>
</ul>
<li><a href="http://coug.ab.ca/events/">21-Jan Calgary Oracle User Group</a></li>
<ul>
<li><a href="http://martindsouza.github.io/pres-open-source-oracle/#/">Open Source Oracle: Tools That Make My Life Easier</a></li>
</ul>
<li><a href="https://www.eventbrite.ca/e/orclapex-yvr-meetup-3-tickets-20446209162">4-Feb Vancouver Oracle User Group</a></li>
<ul>
<li><a href="http://martindsouza.github.io/pres-apex-ent-dev/#/">APEX and the Future of Enterprise Development</a></li>
</ul>
</ul>
<div>
Special thanks to <a href="http://insum.ca/">Insum Solutions</a> for helping make this all possible.</div>
<div>
<br /></div>
<div>
For those located in Calgary we have our monthly <a href="http://www.meetup.com/orclapex-YYC/">YYC APEX Meetup</a> group.</div>
Martin D'Souzahttp://www.blogger.com/profile/06992954599899886499noreply@blogger.com3tag:blogger.com,1999:blog-2132893136140848212.post-61090489503230030912015-11-16T07:00:00.000-07:002015-11-16T07:00:05.158-07:00ClariFit From/To Date Picker Plug-in Moved to OraOpenSource<i>This article is for people looking for help with the ClariFit From/To Date Picker</i>.<br />
<br />
I'm currently in the process of updating some of the plugins I created for ClariFit to support APEX 5.0. As part of these changes some additional things are happening, mainly listing the plugins in the new <a href="http://apex.world/">apex.world</a> site and moving the plugins ownership over to <a href="https://github.com/OraOpenSource">OraOpenSource</a>.<br />
<br />
The first plugin that has been moved/updated is the ClariFit From/To Date Picker. The plugin is now called OraOpenSource From/To Date Picker and is hosted <a href="https://github.com/OraOpenSource/apex-plugin-from-to-datepicker">here</a>. To help with backwards compatibility the plugin's internal name has remained the same. This means that upgrades will be seamless.<br />
<br />
Please post all bugs and enhancement requests on the project's <a href="https://github.com/OraOpenSource/apex-plugin-from-to-datepicker/issues">issue page</a>.<br />
<br />
<br />
The next plugin that will be updated is the ClariFit Dialog (to be called OraOpenSource Dialog). It is currently being tested and will be officially released pending any major bugs. If you'd like any other ClariFit plugins updated to APEX 5.0 please leave a comment and I'll look into it.Martin D'Souzahttp://www.blogger.com/profile/06992954599899886499noreply@blogger.com0tag:blogger.com,1999:blog-2132893136140848212.post-41214040117668131092015-11-09T07:00:00.001-07:002015-11-09T07:00:08.944-07:00ODTUG ElectionIf you were at Oracle Open World a few weeks ago you may have missed that the <a href="http://archive.skem1.com/Campaigner/Public/t.show?9331d--5txha-19v43px8&_v=2">ODTUG Board of Directors election results</a> were posted.<br />
<div>
<br /></div>
<div>
The newly elected directors are:</div>
<div>
<ul>
<li><a href="https://twitter.com/opal_epm">Opal Alapat</a></li>
<li><a href="https://twitter.com/dbaontap">Danny Bryant</a></li>
<li><a href="https://twitter.com/garycrisci">Gary Crisci</a></li>
<li><a href="https://twitter.com/essbaselady">Natalie Delemar</a></li>
<li><a href="https://twitter.com/martindsouza">Martin D'Souza</a></li>
</ul>
<div>
<br /></div>
<div>
I first must thank all the people that voted for me again this year. It means a lot that I have the support of the APEX and Oracle communities. </div>
<div>
<br /></div>
<div>
They're a few board members who will not be returning next year. They all have done a lot for ODTUG and its members.</div>
</div>
<div>
<ul>
<li><a href="https://twitter.com/monty_latiolais">Monty Latiolais</a></li>
<ul>
<li>Monty has been the President of ODTUG for the past few years. He's done an amazing job leading the organization. Monty's lasting legacy at ODTUG will be the <a href="http://www.odtug.com/p/cm/ld/fid=127">Leadership Program</a>. He took a risk trying it out and it has been a very big success helping develop leaders within the ODTUG community.</li>
</ul>
<li><a href="https://twitter.com/dschleis">David Schleis</a></li>
<ul>
<li>David has helped re-energize the traditional developer and DBA communities. Over the past two years he helped merged them into one united "database" community. I look forward to David to continue help out with the database community in the coming years.</li>
</ul>
<li><a href="https://twitter.com/miaurman">Mia Urman</a></li>
<ul>
<li>Mia has been instrumental with helping foster the ADF community and lead the global outreach program. Both of these areas require a lot of time and effort, all which Mia happy put in. If you're going to be at <a href="http://2015.doag.org/en/home/">DOAG</a> in a few weeks look for Mia who be representing <a href="http://odtug.com/">ODTUG</a>.</li>
</ul>
</ul>
<div>
I also need to say a special thank you to the current board for supporting me over the past year. Last year was a very difficult time for me personally and they all stepped up and supported me along the way. This is something I will never forget and will always be thankful for.</div>
</div>
<div>
<br /></div>
<div>
As ODTUG has a six year term limit for directors, this will be my last two years. I look forward to making them as good as the first four. If you have any feedback or things you'd like to see happen within the community please let me know.</div>
<div>
<br /></div>
<div>
- Martin</div>
Martin D'Souzahttp://www.blogger.com/profile/06992954599899886499noreply@blogger.com0tag:blogger.com,1999:blog-2132893136140848212.post-29950346051084804562015-11-09T07:00:00.000-07:002015-11-09T07:00:00.967-07:00ODTUG Technical Journal - Authors WantedIf you've ever thought of starting your own blog or wanted to write a detailed article on some cool APEX or Oracle feature but didn't know where to start, now's your big chance! The <a href="http://www.odtug.com/technical-journal-corner">ODTUG Technical Journal</a> is looking for some new articles and we'd like to see articles from first time contributors.<br />
<br />
Signing up is easy. Simply email Karen Cannell (kcannell@odtug.com) and let her know that you're interested in writing an article for the journal. Then you can work out a schedule with her. After that, all you need to do is write the article, Karen will take care of the rest.<br />
<br />
This is a great opportunity to get your name out there and also promote what you and your organization have been been working on. I'm looking forward to seeing some great content from the APEX community.<br />
<br />
<br />Martin D'Souzahttp://www.blogger.com/profile/06992954599899886499noreply@blogger.com0tag:blogger.com,1999:blog-2132893136140848212.post-745100179556851402015-11-02T09:00:00.000-07:002015-11-02T09:00:02.573-07:001st Calgary APEX Meetup<br />
<div>
We're having our <a href="http://www.meetup.com/orclapex-YYC/events/226256566/">1st inaugural APEX meetup</a> on Thursday Nov 12th! I'll be giving a presentation about APEX 5 and the new <a href="http://apex.world/">apex.world</a> site.</div>
<div>
<br /></div>
<div>
FAQs I've received about this meetup:</div>
<div>
<ul>
<li>Does it cost anything? <i>No, it's entirely free </i></li>
<li>What should I bring? <i>Yourself. Some people like to bring their laptop to try things out at the same time. </i></li>
<li>Is this a sales pitch: <i>No, it's by the APEX community, for the APEX community. </i></li>
<li>Will only APEX items be covered? <i>Primarily we'll be talking about APEX but may deviate a bit in the future to cover some SQL, PL/SQL, and web technologies. These topics are all relevant for APEX developers. </i></li>
<li>Where can I get one of the cool APEX stickers I see everyone has on Twitter? <i>At the meetup. I've got a whole stack to give away.</i></li>
</ul>
</div>
<div>
<br /></div>
<div>
Location details:</div>
<div>
<br /></div>
<div>
Trident Limited Partnership </div>
<div>
<a href="https://goo.gl/maps/Fx5jG4CoMHt">1000, 444 - 7 Avenue SW (Barclay building) </a></div>
<div>
<a href="https://goo.gl/maps/Fx5jG4CoMHt">Calgary, Alberta T2P 0X8</a></div>
<div>
<br /></div>
<div>
<i>10th floor -- Must sign-in at reception desk</i></div>
<div>
<br /></div>
<div>
<br /></div>
<div>
Special thanks to Jean Paradis and <a href="http://www.tridentexploration.ca/">Trident Limited Partnership</a> for securing the meeting space!</div>
<div>
<br /></div>
<div>
<br /></div>
<div>
Please <a href="http://www.meetup.com/orclapex-YYC/events/226256566/">RSVP</a> to let us know if you're coming.</div>
Martin D'Souzahttp://www.blogger.com/profile/06992954599899886499noreply@blogger.com0tag:blogger.com,1999:blog-2132893136140848212.post-31020941902938651422015-10-26T10:00:00.000-06:002015-10-27T08:06:04.958-06:00APEX PodcastIf you can't get enough APEX there's now an <a href="http://apex.press/talkshow">APEX Podcast</a>! This is a great opportunity to know more about the people behind APEX and some key people in the APEX community.<br />
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="http://apex.press/" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjSWRSOBHkXOHWvafDfFxAQTsaUytxuXzht5J9_AijAzRrWo9YIZoETJIWGXTJu7etc00dsuMW8ShGHYR2To5l_0jOXLb7YOfL2RUrxPUBoO_buoSQC2bNyXwqWXZ5LcAHMr-v15VPo98Ji/s1600/JSPodcastdesign150px.jpg" /></a></div>
<br />
<a href="https://twitter.com/juergenschuster">Juergen Schuster</a> and I co-host the show (I only joined on recently) and it has been a lot of fun so far.<br />
<br />
You can download each episode on the official site (<a href="http://apex.press/talkshow">apex.press/talkshow</a>) or subscribe on <a href="https://itunes.apple.com/gb/podcast/the-oracle-apex-talkshow/id979577290?mt=2">iTunes</a>.<br />
<br />
<i>Note: In the latest podcast we mentioned that we're looking for sponsors for the show. If you or your organization is interested in the opportunity please <a href="mailto:martin@talkapex.com">email me</a>.</i><br />
<br />Martin D'Souzahttp://www.blogger.com/profile/06992954599899886499noreply@blogger.com1tag:blogger.com,1999:blog-2132893136140848212.post-86939145087671286992015-10-19T07:00:00.000-06:002015-10-19T07:00:03.946-06:00OOW 15 PresentationsIf you're attending <a href="https://www.oracle.com/openworld/index.html">Oracle OpenWorld 2015</a> this year here are a few links for presentations I'd recommend:<br />
<br />
<ul>
<li><a href="https://events.rainfocus.com/oow15/catalog/oracle.jsp?search=UGF4096&search.event=openworldEvent"> Open Source and Oracle Application Express [UGF4096]</a></li>
<ul>
<li>Sunday Oct 25 8:00am - Moscone South Room 300</li>
<li>Martin Giffy D'Souza</li>
<li>If you've ever thought about using open source applications or want to become more involved with open source development for your Oracle and APEX applications this presentation is for you.</li>
</ul>
<li><a href="https://events.rainfocus.com/oow15/catalog/oracle.jsp?search=UGF10050&search.event=openworldEvent">The Objects of My Affection: Deploying Your APEX Applications [UGF10050]</a></li>
<ul>
<li>Sunday Oct 25 10:00am - Moscone South Room 300</li>
<li>Francis Mignault</li>
<li>Learn how to deploy your applications for testing, QA, and production. Also learn how supporting objects work, and see the new Oracle Application Express 5 features that will help you package and deploy your applications.</li>
</ul>
<li><a href="http://www.odtug.com/p/cm/ld/fid=175">ODTUG Sunday Sessions</a></li>
<ul>
<li>There's a lot of great presentations. Readers of this blog will most likely be focused on the <a href="http://www.odtug.com/p/cm/ld/fid=175#ADF">PL/SQL</a> and <a href="http://www.odtug.com/p/cm/ld/fid=175#APEX">APEX</a> sessions.</li>
</ul>
</ul>
<div>
<br /></div>
<div>
On Tuesday night there will be the <a href="http://www.talkapex.com/2015/09/apex-oow-2015-meetup.html">APEX meetup</a>. Don't get their too late since it fills up pretty quickly. We'll be in the basement.</div>
<div>
<br /></div>
<div>
I'll also be filming some Periscope interviews for ODTUG. If you can't attend OOW then you'll want to follow the <a href="https://twitter.com/odtug">ODTUG twitter account</a>. This will be the first time ODTUG has ever done this and we'd appreciate your feedback. If there's someone you'd like to see interviewed during the conference please let me know below by leaving a comment on this post.</div>
<div>
<br /></div>
<div>
I look forward to seeing everyone there!</div>
Martin D'Souzahttp://www.blogger.com/profile/06992954599899886499noreply@blogger.com0tag:blogger.com,1999:blog-2132893136140848212.post-47851652696293027632015-10-06T09:03:00.000-06:002015-10-06T09:03:16.895-06:00ODTUG 2015 Election - Please VoteThe ODTUG Board of Directors election is <a href="http://www.odtug.com/page/2016-nominees">now officially open</a>. Paid ODTUG members can cast their ballot between Oct 6th - Oct 27th. If you are a paid member you will get an email with the link, username, and voter id.<br />
<br />
I am running for the ODTUG Board of Directors and I am looking for your support to continue to help the ODTUG community for another two years.<br />
<br />
Here is my official campaign statement:<br />
<br />
<i>Over the past four years, I have had the privilege to represent the Oracle APEX Community as a Director for ODTUG. I have made the decision to run again this year for the ODTUG Board and am looking for your support in doing so.</i><br />
<i><br /></i>
<i>During my four-year tenure, I have been involved in several committees within ODTUG that have helped bring conferences around the world, improved marketing initiatives, and organized developer contests. </i><br />
<i><br /></i>
<i>I have been able to build strong relationships with other ODTUG Board Members, Oracle employees, and many developers in the APEX community. These relationships have allowed me to be a liaison between all three groups and help relay ideas and opportunities to the appropriate parties. I hope to continue to be able to facilitate open communication over the next two years.</i><br />
<i><br /></i>
<i>I am looking for your vote to continue as an ODTUG Board Member to represent developers within one of the world’s largest Oracle user groups. Thank you in advance for your support.</i><br />
<br />
Thank you in advance,<br />
<br />
MartinMartin D'Souzahttp://www.blogger.com/profile/06992954599899886499noreply@blogger.com0tag:blogger.com,1999:blog-2132893136140848212.post-89468948731792114082015-10-05T11:52:00.001-06:002015-10-05T11:53:57.750-06:00APEX Webinar: From the Community, for the CommunityODTUG will be hosting an APEX webinar on Monday, Oct 19th at 12:00pm EDT. The webinar is about something that several key members of the APEX community have been working on that is "<i>from the community, for the community</i>". <b>I strongly recommend that everyone attend this webinar. </b><br />
<br />
I can't say anything more than the above statement and all will be revealed in the webinar. Registration is free, and you can register using <a href="https://attendee.gotowebinar.com/register/5033519521597802241">this link</a>.<br />
<br />
<br />Martin D'Souzahttp://www.blogger.com/profile/06992954599899886499noreply@blogger.com1tag:blogger.com,1999:blog-2132893136140848212.post-56139668607392504422015-09-28T07:00:00.000-06:002015-09-28T07:00:00.743-06:00APEX OOW 2015 MeetupEach year the Oracle APEX community gets together at Oracle Open World (OOW) to have a few beers and catch up. This is a great informal event and its your chance to network with a lot of people in the APEX community and meet some of the gurus and members of the core APEX development team.<br />
<br />
We'll be having the annual APEX OOW Meetup at <a href="http://www.johnnyfoleys.com/" target="_blank">Johnny Foleys</a> on Tuesday, October 27th at 7:30 onwards. We've been their a few times now and it is a really fun night since they have duelling pianos later on in the evening. Don't show up too late or it may be tough to get in.<br />
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjMi7RZzgdDWYFoI-CXqvSZaLnJmsXkIn2H7zops3PyP0YQTGypr7jA5POqDQz01OxIlAZ0ofY_0aWT0Y9u51_H8S1qqjDqGyRnw5FYVS_zdzlf-ozKPeg4S5nZK4PCz3Ozpn7UceJWbJID/s1600/johnnyfoleys.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="163" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjMi7RZzgdDWYFoI-CXqvSZaLnJmsXkIn2H7zops3PyP0YQTGypr7jA5POqDQz01OxIlAZ0ofY_0aWT0Y9u51_H8S1qqjDqGyRnw5FYVS_zdzlf-ozKPeg4S5nZK4PCz3Ozpn7UceJWbJID/s320/johnnyfoleys.jpg" width="320" /></a></div>
<br />
<br />
<a href="http://goo.gl/zgbr9m" target="_blank">243 O'Farrell Street</a><br />
<a href="http://goo.gl/zgbr9m" target="_blank">San Francisco, CA 94102</a><br />
<br />
<a href="http://odtug.com/" target="_blank">ODTUG</a> will also be giving away some cool APEX swag!<br />
<br />
Looking forward to seeing everyone there!<br />
<br />
MartinMartin D'Souzahttp://www.blogger.com/profile/06992954599899886499noreply@blogger.com0tag:blogger.com,1999:blog-2132893136140848212.post-21690525355029142172015-09-13T21:46:00.001-06:002015-09-13T21:49:26.422-06:00Custom Code for Tabular Forms (Part 2)The <a href="http://www.talkapex.com/2015/09/custom-code-for-tabular-forms-part-1.html">previous article</a> covered how to create a Tabular Form with manual code rather than automatic row processing. This article will demonstrate how to change the Tabular Form to modify data from multiple tables using the same Tabular Form.<br />
<br />
<h4>
<span style="font-weight: normal;">Modify Tabular Form</span></h4>
Using the example from the <a href="http://www.talkapex.com/2015/09/custom-code-for-tabular-forms-part-1.html">previous article</a>, modify the Tabular Form and change the query to:<br />
<pre class="brush: sql;">select
e.empno,
e.empno empno_display,
e.ename,
e.sal,
d.dname
from emp e, dept d
where 1=1
and e.deptno = d.deptno
</pre>
<h4>
<span style="font-weight: normal;">Edit DNAME</span></h4>
<div>
Edit the newly added DNAME column with the following changes:</div>
<div>
<br /></div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi4fNh_hyCmWMQQadxx4mR2Qh1Hvxl407ILnXqzoyQ16S5P1jdETWLbfQ8KzEWH9euflp67NACSq7BR3znhqkzvHqQXvWOjbgDLB13VtlQnb3l30ruhlcQByEUQzVEadW7gNOL0dJE9qtjb/s1600/Snip20150819_8.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="91" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi4fNh_hyCmWMQQadxx4mR2Qh1Hvxl407ILnXqzoyQ16S5P1jdETWLbfQ8KzEWH9euflp67NACSq7BR3znhqkzvHqQXvWOjbgDLB13VtlQnb3l30ruhlcQByEUQzVEadW7gNOL0dJE9qtjb/s320/Snip20150819_8.png" width="320" /></a></div>
<div class="separator" style="clear: both; text-align: center;">
<br /></div>
<h4>
<span style="font-weight: normal;">Modify Page process</span></h4>
<div>
<span style="font-weight: normal;">Change the page process to use the code snippet below. <i>Note: </i></span><i>This isn't the best example, as the below code will update the department name for each modified employee record. It does highlight is that you can reference and modify data from multiple tables.</i></div>
<pre class="brush: sql;">if :empno is null then
-- code to insert emp
null;
else
update emp
set
ename = :ename,
sal = :sal
where empno = :empno;
-- Update dept name
update dept d
set dname = :dname
where 1=1
and d.deptno = (
select e.deptno
from emp e
where e.empno = :empno)
end if;</pre>
<div>
<br /></div>
<div>
<br /></div>
<div>
<div>
If you've ever developed a true manual tabular form using collections, the above approach covered in this article may be a better alternative to manage and maintain.</div>
</div>
Martin D'Souzahttp://www.blogger.com/profile/06992954599899886499noreply@blogger.com1tag:blogger.com,1999:blog-2132893136140848212.post-25796200518680436082015-09-13T21:44:00.000-06:002015-09-13T21:46:05.513-06:00Custom Code for Tabular Forms (Part 1)<i>Over a year ago I <a href="http://www.talkapex.com/2014/03/running-custom-code-for-tabular-forms.html">wrote an article</a> covering how to create a tabular form and then use custom PL/SQL to process the data rather than the automatic Apply MRU and Apply MRD processes. The demo showed how to do this in APEX 4.2. This article will re-introduce the topic but use APEX 5.0 instead.</i><br />
<i><br /></i>
<br />
<h4>
<span style="font-weight: normal;">Create new Tabular Form</span></h4>
<div>
<ul>
<li>Create page > Page type: Form > Tabular Form</li>
<li>Select the following options: </li>
<div class="separator" style="clear: both; text-align: center;">
</div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjqUcetDxG-Q-cwTwERBhVerGtCyEtHR5Q8cD7zIu4P5G13ibOoPtSOSTVDNILPX1B_RBpuSUWKnPtZcOIk2BkgTZnY-9DtxeE0PaO08lX1V1Fr6ZlvUYlQN58BHQsuQRAGB_FPIbHcfjai/s1600/Snip20150819_4.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="262" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjqUcetDxG-Q-cwTwERBhVerGtCyEtHR5Q8cD7zIu4P5G13ibOoPtSOSTVDNILPX1B_RBpuSUWKnPtZcOIk2BkgTZnY-9DtxeE0PaO08lX1V1Fr6ZlvUYlQN58BHQsuQRAGB_FPIbHcfjai/s400/Snip20150819_4.png" width="400" /></a></div>
<ul>
<li>Note: For simplicity/demo purposes, limiting to just the <span style="font-family: Courier New, Courier, monospace;">SAL</span> and <span style="font-family: Courier New, Courier, monospace;">ENAME</span> columns.</li>
</ul>
<li>Primary Key: Select Primary Key Column(s) > Primary Key Column 1 > <span style="font-family: Courier New, Courier, monospace;">EMPNO</span></li>
<li>Run through the rest of the wizard.</li>
</ul>
<div>
<br /></div>
</div>
<h4>
<span style="font-weight: normal;">Remove Automatic DML</span></h4>
<div>
<div>
Since custom code will be used to process the page, delete the automatic row processing process as shown below.</div>
</div>
<div>
<br /></div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjwRVhec7QECxQ5xBsbp7VNlwxIuTQCQUmEpjo8kupli0sS_jQKgjeH4_3GOIG4HyJzba1ASzgAZ6Htr6zgx9Jo9SICvisiugTnHi1wsLCVLFVl6EkecRUjdPXKWWbgomlTNj5srI12QkW0/s1600/Snip20150819_5.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="400" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjwRVhec7QECxQ5xBsbp7VNlwxIuTQCQUmEpjo8kupli0sS_jQKgjeH4_3GOIG4HyJzba1ASzgAZ6Htr6zgx9Jo9SICvisiugTnHi1wsLCVLFVl6EkecRUjdPXKWWbgomlTNj5srI12QkW0/s400/Snip20150819_5.png" width="318" /></a></div>
<div>
<br /></div>
<h4>
<span style="font-weight: normal;">Create Process</span></h4>
<div>
Create a new process with the following settings (the <i>Source</i> is included below the image).</div>
<div>
<br /></div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8z2dIiZ5Wrf678wwsaoOIWcs-J9iQzZ4CeijzLvnCDSfSmsRh-NDW61mouCMleadsiUf10pfH5eNBP1iEC4Lh547vMCOVfMN2MkAcvgTOFusVXJF7RygDITyo3yrMBq_dyOs60DJ5lc-2/s1600/Snip20150819_7.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="400" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8z2dIiZ5Wrf678wwsaoOIWcs-J9iQzZ4CeijzLvnCDSfSmsRh-NDW61mouCMleadsiUf10pfH5eNBP1iEC4Lh547vMCOVfMN2MkAcvgTOFusVXJF7RygDITyo3yrMBq_dyOs60DJ5lc-2/s400/Snip20150819_7.png" width="286" /></a></div>
<div>
<pre class="brush: sql;">if :empno is null then
-- code to insert emp
null;
else
update emp
set
ename = :ename,
sal = :sal
where empno = :empno;
end if;
</pre>
<div>
<br />
<br />
Using the above technique you can now use a tabular form to call custom PL/SQL code rather than the automatic row processing.</div>
<div>
<br /></div>
<div>
The <a href="http://www.talkapex.com/2015/09/custom-code-for-tabular-forms-part-2.html">next article</a> will cover how to modify data from multiple tables in the same Tabular Form.</div>
</div>
Martin D'Souzahttp://www.blogger.com/profile/06992954599899886499noreply@blogger.com7tag:blogger.com,1999:blog-2132893136140848212.post-49995664161103773512015-09-13T20:40:00.002-06:002015-09-13T21:19:37.201-06:00Report with Checkboxes (an update)Supposed you have a report with checkboxes. Once the user selects all the rows, they can submit the page and the application would process the rows. Sounds pretty simple and straight forward however they're some additional requirements:<br />
<br />
- The report is an Interactive Report<br />
- There may be up to 10,000 records in the report<br />
- When the user "scrolls" through the report (i.e. uses pagination), if they checked off a box it should remain checked the entire time (i.e. if they check an row in the 1st 15 rows, then view rows 16~30, then go back to rows 1~15 it should remain checked). Same applies if a user uses the IR filters.<br />
<br />
<i>If you follow this blog and the above sounds familiar, that's because it is. I <a href="http://www.talkapex.com/2009/01/apex-report-with-checkboxes-advanced.html" target="_blank">wrote about this problem</a> a very long time ago. A lot has changed since 2009 and an update on the original post is long overdue. Here's the updated (and simplified) solution.</i><br />
<i><br /></i>
<br />
<h4>
<span style="font-weight: normal;">Create Item to Hold List of IDs</span></h4>
<br />
Create a hidden APEX item which will contain a comma delimited list of all the IDs that are to be checked off (in this example it will be <span style="font-family: Courier New, Courier, monospace;">P1_EMPNO_LIST</span><i>)</i>. <b>Be sure to modify the <i>Value Protected</i> attribute to <i>No</i></b>. This is critical as this item will be updated via AJAX and can not have any hashing/security applied to it.<br />
<br />
If you are loading this from a cross reference table you can use the following query in a Before Header process. This query will load all the employees from the Accounting department.<br />
<pre class="brush: sql;">select listagg(e.empno, ',') within group (order by e.empno)
from dept d, emp e
where 1=1
and e.deptno = d.deptno
and d.dname = 'ACCOUNTING'
</pre>
<h4>
<span style="font-weight: normal;">Create IR Report with Checkboxes</span></h4>
<b><br /></b>
Create an IR with the query below. Note the <span style="font-family: Courier New, Courier, monospace;">p_attributes</span> value. This is critical as we need to identify the checkboxes that should be monitored.<br />
<pre class="brush: sql;">select
apex_item.checkbox2(
p_idx => 1,
p_value => e.empno ,
p_attributes => 'class="empno"',
p_checked_values => :p1_empno_list,
p_checked_values_delimiter => ',') checkbox,
e.ename,
e.job
from emp e
</pre>
In the report attributes set the <i>Page Items to Submit</i> to <span style="font-family: Courier New, Courier, monospace;">P1_EMPNO_LIST</span>. Each time the report is refreshed (pagination, filters, sorting, etc) the active list of selected values will be submitted.<br />
<br />
<h4>
<span style="font-weight: normal;">Create Dynamic Action (DA)</span></h4>
<div>
<br /></div>
<div>
Create a new DA with the attributes in the below image. This DA will append/remove the comma delimited list of IDs in <span style="font-family: Courier New, Courier, monospace;">P1_EMPNO_LIST</span>. Note the <i>jQuery Selector</i> value must match what was used in the IR query above.</div>
<div>
<br /></div>
<div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh-KPYYfJsgNPNM_igkaRYwLsTX9hg1FEWmoPHVYNtBDP8EFX5YLvD2BE_TZnnAbCrxhhuI36TSKB0_-kVMdevhmDZM48H9okt7fPr5_fkjPO2fPDYhAbtYNbmeXQKAk0iP5alCEAGpfe0E/s1600/Snip20150913_1.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="292" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh-KPYYfJsgNPNM_igkaRYwLsTX9hg1FEWmoPHVYNtBDP8EFX5YLvD2BE_TZnnAbCrxhhuI36TSKB0_-kVMdevhmDZM48H9okt7fPr5_fkjPO2fPDYhAbtYNbmeXQKAk0iP5alCEAGpfe0E/s320/Snip20150913_1.png" width="320" /></a></div>
<br /></div>
<div>
Configure a True action as shown below (JS code follows).</div>
<div>
<br /></div>
<div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhahpRZLo790T_mh_4nGGZZDGbYRvD49mQK7OwBojtc2qkUOQFp2KUpCJKIE7LTTsxa_foOU7I4MvwqlM3rq-1bBuMsPe98E6Bgq58YibVOiY8G5hUFASCBBNaJfS183wKc10zpj3Kxj9QY/s1600/Snip20150913_3.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="400" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhahpRZLo790T_mh_4nGGZZDGbYRvD49mQK7OwBojtc2qkUOQFp2KUpCJKIE7LTTsxa_foOU7I4MvwqlM3rq-1bBuMsPe98E6Bgq58YibVOiY8G5hUFASCBBNaJfS183wKc10zpj3Kxj9QY/s400/Snip20150913_3.png" width="276" /></a></div>
</div>
<div>
<pre class="brush: js;">var
//Checkbox that was changed
$checkBox = $(this.triggeringElement),
//DOM object for APEX Item that holds list.
apexItemIDList = apex.item(this.affectedElements.get(0)),
//Convert comma list into an array or blank array
//Note: Not sure about the "?" syntax see: http://www.talkapex.com/2009/07/javascript-if-else.html
ids = apexItemIDList.getValue().length === 0 ? [] : apexItemIDList.getValue().split(','),
//Index of current ID. If it's not in array, value will be -1
idIndex = ids.indexOf($checkBox.val())
;
//If box is checked and it doesn't already exist in list
if ($checkBox.is(':checked') && idIndex < 0) {
ids.push($checkBox.val());
}
//If box is unchecked and it exists in list
else if (!$checkBox.is(':checked') && idIndex >= 0){
ids.splice(idIndex, 1);
}
//Convert array back to comma delimited list
apexItemIDList.setValue(ids.join(','));
</pre>
<br /></div>
<h4>
<span style="font-weight: normal;">Demo</span></h4>
<div>
<br /></div>
<div>
That's all that's required. Now each time a checkbox is checked/unchecked <span style="font-family: Courier New, Courier, monospace;">P1_EMPNO_LIST</span> will be updated to reflect these changes. The checkboxes will persist each time the report is refreshed. You can see the checkbox implantation in <a href="https://apex.oracle.com/pls/apex/f?p=16406:1400">this demo</a>.</div>
<div>
<br /></div>
<h4>
<span style="font-weight: normal;">Considerations</span></h4>
<div>
<br /></div>
<div>
This solution is fairly simple to create an manage however it does have one small caveat. If the list of checked items is very large (more than 4000 characters) you may run into some <span style="font-family: Courier New, Courier, monospace;">varchar2</span> issues. In most cases this shouldn't be an issue but if it is you should test first.</div>
<div>
<br /></div>
<div>
To process the list of comma delimited list you can use the <span style="font-family: Courier New, Courier, monospace;"><a href="https://docs.oracle.com/cd/E59726_01/doc.50/e39149/apex_util.htm#AEAPI185">apex_util.string_to_table</a></span> function and loop over the table values. If you want to use the comma delimited list in a query the following example should work (again it does have <span style="font-family: Courier New, Courier, monospace;">varchar2</span> size limitations).</div>
<pre class="brush: sql;">select regexp_substr(:p1_empno_list,'[^,]+', 1, level) empno
from dual
connect by regexp_substr(:p1_empno_list, '[^,]+', 1, level) is not null
</pre>
Martin D'Souzahttp://www.blogger.com/profile/06992954599899886499noreply@blogger.com17tag:blogger.com,1999:blog-2132893136140848212.post-66792319110817140262015-08-15T06:23:00.001-06:002015-08-15T06:23:41.096-06:00Oracle Developer Choice Awards - 1 Week Left to NominateOracle has launched its inaugural <a href="https://community.oracle.com/community/database/awards/overview" target="_blank">Developer Choice Awards</a>. The deadline to nominate someone has been extended to August 21st so take advantage of this extension and nominate someone you think deserves recognition for the work they do with Oracle!<br />
<br />
A description of the competition is below and you can find out more by going to the main site.<br />
<br />
<i>The Oracle Database Developer Choice Awards celebrate and recognize technical expertise and contributions in the Oracle Database community. As longtime and new users of Oracle Database move to the Cloud and take advantage of this exciting new architecture, community experts will play a critical role in helping them succeed.</i><br />
<br />
<i>For 2015, awards will be given out in the following technology areas:</i><br />
<br />
<ul>
<li><i>SQL</i></li>
<li><i>PL/SQL</i></li>
<li><i>Oracle REST Data Services</i></li>
<li><i>Oracle Application Express</i></li>
<li><i>Database Design</i></li>
</ul>
<br />
<i>We encourage you to nominate a developer you believe is deserving of this award. We are accepting nominations through August 21. A panel of judges, composed of Oracle ACEs and Oracle employees, will then choose a set of finalists.</i><br />
<br />
<i>But who chooses the winners? You do! The worldwide Oracle technologist community votes on the finalists from September 15 through October 15.</i><br />
<br />
<i>The winners of the Oracle Database Developer Choice Awards will be announced at the YesSQL! Celebration during Oracle OpenWorld 2015.</i><br />
<i><br /></i>
<i>This is your chance to shine and earn highly deserved recognition for yourself or your respected peers.</i>Martin D'Souzahttp://www.blogger.com/profile/06992954599899886499noreply@blogger.com0tag:blogger.com,1999:blog-2132893136140848212.post-56122452103144793132015-08-10T13:28:00.003-06:002015-08-11T15:16:59.188-06:00APEX Meetup - Montreal this Thursday!<i>Note: The location for the Meetup has moved. Please check the <a href="http://www.meetup.com/fr/orclapex-MTL/events/224538959/" target="_blank">meetup page</a> for the new location.</i><br />
<br />
For those in Montreal, I'll be presenting at the local #orclapex meetup this Thursday, August 13, evening from 5-7. All the information can be found on the <a href="http://www.meetup.com/fr/orclapex-MTL/events/224538959/" target="_blank">meetup page</a>.<br />
<br />
<br />
<b>Top 10 APEX API</b><br />
<br />
<i>APEX has a lot of excellent APIs. These APIs, for both PL/SQL and JavaScript, can help extend your application and improve your development. This presentation will cover some of the most useful APIs (both documented and undocumented) that are available.</i><br />
<br />
<br />
The presentation will be in English however I can take questions in both French and English.<br />
<br />
I look forward to meeting the Montreal APEX community!<br />
<br />
- MartinMartin D'Souzahttp://www.blogger.com/profile/06992954599899886499noreply@blogger.com0tag:blogger.com,1999:blog-2132893136140848212.post-22026512404585046182015-07-29T06:30:00.000-06:002015-07-31T00:00:15.402-06:00APEX and the Order Items are Submitted<i>This is the last post in a multi-part series on how APEX submits and processes input elements from your browser to the server. The goal is to understand the effects of moving elements around the page. </i><i>It is important to read these articles in the following order.</i><br />
<i><br /></i><i>- <a href="http://www.talkapex.com/2015/07/back-to-basics-html-form.html">Back to Basics</a></i><br />
<i>- <a href="http://www.talkapex.com/2015/07/apex-and-html-form.html">APEX and the HTML Form</a></i><br />
<i>- <a href="http://www.talkapex.com/2015/07/apex-and-order-items-are-submitted.html">APEX and the Order Items are Submitted</a></i><br />
- <a href="http://hardlikesoftware.com/weblog/2015/07/30/apex-item-submission/"><i>Why does APEX do this? (by John Snyders)</i></a><br />
<br />
The goal of this article is to highlight the effects of moving items and regions around on a page. This article will be broken into four sections, a high level recap from the previous two articles, moving an APEX item, moving an APEX item along with its corresponding <span style="font-family: Courier New, Courier, monospace;">p_arg_names</span> element, and finally a conclusion. It will reference and build upon the example from the <a href="http://www.talkapex.com/2015/07/apex-and-html-form.html">previous article</a>.<br />
<br />
<h3>
<b>Recap</b></h3>
I can't stress enough how important it is to read the previous two articles. To recap, when APEX submits the page it'll use the following values to map the HTML elements to their corresponding APEX items.<br />
<br />
<b><span style="font-family: Courier New, Courier, monospace;">APEX Item ID | APEX Item | Element Name<!-----><!-----><!-----></span></b><br />
<span style="font-family: Courier New, Courier, monospace;">p_arg_names[1] | P1_FIRST_NAME | p_t01<!-----><!-----><!-----></span><br />
<span style="font-family: Courier New, Courier, monospace;">p_arg_names[2] | P1_LAST_NAME | p_t02</span><br />
<span style="font-family: Courier New, Courier, monospace;"><br /></span>
<br />
<h3>
Moving APEX items</h3>
<div>
They're some times where it is required to move APEX items around the page after it has rendered. This example will highlight what happens when an item (and only the item) is moved.</div>
<div>
<br /></div>
<div>
Using the example from the <a href="http://www.talkapex.com/2015/07/apex-and-html-form.html">previous article</a> suppose you move <span style="font-family: Courier New, Courier, monospace;">P1_LAST_NAME</span> before <span style="font-family: Courier New, Courier, monospace;">P1_FIRST_NAME</span> using jQuery. </div>
<pre class="brush: js;">$('#P1_LAST_NAME').insertBefore('#P1_FIRST_NAME');
</pre>
<br />
The page will look like:<br />
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjG6Ez35CWI5UXNLXHsh2khowGWWlZ517qb7EzL42vh9iJMGWy3aTQQe19tLQ22bQugxNgOwLPiG-nLYtMc6CuxCnftDm50Qp714OLKWMvdaa4wBaHldh74jJfuocSjVSbhcwYNS19M41nl/s1600/Snip20150724_9.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="90" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjG6Ez35CWI5UXNLXHsh2khowGWWlZ517qb7EzL42vh9iJMGWy3aTQQe19tLQ22bQugxNgOwLPiG-nLYtMc6CuxCnftDm50Qp714OLKWMvdaa4wBaHldh74jJfuocSjVSbhcwYNS19M41nl/s400/Snip20150724_9.png" width="400" /></a></div>
<br />
When the page is submitted, everything still works as expected. <span style="font-family: Courier New, Courier, monospace;">P1_FIRST_NAME = Martin</span> and <span style="font-family: Courier New, Courier, monospace;">P2_LAST_NAME = D'Souza</span>. In this case, it was safe to the move the item around the page since only the <span style="font-family: Courier New, Courier, monospace;">p_t02</span> element was moved. The order of <span style="font-family: Courier New, Courier, monospace;">p_arg_names</span> (which APEX uses to map to <span style="font-family: Courier New, Courier, monospace;">apex_application_page_items.item_id</span> an <span style="font-family: Courier New, Courier, monospace;">p_txx</span>) was not changed.<br />
<br />
<h3>
Moving an APEX item along with its corresponding <span style="font-family: Courier New, Courier, monospace;">p_arg_names</span> element.</h3>
Using the previous example, suppose the items were split up into two regions as shown below. To help out, each region has been assigned a static id of <span style="font-family: Courier New, Courier, monospace;">region-one</span> and <span style="font-family: Courier New, Courier, monospace;">region-two</span> respectively.<br />
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhbc2jIkGXfJSpskfVN1g-tJHwPZSfcDXKvQzPnU6WcqBcRy4ZTo12IwmGuOhLND-HFwvg7uEE4w0u7qyQmmgiGxsJBosj82HgNSFaHsEeIpN41y0SH-dCzMfJe0fjXtKzDF7qxH2beqc8c/s1600/Snip20150724_10.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="215" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhbc2jIkGXfJSpskfVN1g-tJHwPZSfcDXKvQzPnU6WcqBcRy4ZTo12IwmGuOhLND-HFwvg7uEE4w0u7qyQmmgiGxsJBosj82HgNSFaHsEeIpN41y0SH-dCzMfJe0fjXtKzDF7qxH2beqc8c/s320/Snip20150724_10.png" width="320" /></a></div>
<br />
Using the following code, Region Two is moved above Region One:<br />
<pre class="brush: js;">$('#region-two').insertBefore('#region-one');
</pre>
<br />
The screen then looks like:<br />
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjoMSjyjsftQH9UKfq20VyTRz84xfxFLOL__Us22TWODzc4k0olUe5k6EWjUmtgw9KEBr0U-fG2q_XeRfxo_wRAV8R_S5bhBAA3vrwMMeXBVFaXfM_TPV4MJ-8rTZ3BPIwnzmMduawxfsNs/s1600/Snip20150725_11.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="196" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjoMSjyjsftQH9UKfq20VyTRz84xfxFLOL__Us22TWODzc4k0olUe5k6EWjUmtgw9KEBr0U-fG2q_XeRfxo_wRAV8R_S5bhBAA3vrwMMeXBVFaXfM_TPV4MJ-8rTZ3BPIwnzmMduawxfsNs/s320/Snip20150725_11.png" width="320" /></a></div>
<br />
Referring to the <a href="http://www.talkapex.com/2015/07/apex-and-html-form.html">previous article</a> not only has the input element for <span style="font-family: Courier New, Courier, monospace;">P1_LAST_NAME</span> moved, but it's corresponding <span style="font-family: Courier New, Courier, monospace;">p_arg_names</span> hidden element was moved and its overall order has changed. Now when the page is submitted the following is sent to the server (note the order):<br />
<br />
<span style="font-family: Courier New, Courier, monospace;">p_arg_names[1] = 32629863123858907 - Maps to APEX item P1_LAST_NAME</span><br />
<span style="font-family: Courier New, Courier, monospace;">p_arg_names[2] = 32629789701858906 - Maps to APEX item P1_FIRST_NAME</span><br />
<span style="font-family: Courier New, Courier, monospace;"><br /></span>
<span style="font-family: Courier New, Courier, monospace;">p_t01 = Martin</span><br />
<span style="font-family: Courier New, Courier, monospace;">p_t02 = D'Souza</span><br />
<br />
Just to recap and highlight what is about to happen:<br />
<br />
<span style="font-family: Courier New, Courier, monospace;">p_arg_names[<b>1</b>] (P1_LAST_NAME) maps to p_t0<b>1</b> (Martin)</span><br />
<span style="font-family: Courier New, Courier, monospace;">p_arg_names[<b>2</b>] (P1_FIRST_NAME) maps to p_t0<b>2</b> (D'Souza)</span><br />
<br />
You can see the mis-match occur below once the page has been submitted. <span style="font-family: Courier New, Courier, monospace;">Martin</span> is stored in <span style="font-family: Courier New, Courier, monospace;">P1_LAST_NAME</span> and <span style="font-family: Courier New, Courier, monospace;">D'Souza</span> is stored in <span style="font-family: Courier New, Courier, monospace;">P1_FIRST_NAME</span>.<br />
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8vUCgPxkExvV1wluKhyuq8arwCrhUB2ADvDlFKOEdmdCD7hZwhdMvU9-kY4UFNmoSOacsrBBB6mNeJi3XrSXip9x6p5H6g1V5tNy3dUirC1wFYPdw41fnsdwfGjYS_SHcPjyJO-q_R8zG/s1600/Snip20150725_12.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="196" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8vUCgPxkExvV1wluKhyuq8arwCrhUB2ADvDlFKOEdmdCD7hZwhdMvU9-kY4UFNmoSOacsrBBB6mNeJi3XrSXip9x6p5H6g1V5tNy3dUirC1wFYPdw41fnsdwfGjYS_SHcPjyJO-q_R8zG/s320/Snip20150725_12.png" width="320" /></a></div>
<h3>
Conclusion</h3>
Be very careful when moving APEX items around the page. As a guideline, it's usually safe to move individual items, provided you're not moving any <span style="font-family: Courier New, Courier, monospace;">p_arg_names</span> hidden elements. If you're moving a region and/or any <span style="font-family: Courier New, Courier, monospace;">p_arg_names</span> elements you may get invalid data assignments if the order of <span style="font-family: Courier New, Courier, monospace;">p_arg_names</span> is changed.<br />
<br />
This issue was first discussed a very long time ago between myself and <a href="https://twitter.com/dmcghan">Dan McGhan</a> on the Oracle Forums: <a href="https://community.oracle.com/message/3182532">https://community.oracle.com/message/3182532</a>Martin D'Souzahttp://www.blogger.com/profile/06992954599899886499noreply@blogger.com3tag:blogger.com,1999:blog-2132893136140848212.post-74955198716194224242015-07-28T06:30:00.000-06:002015-07-30T09:40:20.987-06:00APEX and the HTML Form<i>This is the second post in a multi-part series on how APEX submits and processes input elements from your browser to the server. The goal is to understand the effects of moving elements around the page. </i><i>It is important to read these articles in the following order.</i><br />
<i><br /></i><i>- <a href="http://www.talkapex.com/2015/07/back-to-basics-html-form.html">Back to Basics</a></i><br />
<i>- <a href="http://www.talkapex.com/2015/07/apex-and-html-form.html">APEX and the HTML Form</a></i><br />
<i>- <a href="http://www.talkapex.com/2015/07/apex-and-order-items-are-submitted.html">APEX and the Order Items are Submitted</a></i><br />
- <a href="http://hardlikesoftware.com/weblog/2015/07/30/apex-item-submission/"><i>Why does APEX do this? (by John Snyders)</i></a><br />
<br />
The goal of this article is to highlight how APEX actually processes the data that is sent data from the browser to the server when a submit button is pressed.<br />
<br />
Suppose you have a simple page with two elements: <span style="font-family: Courier New, Courier, monospace;">P1_FIRST_NAME</span> and <span style="font-family: Courier New, Courier, monospace;">P1_LAST_NAME</span> as shown below:<br />
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgXf_uciKi4TiJlbSapfOc-xUgAUeQFzU2xHsIRh8nJrbeIYlyVuWT3KgS-Hffn5DqJOipcYmuhH0-TIbm_F0WI_xQl6L60onuH406BJWpLcRKinaX4SmwiSq5xVVlbiMkoRNNN8uw8Jp9y/s1600/Snip20150724_7.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="108" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgXf_uciKi4TiJlbSapfOc-xUgAUeQFzU2xHsIRh8nJrbeIYlyVuWT3KgS-Hffn5DqJOipcYmuhH0-TIbm_F0WI_xQl6L60onuH406BJWpLcRKinaX4SmwiSq5xVVlbiMkoRNNN8uw8Jp9y/s320/Snip20150724_7.png" width="320" /></a></div>
<div class="separator" style="clear: both; text-align: center;">
<br /></div>
Stripping out a lot code, the underlying HTML code for this page looks like:<br />
<pre class="brush: html;"><form action="wwv_flow.accept" id="wwvFlowForm" method="post" name="wwv_flow">
<input name="p_arg_names" type="hidden" value="32629789701858906" />
<input id="P1_FIRST_NAME" name="p_t01" type="text" value="" />
<input name="p_arg_names" type="hidden" value="32629863123858907" />
<input id="P1_LAST_NAME" name="p_t02" type="text" value="" />
</form>
</pre>
You'll notice that despite their being four input elements they're really only three unique sets of names that are used: <span style="font-family: Courier New, Courier, monospace;">p_arg_names, p_t01,</span> and <span style="font-family: Courier New, Courier, monospace;">p_t02</span>. When the page is submitted the web server (APEX) will get/processes the following elements:<br />
<br />
<span style="font-family: Courier New, Courier, monospace;">p_arg_names[1] = 32629789701858906</span><br />
<span style="font-family: Courier New, Courier, monospace;">p_arg_names[2] = 32629863123858907</span><br />
<span style="font-family: Courier New, Courier, monospace;"><br /></span>
<span style="font-family: Courier New, Courier, monospace;">p_t01 = Martin </span><br />
<span style="font-family: Courier New, Courier, monospace;">p_t02 = D'Souza</span><br />
<br />
None of the data sent back to the server make reference of <span style="font-family: Courier New, Courier, monospace;">P1_FIRST_NAME</span> or <span style="font-family: Courier New, Courier, monospace;">P2_LAST_NAME</span>. As well, <span style="font-family: Courier New, Courier, monospace;">p_arg_names</span> is stored in a top down order of how they are in the page.<br />
<br />
<span style="font-family: Courier New, Courier, monospace;">p_arg_names</span> values are actually the IDs for each of the of the page items as highlighted in the following query:<br />
<pre class="brush: sql;">select item_id, item_name
from apex_application_page_items
where 1=1
and application_id = 118
and page_id = 1;
ITEM_ID ITEM_NAME
----------------- -------------
32629789701858906 P1_FIRST_NAME
32629863123858907 P1_LAST_NAME
</pre>
APEX is able to map the data back to their corresponding APEX items by first mapping the values in <span style="font-family: Courier New, Courier, monospace;">p_arg_names</span> to the <span style="font-family: Courier New, Courier, monospace;">apex_application_page_items</span> view and then using the values in the <span style="font-family: Courier New, Courier, monospace;">p_txx</span> to retrieve the data that was submitted for each item.<br />
<br />
The order that the values are submitted in for <span style="font-family: Courier New, Courier, monospace;">p_arg_names</span> must match the <span style="font-family: Courier New, Courier, monospace;">p_txx</span> values for APEX to correctly map the values to their appropriate APEX item. I.e. <span style="font-family: Courier New, Courier, monospace;">p_args_names[<b>1</b>]</span> will link to <span style="font-family: Courier New, Courier, monospace;">p_t0<b>1</b></span> and <span style="font-family: Courier New, Courier, monospace;">p_arg_names[<b>2</b>]</span> will link to <span style="font-family: Courier New, Courier, monospace;">p_t0<b>2</b></span> etc.Martin D'Souzahttp://www.blogger.com/profile/06992954599899886499noreply@blogger.com0tag:blogger.com,1999:blog-2132893136140848212.post-72630291130120840782015-07-27T06:30:00.000-06:002015-07-30T09:40:09.179-06:00Back to Basics: The HTML Form<i>This is the first post in a multi-part series on how APEX submits and processes input elements from your browser to the server. The goal is to understand the effects of moving elements around the page. </i><i>It is important to read these articles in the following order.</i><br />
<i><br /></i>
<i>- <a href="http://www.talkapex.com/2015/07/back-to-basics-html-form.html">Back to Basics</a></i><br />
<i>- <a href="http://www.talkapex.com/2015/07/apex-and-html-form.html">APEX and the HTML Form</a></i><br />
<i>- <a href="http://www.talkapex.com/2015/07/apex-and-order-items-are-submitted.html">APEX and the Order Items are Submitted</a></i><br />
- <a href="http://hardlikesoftware.com/weblog/2015/07/30/apex-item-submission/"><i>Why does APEX do this? (by John Snyders)</i></a><br />
<i><br /></i>
As the above note suggests, the next few articles will cover how APEX submits and processes input elements in a page. This article is specifically focused on the basics: HTML forms. It's important to understand how the HTML <span style="font-family: Courier New, Courier, monospace;">form</span> tag works and posts input elements. They're other articles that cover this in much more detail and this article will only cover the high level concepts.<br />
<br />
Any web page that submits data to it has the following structure:<br />
<pre class="brush: html;"><form action="submitURL" method="post">
First name: <input id="foo" name="firstname" type="text" />
Last Name: <input id="bar" name="lastname" type="text" />
<input type="submit" />
</form>
</pre>
This will produce a page that looks like:<br />
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi-Qn6cevdgiTAqWrcE4ZflGlPAOgv9MFK6w-v-FfDDD19XbyRL9wI54lMlrdt4VC_-ANcnUnTtndVix7SVLAozcclQY9Lm9okhote1YiQMvIxa4E6tVY4SA22OZxwjjv-l3MGZjMRBB9Ql/s1600/Snip20150724_4.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi-Qn6cevdgiTAqWrcE4ZflGlPAOgv9MFK6w-v-FfDDD19XbyRL9wI54lMlrdt4VC_-ANcnUnTtndVix7SVLAozcclQY9Lm9okhote1YiQMvIxa4E6tVY4SA22OZxwjjv-l3MGZjMRBB9Ql/s1600/Snip20150724_4.png" /></a></div>
When the page is submitted the following is sent to the server:<br />
<br />
<span style="font-family: Courier New, Courier, monospace;">firstname = Martin</span><br />
<span style="font-family: Courier New, Courier, monospace;">lastname = D'Souza</span><br />
<br />
Despite what most developers think, the element's IDs (in this case <span style="font-family: Courier New, Courier, monospace;">foo</span> and <span style="font-family: Courier New, Courier, monospace;">bar</span>) are not submitted to the server. The server never sees/knows about them. Instead it must use the element's <span style="font-family: Courier New, Courier, monospace;">name</span> attribute.<br />
<br />
HTML form behaviour has another nice feature that allows for the same name to be used multiple times. Modifying the previous example, the next example will use the name <span style="font-family: Courier New, Courier, monospace;">person</span> for both the first and last name elements:<br />
<pre class="brush: html;"><form action="submitURL" method="post">
First name: <input id="foo" name="person" type="text" />
Last Name: <input id="bar" name="person" type="text" />
<input type="submit" />
</form>
</pre>
Now when submitting the page the following is sent to the server:<br />
<br />
<span style="font-family: Courier New, Courier, monospace;">person[1] = Martin</span><br />
<span style="font-family: Courier New, Courier, monospace;">person[2] = D'Souza</span><br />
<br />
The server processes the <span style="font-family: Courier New, Courier, monospace;">person</span> attribute as an array of data. Using pseudo code, this is how a web server scripting language may process the data:<br />
<br />
<span style="font-family: Courier New, Courier, monospace;">...</span><br />
<span style="font-family: Courier New, Courier, monospace;">firstName = htmlForm.person[1];</span><br />
<span style="font-family: Courier New, Courier, monospace;">lastName = htmlForm.person[2];</span><br />
<span style="font-family: Courier New, Courier, monospace;">...</span><br />
<br />
The two key items to take away from this article are:<br />
<br />
- When elements are submitted, only the <span style="font-family: Courier New, Courier, monospace;">name</span> attribute is sent to the web server and is used to reference the element.<br />
- A form can contain multiple elements with the same name. In this case the web server will view them as an array of data.Martin D'Souzahttp://www.blogger.com/profile/06992954599899886499noreply@blogger.com0tag:blogger.com,1999:blog-2132893136140848212.post-85230904933953623392015-06-08T08:18:00.000-06:002015-06-08T08:18:37.802-06:00A New ChapterI'm please to announce that starting in July I will be joining <a href="http://insum.ca/">Insum</a> as a Senior Technical Consultant! I'm really excited to be joining their team which specializes in Oracle and APEX solutions.<br />
<br />
A bit about Insum:<br />
<br />
"<i>Insum is a highly creative solution center specialized in Oracle Database, developing innovative applications for clients and partners in North America. Founded in 2002, Insum has been assisting customers realize the full benefits of Oracle Database with Application Express since 2005. In fact, Insum is a pioneer with APEX and is today the largest consultancy specialized in Oracle APEX developments in North America. Privately held with offices in Montreal, Canada and South Burlington, USA, Insum has the most complete and experienced staff to serve the needs for complex application development and deployments in a wide range of industries. Come discover our unique APEX center of excellence</i>"<br />
<br />
- MartinMartin D'Souzahttp://www.blogger.com/profile/06992954599899886499noreply@blogger.com3tag:blogger.com,1999:blog-2132893136140848212.post-19838027508673638452015-05-21T08:30:00.000-06:002015-05-21T08:30:01.072-06:00APEX Meetups - CalgaryOne of the popular things these days in the APEX community is to have localized <a href="http://apexmeetups.com/">APEX Meetups</a>. These are usually monthly meetings where one, or a few, people give a presentation about APEX. These are a lot more informal than traditional conferences and help the community grow in a given area.<br />
<br />
I recently launched the Calgary APEX Meetup group: <a href="http://www.meetup.com/orclapex-YYC/">ORCLAPEX-YYC</a>. If you live in or around Calgary and are interested in getting together once a month to hear more about APEX join this group! The plan is to host our first Meetup in early June and are currently looking for a venue to host us. If you can acquire some space please leave a comment on the <a href="http://www.meetup.com/orclapex-YYC/messages/boards/thread/48970051">discussion board</a>.<br />
<br />
We're looking to keep these events free and are always looking for sponsors to help fund some of the small costs. If you or your organization is interested please leave a comment on the <a href="http://www.meetup.com/orclapex-YYC/messages/boards/thread/48970066">discussion board</a>.Martin D'Souzahttp://www.blogger.com/profile/06992954599899886499noreply@blogger.com0tag:blogger.com,1999:blog-2132893136140848212.post-62847600478771463922015-05-18T08:59:00.000-06:002015-05-18T08:59:53.625-06:00SQLcl and login.sqlIn SQL*Plus you can configure it to automatically run login scripts, typically used to configure your session. These are stored in the files <span style="font-family: Courier New, Courier, monospace;">glogin.sql</span> and <span style="font-family: Courier New, Courier, monospace;">login.sql</span>. Some examples that you'd find in these files are statements like: <span style="font-family: Courier New, Courier, monospace;">set serveroutput on</span>. You can read more about login scripts <a href="http://www.adp-gmbh.ch/ora/sqlplus/login.html">here</a>.<br />
<br />
SQLcl also handles login scripts, however it may require some additional configuration. The easiest way to leverage this is to create a file called <span style="font-family: Courier New, Courier, monospace;">login.sql</span> in your current directory, then call SQLcl from that directory.<br />
<br />
If you're like me and launch SQLcl from many directories that approach won't work. Instead, you can create one <span style="font-family: Courier New, Courier, monospace;">login.sql</span> file and have it automatically referenced. To do this create <span style="font-family: Courier New, Courier, monospace;">login.sql</span> in a folder (in my case it was <span style="font-family: Courier New, Courier, monospace;">~/Documents/Oracle</span>) and then add the following to <span style="font-family: Courier New, Courier, monospace;">~/.bash_profile</span>: <span style="font-family: Courier New, Courier, monospace;">export SQLPATH=~/Documents/Oracle/</span><br />
<span style="font-family: Courier New, Courier, monospace;"><br /></span>
<span style="font-family: inherit;">Now when you run SQLcl anywhere it will reference your </span><span style="font-family: Courier New, Courier, monospace;">login.sql</span><span style="font-family: inherit;"> file.</span><br />
<span style="font-family: Courier New, Courier, monospace;"><br /></span>
<i><span style="font-family: inherit;">Thanks to <a href="https://twitter.com/krisrice">Kris Rice</a> and <a href="https://twitter.com/thatjeffsmith">Jeff Smith</a> for helping with this.</span></i>Martin D'Souzahttp://www.blogger.com/profile/06992954599899886499noreply@blogger.com1tag:blogger.com,1999:blog-2132893136140848212.post-26155000434434861762015-05-15T09:15:00.000-06:002015-05-15T09:15:34.957-06:00Help Promote LoggerHere's a snippet from a Twitter conversation today between <a href="https://twitter.com/sfonplsql">Steven Feuerstein</a> and I around a user that created their own PL/SQL logging platform:<br />
<br />
<blockquote class="twitter-tweet" data-cards="hidden" data-partner="tweetdeck">
<div dir="ltr" lang="en">
Shameless self-promotion, I know. But it feels so good....I really like to help people. <a href="http://t.co/WW91NDOnN9">http://t.co/WW91NDOnN9</a> <a href="http://t.co/EuigB0cAIO">pic.twitter.com/EuigB0cAIO</a></div>
— Steven Feuerstein (@sfonplsql) <a href="https://twitter.com/sfonplsql/status/599212316161245184">May 15, 2015</a></blockquote>
<script async="" charset="utf-8" src="//platform.twitter.com/widgets.js"></script>
<br />
<blockquote class="twitter-tweet" data-cards="hidden" data-conversation="none" data-partner="tweetdeck">
<div dir="ltr" lang="en">
<a href="https://twitter.com/sfonplsql">@sfonplsql</a> Any reason they’re not using Logger? <a href="https://t.co/Q2BViP914Q">https://t.co/Q2BViP914Q</a></div>
— Martin Giffy D'Souza (@martindsouza) <a href="https://twitter.com/martindsouza/status/599218291849039872">May 15, 2015</a></blockquote>
<script async="" charset="utf-8" src="//platform.twitter.com/widgets.js"></script>
<br />
<blockquote class="twitter-tweet" data-cards="hidden" data-conversation="none" data-partner="tweetdeck">
<div dir="ltr" lang="en">
<a href="https://twitter.com/martindsouza">@martindsouza</a> You haven't done a good enough job promoting it? They don't trust outside code? I don't use it?</div>
— Steven Feuerstein (@sfonplsql) <a href="https://twitter.com/sfonplsql/status/599218493293072385">May 15, 2015</a></blockquote>
<br />
<script async="" charset="utf-8" src="//platform.twitter.com/widgets.js"></script>
Steven is absolutely correct when he says "<i>You haven't done a good enough job promoting it</i>" ("it" being <a href="http://www.oraopensource.com/logger/">Logger</a>). Despite my best efforts, promoting Logger is something I've struggled with and need some help.<br />
<br />
Based on past emails and conversations, I know they're a lot of developers and organizations using Logger. <b>If you're using Logger, either personally or within your organization, I need your help. Please blog about it (and post the link in the comments section below), email me a quote that I can use (martin@clarifit.com), Tweet about it (use <a href="https://twitter.com/hashtag/orcllogger?src=hash">#orcllogger</a>), or mention it at the next conference you go to</b>.<br />
<br />
To those that help promote it, thank you in advance.<br />
<br />
- MartinMartin D'Souzahttp://www.blogger.com/profile/06992954599899886499noreply@blogger.com3