F5 works closely with Oracle to build joint solutions, providing an optimized and secure platform for delivering powerful Oracle apps across the LAN and WAN. Offload resource-intensive tasks like compression and SSL from Oracle WebLogic Server and get faster performance.

Read how. links.f5.com/Sosd0C

Untitled-1 1 12/3/12 11:31 PM JANUARY/FEBRUARY 2013

Roadmaps and Guardrails It’s time to revive the conversation about IT governance / 25 Package Your Code Part 11 in a series of articles on understanding and using PL/SQL / 45 Beginning Performance Tuning: Active Session History Identify the root cause of performance issues at a precise point in the past / 51 Sums, Averages, and Other Grouped Data Part 9 in a series on the basics of the relational database and SQL / 57 On Promotion, Restriction, and Data Loading Our technologist provides missing links, custom sizes, and external table tips / 61

CIO OF THE YEAR ORACLE JAPAN Seiji Nishikawa EXCELLENCE NTT DOCOMO AWARDS CIO OF THE YEAR EUROPE, MIDDLE EAST, 2012 AND AFRICA Honoring leadership and Victor Orlovski innovation in technology Sberbank

CIO OF THE YEAR ASIA PACIFIC Dr. Jung Hee Song SPARC AT 25 KT Corporation Anniversary event explores the past, present, and future of SPARC CIO OF THE YEAR NORTH AMERICA Cormac Lynch ACCELERATED National Oilwell Varco PERFORMANCE With a massive boost in fl ash and CIO OF THE YEAR DRAM, Oracle Exadata X3 delivers LATIN AMERICA faster applications across clouds Leandro Balbinot and consolidated workloads Lojas Renner

CIO OF THE YEAR GLOBAL BUSINESS UNIT Mark Dearnley Vodafone UK

JF13_cover_R2.indd 1 12/13/12 10:57 AM Reach new heights

SPARC64 X: Fujitsu’s latest SPARC processor carrying the inheritance from the world’s top-level supercomputer to provide unprecedented performance and scalability. Fujitsu, together with Oracle, ensures that SPARC systems interoperate well with next generations of , , and Oracle software products.

© Copyright 2012 Fujitsu Limited. Fujitsu, the Fujitsu logo are trademarks or registered trademarks of Fujitsu Limited in Japan and other countries. Other company, product and service names may be trademarks or registered trademarks of their respective owners.

omag1112pCov2_p001.indd 2 10/31/12 1:56 PM Reach new heights

SPARC64 X: Fujitsu’s latest SPARC processor carrying the inheritance from the world’s top-level supercomputer to provide unprecedented performance and scalability. Fujitsu, together with Oracle, ensures that SPARC systems interoperate well with next generations of Oracle Solaris, Oracle Database, and Oracle software products.

© Copyright 2012 Fujitsu Limited. Fujitsu, the Fujitsu logo are trademarks or registered trademarks of Fujitsu Limited in Japan and other countries. Other company, product and service names may be trademarks or registered trademarks of their respective owners.

omag1112pCov2_p001.indd 3 10/31/12 1:55 PM 2 FEATURED CONTENT VOLUME XXVII - ISSUE 1 CONTENTS

2012 ORACLE EXCELLENCE AWARDS /28 Oracle customers and partners continually discover innovative ways to deploy successful, groundbreaking solutions and establish best practices using Oracle technology. The Oracle Excellence Awards recognize customers and partners who have excelled in driving business value together with Oracle. This year, the Oracle Excellence Awards include 12 different award programs—with new programs for 2012—that reach across efforts ranging from leadership and technology to enterprise sustainability and database administration. –By David A. Kelly, with additional reporting by Patty Waddington Cover: Nicholas Pavkovic

SPARC at 25 /18 Extreme Performance with Oracle Exadata X3 /19

In 1987, a small With a massive boost in flash and DRAM, Oracle Exadata startup called Sun X3 delivers faster applications. Juan Loaiza, senior vice Microsystems president of systems technology at Oracle, talks about developed its these and other new developments in Oracle’s engineered own microprocessor, called SPARC, and systems with Tom Haunert, Oracle Magazine editor in chief. introduced the first computer based on the –By Tom Haunert new chip. On November 1, 2012, many early SPARC team members gathered for SPARC at 25: Past, Present, and Future, an event that provided a look back at the history of SPARC as well as a glimpse of what’s to come. –By Diana Reichardt

JANUARY/FEBRUARY 2013 ORACLE.COM/ORACLEMAGAZINE

JF13_TOC_R1.indd 2 12/5/12 9:16 AM Use your programmer's point of view...

WIN!

Win a tablet or choose a 50% discount on PL/SQL Developer! Use your logical skills to find the secret code, go to www.plsqldev.com/code and have a chance to win a new iPad or ASUS TF700! Challenge accepted? Real solutions for Oracle developers.

Closing date: March 1, 2013 4 DEPARTMENTS VOLUME XXVII - ISSUE 1

Up Front / 6

FROM THE EDITOR / 6 MASHUP / 8 Congratulations and News, views, trends, Thanks —Tom Haunert and tools

At Oracle / 11

EVENTS / 11 RESOURCES / 13 BRIEFS / 15 Find out about upcoming Your guide to Oracle The latest product news technology and industry Webcasts, podcasts, white events. papers, and more

Community / 22

PARTNER NEWS / 22 ARCHITECT / 25 UP CLOSE / 26 PEER-TO-PEER / 27 BOOK BEAT / 22 Roadmaps and Guardrails On Code Reviews and Green Is Good It’s time to revive the Standards Peers use performance conversation about IT A user group speaker gives optimization, e-readers, governance. —Bob Rhubart development teams simple and mobile solutions to do ways to succeed. their part. —Blair Campbell —Jeff Erickson

Technology / 45

PL/SQL 101 / 45 TUNING / 51 SQL 101 / 57 ASK TOM / 61 Wrap Your Code in a Neat Beginning Performance Having Sums, Averages, On Promotion, Package Tuning: Active Session and Other Grouped Data Restriction, and Part 11 in a series of articles History Part 9 in a series on the Data Loading on understanding and using Identify the root cause of basics of the relational Our technologist queries PL/SQL —Steven Feuerstein performance issues at a database and SQL missing links, custom sizes, precise point in the past. —Melanie Caffrey and external table tips. —Arup Nanda —Tom Kyte

Comment / 67

IN THE FIELD / 67 TIME CAPSULE / 68 Evolutionary Thinking Flashbacks: Culture. Industry. Is the data scientist the Oracle. Oracle Magazine. next step on the information —Rich Schwerin technology ladder? —John Matelski

JANUARY/FEBRUARY 2013 ORACLE.COM/ORACLEMAGAZINE

JF13_TOC.indd 4 11/30/12 1:43 PM 5

Editorial Publishing Editor in Chief Vice President Tom Haunert [email protected] Jeff Spicer [email protected] Managing Editor Publisher Jan Rogers [email protected] Jennifer Hamilton [email protected] +1.650.506.3794 Senior Editor Audience Development and Operations Director Caroline Kvitka [email protected] Karin Kinnear [email protected] +1.650.506.1985 Associate Editor Patty Waddington Advertising sales Contributing Editor and Writer Associate Publisher Blair Campbell Kyle Walkenhorst [email protected] +1.323.340.8585 Technology Advisor Northwest and Central US Tom Kyte Tom Cometa [email protected] +1.510.339.2403 Contributors Southwest US and LAD Marta Bright, Jeff Erickson, Fred Sandsmark, Rich Schwerin, Leslie Steere Shaun Mehr [email protected] +1.949.923.1660 Northeast US and EMEA/APAC DESIGN Mark Makinney [email protected] +1.805.709.4745 Senior Creative Director Advertising Sales Assistant Francisco G Delgadillo Cindy Elhaj [email protected] +1.626.396.9400, x201 Senior Design Director Mailing-List Rentals Suemi Lam Contact your sales representative. Design Director Richard Merchán Resources Contributing Designers Oracle Products Jaime Ferrand, Nicholas Pavkovic +1.800.367.8674 (US/Canada) Production Designers Oracle Services Sheila Brennan, Kathy Cygnarowicz +1.888.283.0591 Oracle Press Books Editorial Board oraclepressbooks.com Ian Abramson, Karen Cannell, Andrew Clarke, Chris Claterbos, Karthika Devi, Kimberly Floss, Kent Graziano, Taqi Hasan, Tony Jambu, Tony Jedlinski, Copyright © 2013, Oracle and/or its affiliates. All Rights Reserved. No part of this publication Ari Kaplan, Val Kavi, John King, Steve Lemme, Carol McGury, Sumit Sengupta, may be reprinted or other­wise reproduced without permission from the editors. ORACLE MAGAZINE Jonathan Vincenzo, Dan Vlamis IS PROVIDED ON AN “AS IS” BASIS. ORACLE EXPRESSLY DISCLAIMS ALL WARRANTIES, WHETHER EXPRESS OR IMPLIED. IN NO EVENT SHALL ORACLE BE LIABLE FOR ANY DAMAGES Subscription Information OF ANY KIND ARISING FROM YOUR USE OF OR RELIANCE ON ANY INFORMATION PROVIDED Subscriptions are complimentary for qualified individuals who complete the HEREIN. The information is intended to outline our general product direction. It is intended for subscription card found in each issue or online at oracle.com/oraclemagazine. information purposes only, and may not be incorporated into any contract. It is not a commitment For change of address, mail in label with the new address to: Oracle Magazine, to deliver any material, code, or functionality, and should not be relied upon in making purchasing P.O. Box 1263, Skokie, IL 60076-8263. decisions. The development, release, and timing of any features or functionality described for Oracle’s products remains at the sole discretion of Oracle. Oracle and Java are registered trademarks Magazine Customer Service of Oracle and/or its affiliates. Other names may be trademarks of their respective owners. [email protected] Fax +1.847.763.9638 Phone +1.847.763.9635 Oracle Magazine (ISSN 1065-3171) is published bimonthly with a free subscription price by: Oracle, Privacy 500 Oracle Parkway, MS OPL-3C, Redwood City, CA 94065-1600. Periodicals Postage Paid at Oracle Publishing allows sharing of its mailing list with selected third parties. Redwood City, CA, and additional mailing offices. • POSTMASTER: Send address changes to: Oracle If you prefer that your mailing address or e-mail address not be included in this Magazine, P.O. Box 1263, Skokie, IL 60076-8263. program, contact Customer Service at [email protected]. Printed by Brown Printing

Oracle PRODUCT INDEX Product Name Page Product Name Page Product Name Page MySQL 13, 22 Elastic Cloud 13 Oracle Solaris 68 MySQL Cluster 13 Oracle Exalytics 22 Oracle Validated Configurations 14 NetBeans IDE 16 Oracle Identity Governance Suite 16 Oracle VM Templates 15 Oracle ADF Mobile 15 15 Oracle WebCenter 13 Oracle Application Development Framework 22 Oracle Network Applications Platform 15 PeopleSoft applications 16, 22 Oracle Application Express 15 Oracle NoSQL Database 15 SPARC Enterprise M-Series servers 14 Oracle Application Testing Suite 15 Oracle Optimized Solution for Backup and Recovery 14 SPARC processors 18, 68 Oracle Business Intelligence 16 Oracle Optimized Solution for Oracle E-Business Suite 14 SPARC SuperCluster 14, 68 Oracle Database 45, 51, 57, 61 Oracle Optimized Solution for SAP 14 StorageTek Virtual Storage Manager 16 Oracle Enterprise Manager 13, 23 Oracle SOA Suite 22 Sun x86 servers 14 Oracle Exadata X3 19, 68

oracle magazine January/February 2013

JF13_TOC.indd 5 11/30/12 1:43 PM 6 From The Editor

Congratulations and Thanks 2012 Oracle Excellence Awards deliver honors at Oracle OpenWorld.

n October 2, 2012, I presented tro- about how award winners through Ophies for the Oracle Excellence Award the years have used and succeeded for Technologist of the Year at Oracle with Oracle solutions, so thank you to OpenWorld in San Francisco, California. all winners past and present for your I asked Oracle Architect Tom Kyte to join great stories. And, finally, to this year’s me and present the trophies for the new winners, thanks in advance for sharing Oracle Excellence Award for Database your stories with the Oracle community. Administrator of the Year program. Oracle Excellence Awards for 10 other The Issue at Hand awards categories had already been pre- This issue of Oracle Magazine presents sented during the first few days of Oracle and celebrates the winners in all of the OpenWorld, and the October 2 presentation 2012 Oracle Excellence Awards programs, also served as an award reception for winners including the Oracle Excellence Awards for in all 12 Oracle Excellence Awards programs CIO of the Year, Technologist of the Year, and for 2012. Database Administrator of the Year. After Jeb Dasteel, senior vice president Managing nominations, judging, trophy and chief customer officer at Oracle, opened design and delivery, events, publicity, and the reception, I read a few words of my own more across 12 awards programs is no small Next Steps leading into the Technologist of the Year collection of responsibilities. Oracle Global trophy presentations: Customer Programs oversees the 12 Oracle LEARN more about On behalf of Tom Kyte, Oracle architect, Excellence Awards programs, coordinates Oracle Excellence Awards and myself, thank you all for being here. many of these activities, and deserves oracle.com/us/corporate/awards In 2002, Oracle Magazine started much congratulations and thanks for all CIO of the Year an awards program called the Oracle of its efforts. The judging processes vary oracle.com/us/corporate/awards/cio Magazine Editors’ Choice Awards, and across the different awards categories, but Database Administrator of the Year oracle.com/us/corporate/awards/ this originally included the CIO of the several programs—including Technologist database-administrator Year and Database Administrator of the of the Year—use Oracle user group leaders Leadership Year awards. Oracle Global Customer as judges. Thanks to these community oracle.com/us/corporate/awards/leadership Programs soon took on the CIO of the leaders for volunteering their time and Technologist of the Year Year awards and started the Oracle expertise. Thanks also to the nominators, oracle.com/us/corporate/awards/technologist Excellence Awards program, and last designers, and everyone else who worked Send Mail to the Editors year the Editors’ Choice Awards became behind the scenes. the Oracle Excellence Awards for Finally, on behalf of Oracle Magazine, con- Send your opinions about what you read in Oracle Technologist of the Year. gratulations and thanks to all of the Oracle Magazine, and suggestions for possible technical Oracle Magazine has featured Excellence Awards winners. articles, to [email protected]. You can Editors’ Choice Award winners, CIO also follow our @oraclemagazine Twitter feed or join us on Facebook at bit.ly/orclmagfb. of the Year award winners, and now Tom Haunert, Editor in Chief Letters may be edited for length and clarity and Technologist of the Year award winners [email protected] may be published in any medium. We consider in its pages since 2002. Some of the any communications we receive publishable. best content in the magazine has been

CONNECT: bit.ly/aVgo69 bit.ly/orclmagfb twitter.com/oraclemagazine linkd.in/orclmag

January/February 2013 Oracle.com/oraclemagazine

JF13_ednote.indd 6 11/30/12 1:47 PM Your Destination for oracle anD Java expertise Written by leading technology professionals, Oracle Press books offer the most definitive, complete, and up-to-date coverage of Oracle products and technologies available.

oca/ocp Java se 7 programmer i & ii study Guide Kathy Sierra, Bert Bates Get complete coverage of all objectives for exams 1Z0-803 and 1Z0-804, plus challenging practice exam questions.

oca Java se 7 programmer i study Guide Edward Finegan, Robert Liguori Get complete coverage of all objectives for exam 1Z0-803, plus challenging practice exam questions.

oracle Business intelligence 11g Developers Guide Mark Rittman Deliver meaningful business information to users anytime, anywhere, on any device, with Oracle Business Intelligence 11g.

oracle exalytics revealed Mark Rittman Written by Oracle ACE Director Mark Rittman, this eBook-exclusive eBook publication offers comprehensive only coverage of Oracle Exalytics In-Memory Machine. Available as an eBook only

Available in print and eBook formats Join the Oracle Press Community: www.OraclePressBooks.com

@OraclePress OraclePress

MHP OracleMag Ad jan-feb 2013.indd 1 11/9/12 3:55 PM 8 MashUp News. Views. Trends. Tools.

Need help with your New Year’s resolutions? Look no further than your smartphone. Get Fit Learn Something Reduce Stress Get Out of Debt APPS Endomondo Sports New Stress Check by Debt Payoff Planner Tracker lets you track Get pocket access to Azumio uses your lets you consolidate all running, cycling, the Wolfram|Alpha smartphone’s camera your debt in one place and other distance- “knowledge engine,” and light features to and track payments based activities and which features broad measure your heart and schedules. Pay get support from a and deep information rate and thereby off bills by highest 12-million-member ranging from math quantifies your stress balance first, lowest community. Free or and physics to music, level. The app also balance first, highest US$4.99 for PRO books, and languages. helps you identify interest first, minimum version with additional US$3.99 (Android, stressors and tracks payments only, or

2013 RESOLUTION RESOLUTION 2013 features (Android, iPhone/iPad). your stress level over your specified order. “When leaders BlackBerry, Java, products time. Free (Android, US$0.99 (Android). embrace iPhone, Symbian, .wolframalpha.com/ iPhone). azumio.com/ adonisapps.webs beliefs without Windows Mobile). mobile apps/stress-check .com endomondo.com understanding and managing the potential side effects, the beliefs become sacred cows and get MIGHTY MIC in the way.” —Jake Breeden, author of Tipping Have you used your iPad or iPhone to record audio? Were you Sacred Cows (Jossey-Bass, 2012) satisfied with the results? If you’re looking for professional-quality recording from your iOS device, Mikey Digital, a plug-and-play stereo microphone from Blue Microphones, directly connects COVER to your iPad or iPhone and is instantly recognized by audio and YOUR APPS video applications. Automatic gain settings enable Mikey Digital to intelligently adjust to fluctuating volume levels, while manual In the months gain settings allow users to set low sensitivity for extremely loud of June, July, and August 2012, nearly 25,600 sources and high sensitivity for quieter sources. The mic’s LED malicious smartphone apps clipping indicator flashes whenever volume levels are producing were available for download— distortion, providing immediate feedback so users can make a 216 percent increase from the adjustments. Mikey Digital also rotates 230 degrees for optimal previous three-month period. positioning or alignment with front- or rear-facing cameras. It China-based app marketplaces includes a multisource input jack that allows for direct connection are the most risky, and games of guitars and other sound sources. US$99.99. bluemic.com are the most likely category of apps to carry threats. Source: TrustGo, bit.ly/PFG1ou

Bad Mobile Sites Harm Brands Insights on Innovation If your business Website isn’t optimized for The world’s most innovative companies not only permit failure but welcome it to craft mobile use, it hurts your company’s brand, accord- better ideas. However, nearly half of the respondents to a global survey said that their ing to a survey of 1,088 adult smartphone users in the US. companies have no systems in place to learn from failure. What’s more, many companies KEY FINDINGS do not capitalize on IT to foster innovation. Responses to the question, “What is the role of your IT department in cultivating business innovation? (select up to two)” were of respondents feel frustrated and annoyed when 48% they get to a site that’s not mobile-friendly 51% Supplying technologies that foster the innovative process of respondents feel like they’ve wasted their time 37% Enabling business units to adapt processes rapidly 36% by visiting those sites 28% Implementing and maintaining new business ideas within business processes of respondents say a bad mobile experience 19% Educating business leaders on new technology trends 52% made them less likely to engage with a company 13% The IT department is not involved in our business innovation of respondents say if a site didn’t work well on 11% Identifying pockets of innovation in the enterprise 48% their smartphones, it made them feel like the company didn’t care about their business

Source: Google, bit.ly/Syslba Source: Cultivating Business-Led Innovation, Economist Intelligence Unit report sponsored by Oracle, bit.ly/TIKDcI CHEN I-HUA

JANUARY/FEBRUARY 2013 ORACLE.COM/ORACLEMAGAZINE

JF13_MashUp.indd 8 11/29/12 12:26 PM oracle-global-business-nov12-fullOL.pdf 1 11/12/2012 4:12:20 PM

C

M

Y

CM

MY

CY

CMY

K 12711 NGS Education Ad_Select 1_Layout 1 8/30/11 12:26 PM Page 1

National Geographic Education supports the mission of the National Geographic Society to TOGETHER ORACLE AND inspire people to care about the planet by NATIONAL GEOGRAPHIC EDUCATION ARE creating compelling educational materials for young people and the adults who teach them. NG Education provides unique learning Leading the Way experiences to educators and advocates for improved education in geography, the in Ocean Education environmental sciences, and other disciplines that are critical to understanding our world.

and Marine Research With support from Oracle, National Geographic Education is engaged in a major project to develop teacher leaders in marine ecology and create materials about ocean science and geography for students, families, the ocean recreation community, and the general public.

Support our work today. Visit nationalgeographic.org/education.

National Geographic is a 501(c)(3) organization. PHOTOGRAPH BY ENRIC SALA Events 11

Technology Events Oracle User Groups Dayton Oracle Users Group Meeting Conferences and sessions to help you stay Featuring Tom Kyte January 8, Dayton, Ohio on the cutting edge dayton.oracle.ioug.org

IOUG Business Intelligence, Warehousing, and Analytics (BIWA) Cloud Expo Europe SIG Summit January 29–30, London, England January 8, Redwood Shores, California oraclebiwasig.blogspot.com This free “how to” event is for businesses and public sector agencies seeking to deliver cloud strategies on KC Java User Group Meetups time and on budget. Sessions cover technology and January 9 and February 13, Leawood, Kansas meetup.com/kcjava business issues related to public, private, and hybrid clouds, including security, governance, and virtualiza- PackerLand Users Group Meeting tion. The expo also features seven seminar theaters and January 10, Fond du Lac, Wisconsin bit.ly/PoE8N0 100 vendors and service suppliers in the exhibit hall. cloudexpoeurope.com St. Louis Hadoop Users Group Meetup January 15, St. Louis, Missouri www.stlhadoop.org

Oracle Desktop Virtualization Network with senior business and IT executives, Connecticut Java Users Group Meetings Seminars in the UK attend high-value business sessions tailored for January 15 and February 19, Hartford, January 9, London, England; January 23, global retailers, and learn how Oracle’s extended Connecticut ctjava.org Reading, England; February 6, Linlithgow, retail footprint supports innovative retailers. Scotland; February 20, Birmingham, Seattle Area Java Users Group Meetings England; February 21, Manchester, England Construction CPM Conference January 15 and February 19, Seattle, Washington fevents.oracle.com January 27–30, New Orleans, Louisiana seajug.org The free seminars’ topics and demonstrations fconstructioncpm.com include how to develop a seamless applications- Construction professionals meet to study and UKOUG Solaris SIG Meetings January 16 and February 20, London, England to-disk strategy, deploy server virtualization stra- discuss the theory and practice of critical path ukoug.org tegically, provide a managed and hosted desktop method (CPM) in their industry. Sessions include workspace, and allow secure access to Oracle introductory and advanced training on CPM Toronto Java Users Group Meetings and other applications from nearly any device. software products, estimating cost and risk, the January 17 and February 21, Toronto, Ontario, Canada Preregistration is required. impacts of building information modeling, and tjug.ca lean and green practices. New Zealand Oracle Users 2013 Chief Marketing Officer Group Meetings Leadership Forum AFCEA West January 23 and February 13, Wellington, January 10, Los Angeles, California January 29–31, San Diego, California New Zealand nzoug.org fbit.ly/WSJO0T fbit.ly/W3ekFP Chief marketing officers (CMOs) and marketing Cosponsored by the Armed Forces OUG Scotland BI SIG leaders from many industries gather to discuss Communications and Electronics Association February 5, Linlithgow, Scotland best practices and innovative marketing strate- (AFCEA) International and the U.S. Naval ukoug.org gies. Areas of emphasis include renewing and Institute, this is the largest event on the West Rocky Mountain Oracle Users Group strengthening consumer focus, key elements Coast for military communications, electronics, Technical Training Days of exceptional brands, understanding and using intelligence, information systems, imaging, February 11–13, Denver, Colorado bit.ly/Xhny4R social media and digital marketing, and the role weapon systems, aviation, shipbuilding, and more. of the CMO. Memphis Area Oracle User NAW 2013 Executive Summit Group Meeting February 12, Memphis, Tennessee Oracle Retail Exchange January 29–31, Washington DC bit.ly/uXM6L6 January 13–16, New York, New York fbit.ly/RxtNKy fbit.ly/Thj8CN The National Association of Wholesaler- Southwest Regional Oracle Applications User Group Meeting International attendees of the National Retail Dealers (NAW) meets to focus on the chal- February 22, Los Angeles, California Federation BIG Show receive additional content lenges and opportunities its members face sroaug.com

/P olkadot istock and opportunities at the Oracle Retail Exchange. in 2013–2014. Executives, consultants, and

oracle magazine January/February 2013

JF13_Events.indd 11 11/29/12 12:48 PM 12 EVENTS

launch and expand MDM initiatives, and explore methods and metrics for assessing MDM’s return on investment.

FAST ’13: The USENIX Conference on File and Storage Technologies February 12–15, San Jose, California „usenix.org/conference/fast13 Storage researchers and practitioners gather to explore new directions in the design, implemen- tation, evaluation, and deployment of storage systems. The conference includes technical presentations, refereed papers, work-in-progress Storage trends are a key theme at FAST ’13: The USENIX Conference on File and Storage Technologies in San Jose, California, February 12–15. reports, poster sessions, and tutorials.

academics speak, and roundtables provide event explores the convergent needs of digital TDWI World Conference 2013: opportunities for networking. storage to support cloud content distribution Data Strategy for Your Enterprise and sharing, capture and use user-generated February 17–22, Las Vegas, Nevada Oracle Value Chain Summit content, and run professional media and enter- „tdwi.org/conferences February 4–6, San Francisco, California tainment applications. This conference provides business and tech- „bit.ly/OUn8Oo nology professionals with in-depth, vendor- This inaugural event for Oracle users, thought Crexia SMART neutral education on business intelligence and leaders, partners, and experts includes 200 ses- January 17, London, England data warehousing topics. It features basic and sions, demos, and more featuring content about „crexia.com/events/smart advanced courses, peer networking, one-on-one product lifecycle management, enterprise asset This event, covering social, mobile, and recruit- consulting, and certification. management, logistics, value chain planning, ment technology (SMART), attracts more than and procurement. 300 delegates to discuss social recruiting plat- Mobile World Congress forms, mobile recruiting platforms, and big data February 25–28, Barcelona, Spain 7th Annual Oracle Maintenance recruiting tools. It also features opportunities to „mobileworldcongress.com Summit network with fellow professionals, HR bloggers, This industry-leading event includes a thought- February 4–9, San Francisco, California and technology vendors. leadership conference with keynotes and panel „bit.ly/Panlgh discussions, a product and technology exhibi- Learn from industry experts, fellow Oracle users, CalConnect XXVI tion with 1,500 exhibitors, gatherings of mobile partners, and Oracle representatives how to January 28–February 1, Santa Clara, applications and mobile marketing communities, leverage Oracle enterprise asset management California and an awards program. across an organization. „calconnect.org Oracle hosts this meeting of the Calendaring RSA USA 2013 The Conference Board Talent and Scheduling Consortium, which focuses on February 25–March 1, San Francisco, Management Strategies Conference the interoperable exchange of calendaring and California February 13–14, New York, New York scheduling information between dissimilar pro- „bit.ly/URS2DC „bit.ly/SSlgjW grams, platforms, and technologies, through cal- Thousands of information security profes- Talent management professionals share how endaring and scheduling methodologies, tools, sionals meet to discuss the technologies that they are innovating processes to meet busi- applications, and standards. protect products, data, and infrastructure. ness challenges, creating ways to tap employee More than 220 sessions are featured across passion and deliver business results, and lever- Gartner Master Data Management 18 tracks. aging technology to attract and retain talent. Summit February 7–8, Barcelona, Spain Storage Visions „bit.ly/ThkDAZ EVENTS LOCATOR January 6–7, Las Vegas, Nevada This conference examines data management „storagevisions.com tools and technologies that can improve the Oracle Events CEOs, storage industry leaders, manufacturers, visibility, accuracy, and usefulness of critical oracle.com/events ÁN and end users gather to discuss how digital data. Learn to create a master data manage- Locate User Groups oracle.com/technetwork/community

content is created, protected, and stored. This ment (MDM) strategy, understand how to MERCH ELIJAH

JANUARY/FEBRUARY 2013 ORACLE.COM/ORACLEMAGAZINE

JF13_Events.indd 12 11/29/12 12:49 PM Resources 13

What’s New at Oracle The latest videos, podcasts, blogs, and more

WEBCASTS “Oracle Linux Management Demystified” Your Data Center. Optimized. “Time for Change: Optimizing Data Center fbit.ly/WLTD1y fbit.ly/Ragi4n Infrastructure with a Technology Refresh” Find out about provisioning, patching, monitoring, Transform your data center from a cost center to fbit.ly/TdkfJH and administration of Linux systems using Oracle an innovation hub: simplify IT for business innova- International Data Corporation representatives Enterprise Manager 12c. tion; increase server consolidation, performance, discuss findings based on interviews with seven and flexibility; and reduce deployment time, costs, Oracle customers that recently completed data Webcast Series: Oracle WebCenter in Action and risk. center optimization projects. fwebcenterinaction.com This series features Oracle WebCenter customers MySQL Strategy 2012: The State of “Managing Social Relationships for and partners as they share how Oracle’s portal, the Dolphin the Enterprise” Web experience management, content manage- fbit.ly/T2RZr4 fbit.ly/QYyGfN ment, social, and collaboration technologies are Watch this MySQL Connect keynote featuring Altimeter Group’s Jeremiah Owyang and helping them transform into social businesses. Oracle Chief Corporate Architect Edward Screven Oracle’s Reggie Bradford discuss how to opti- and Oracle Vice President of MySQL Engineering mize engagement with prospects and customers Webcast Series: Oracle Author Chat Tomas Ulin. and explore strategies for developing brands fbit.ly/QsSXuJ through social media. Tom Plunkett, coauthor of the Oracle Press Reduce Risk with Oracle Advanced book Oracle Exalogic Elastic Cloud Handbook, Monitoring and Resolution “The Value of MySQL for SaaS Vendors” describes how this book helps administrators and fbit.ly/QDVXqf fbit.ly/Vewkjd architects understand how to use Oracle Exalogic Discover the unique features of Oracle’s 24/7 In this technical Webcast, MySQL expert Mario in a data center. secure monitoring services and the value of pro- Beck reviews features that make MySQL well active resolution for Oracle products, delivered by suited for software as a service (SaaS), touches GAMES advanced support engineers. on upcoming improvements in MySQL 5.6, and Oracle Vanquisher Data Center provides practical tips on how to get the most Optimization Adventure Oracle Platinum Services Centers from MySQL in a SaaS environment. fbit.ly/XpVVTy of Excellence What if you could vanquish threats to your data fbit.ly/PEkFaM “Discover MySQL Cluster 7.2: Extreme center such as heat, downtime, and legacy hard- Find out how Oracle delivers remote monitoring, Performance, Availability, and Affordability ware to simplify IT and accelerate business inno- restoration, and patching to help maximize the for Independent Software Vendors and vation and growth? Play this new data center performance and availability of Oracle’s engi- Original Equipment Manufacturers” optimization arcade video game and find out. neered systems. fbit.ly/Vex1ce Learn how the new MySQL Cluster 7.2 VIDEOS Confidence in the Cloud: Tour Oracle’s EMEA release that supports more than 1 billion Oracle OpenWorld Highlights Data Center queries per minute can enable products that fbit.ly/XpYdSI fbit.ly/R6CXQo deliver 70-times-higher join performance, Don’t miss the full-length keynotes and high- Watch Oracle Cloud Service CIO Tom Fisher linear scalability, five 9s of uptime, and real- lights, general sessions, and executive solution and Oracle Vice President of Service Delivery for time responsiveness. sessions from Oracle OpenWorld 2012. Europe, the Middle East, and Africa Tony Gray as they discuss Oracle’s global data centers and “Bridging the Gap in Big Data, Cloud, and Hardware and Software, Engineered to Work enterprise-grade security standards. Real-Time Data Integration: Keep Pace Together: Why It’s a Different Approach with the Latest Breakthroughs” fbit.ly/Tvh2iV PODCASTS fbit.ly/QOKyQe Watch Oracle CEO ’s Oracle “SQL Server Migration Tool” Get up to speed on big data, cloud integration, OpenWorld 2012 keynote to learn how Oracle fbit.ly/R5aFWv real-time analytics, and continuous availability technology is engineered to work together and is Alfredo Kojima, Oracle senior software devel- solutions. changing the face of IT. opment manager, talks about the advantages

oracle magazine January/February 2013

JF13_Resources.indd 13 11/29/12 1:01 PM 14 Resources

overHEARD private cloud offerings and Oracle SPARC SuperCluster can help you consolidate and evolve “As we move more and more of our databases onto [Oracle] to a private cloud model. Exadata machines, those databases aren’t going to go onto disk drives. They’re going to go into flash memory where the “Consolidation on High-End SPARC Enterprise M-Series Servers” information is available instantaneously, where you can ask a fbit.ly/OPiPTd question and get an answer at the speed of thought.” Find out how to boost server utilization and —Oracle CEO Larry Ellison in his Oracle OpenWorld 2012 keynote address, Hardware and Software, simplify application deployment by consoli- Engineered to Work Together: Why It’s a Different Approach (bit.ly/Tvh2iV) dating on Oracle’s SPARC Enterprise M8000 and M9000 servers. of the new Microsoft SQL Server to MySQL Demystifying Cloud Integration migration tool. fbit.ly/RqSkBo “The Oracle x86 Portfolio: Competitive As organizations use a mix of private and public Advantages in Total Cost of Ownership” “Top Tips to Accelerate Enterprise Software cloud services, they need a better way to inte- fbit.ly/R8Odf6 Deployment on Linux” grate information across a multitude of cloud Read Edison Research’s conclusions about the fbit.ly/VkuY6o environments. Find out why Oracle takes a unified lower-cost advantages of Oracle’s Sun x86 Discover how Oracle Validated Configurations can approach to integrating information with its real- server offerings. speed up deployment. time data integration solutions. “Stock Shock: The Effect of Project and SOCIAL MEDIA E-BOOKS Portfolio Management on Share Price” New OracleVoice Channel on Forbes.com Enterprise Cloud Infrastructure for Dummies fbit.ly/R4kB0m fonforb.es/S7YtQB fbit.ly/WpdULZ This independent report examines existing Join others following Oracle on the new Discover how to implement a cloud infrastructure research and industry examples and explores OracleVoice channel on forbes.com. Don’t miss that not only lowers operational costs but can also practical approaches to maintaining effective the inaugural article written by Oracle Senior Vice easily adapt and scale to safely and securely run a visibility and control over key operational project President of Communications Bob Evans, “The broad range of application services. management metrics. Top 10 Strategic CIO Issues for 2013.” Simplify IT Through Hardware web locator RESOURCE CENTERS Technology Refresh Consolidate and Simplify SAP Environments fbit.ly/U032jO Oracle Blog Center oracle.com/blogs fbit.ly/WBjIQP Read this e-book to understand how to assess the Oracle Consulting Learn how the Oracle Optimized Solution for SAP current value of your existing assets and map out oracle.com/consulting can help you consolidate an SAP environment your future infrastructure. Oracle Events and Webcasts onto a high-performing, highly available applica- oracle.com/events tion infrastructure. Plan. Build. Operate. Success Strategies Oracle Newsletters for Oil and Gas Projects oracle.com/newsletters Simplify and Modernize Global fbit.ly/QYC3Dn Oracle Podcast Center oracle.com/podcasts Business Environments This interactive e-book is full of videos, demos, Oracle University fbit.ly/RH6IYT white papers, and other valuable resources. oracle.com/education Discover how the Oracle Optimized Solution for Oracle on Facebook Oracle E-Business Suite provides an ideal archi- WHITE PAPERS facebook.com/oracle tecture for upgrading and consolidating Oracle’s “Preventing Silent Data Corruption” Oracle on Google+ integrated suite of global business applications. fbit.ly/QCExG9 bit.ly/LdGiM0 Learn what Oracle is doing to protect the integ- Oracle on LinkedIn linkedin.com/company/oracle Oracle Optimized Solution for Backup rity of data as it travels through the storage- Oracle on Twitter and Recovery area network. twitter.com/oracle fbit.ly/VbOged Oracle Support Learn how the Oracle Optimized Solution for “Infrastructure Modernization Done oracle.com/support Backup and Recovery can reduce time to deploy with Ease and Efficiency: Application My Oracle Support backup and recovery capabilities by up to 2.5 Consolidation to the Private Cloud” myoraclesupport.com times and cut software license and maintenance fbit.ly/QCKnHt My Oracle Support Communities communities.oracle.com costs by up to 75 percent. Get detailed information about how Oracle’s

January/February 2013 Oracle.cOm/oraclemagazine

JF13_Resources.indd 14 11/29/12 1:02 PM Product Resources BRIEFS 15

TUTORIALS Oracle ADF Mobile Available

Oracle NoSQL Database Tutorials Oracle has unveiled Oracle ADF Mobile, a new to multiple devices and platforms. Get started with Oracle NoSQL Database HTML5 and Java-based application develop- “With Oracle ADF Mobile, developers with this series of video demos. Topics ment framework that enables developers can spend less time rewriting code and include retrieving key-value pairs, installing Oracle NoSQL Database, and to build, deploy, and extend hybrid mobile more time building the most-advanced using Eclipse in developing Oracle NoSQL applications for multiple platforms, including enterprise mobile applications,” says Chris Database applications. iOS and Android, from a single code base. An Tonas, vice president of Oracle’s applica- „bit.ly/Yjus6g extension of Oracle Application Development tion development tools group. “Oracle ADF Framework, Oracle ADF Mobile enables orga- Mobile is tightly integrated with the Oracle Getting Started with Application Express 4.2 nizations to protect their investments while Fusion Middleware product portfolio, sup- This video series helps you to get started addressing frequently ports Oracle Fusion Applications, and can using Oracle Application Express Release changing mobile easily integrate non-Oracle-based applica- 4.2. Topics include creating a mobile Web requirements by tions. With a rich, visual, and declarative application, installing and using a pack- allowing developers programming model, Oracle ADF Mobile aged application, using Oracle Application to rapidly and visually helps developers increase their productivity Express 4.2’s Theme 25 to create a develop applications and deliver applications faster.” responsive Web application, and declara- once and deploy them bit.ly/gKrPpm tively creating a RESTful Web service. „bit.ly/W30kPt Oracle Application Express Release 4.2 Available Oracle Application Testing Suite 12.1: OpenScript for Load Testing Script The latest release of Oracle Application that incorporate responsive Web design or Troubleshooting Express allows developers to rapidly build jQuery Mobile to provide an optimal viewing This 50-minute advanced training session database-centric HTML5 applications using experience on all devices,” says Mike Hichwa, covers the basics of how the load testing only a Web browser. These applications vice president of Oracle’s database tools module in OpenScript 12.1 records and can run on any mobile platform. Oracle group. “Another key feature being introduced plays back the script, how it correlates the Application Express is a no-cost option is packaged applications that provide out-of- dynamic parameters, and how you can included with all editions and current releases the-box point solutions. The primary benefits troubleshoot script failure problems. of Oracle Database. Oracle Application of these include instantly available produc- „bit.ly/PpRh76 Express 4.2 is available now for download tivity applications, the ability to unlock and ARTICLES from Oracle Technology Network. customize the solutions provided, and the “ Tips for Securing an Oracle “With Oracle Application Express 4.2, ability to demonstrate best practices.” Linux Environment” developers can now easily create applications bit.ly/Y7ws2w Find out about administrative tools that can reduce vulnerabilities and minimize risk for Oracle Delivers First Industry-Specific Engineered System your Oracle Linux environment. „bit.ly/SbMFir Oracle has launched its first industry- Service Availability, and Oracle Clusterware “How to Use Oracle VM Templates” specific engineered system, designed software technologies. The preconfigured, Learn how to prepare an Oracle VM environ- to meet the extreme network workload integrated, and tested Oracle Network ment to use Oracle VM Templates, how to requirements for the development and Applications Platform enables organizations obtain a template, and how to deploy the deployment of mission-critical services in the communications industry to minimize template to your Oracle VM environment. and applications for costs while accelerating the development of „bit.ly/QSwreI the communica- new services. “ How to Migrate Oracle Database tions industry. Oracle “The introduction of Oracle Network from Oracle Solaris 8 to Oracle Network Applications Applications Platform underscores Solaris 11” Platform is an engi- Oracle’s commitment to the communica- Get details on migrating an Oracle Solaris 8 neered system that tions industry by integrating all the key physical system with Oracle Database 10g combines Oracle’s infrastructure components—which have and an Oracle Automatic Storage Sun Netra 6000, historically been custom-assembled—into Management file system located on SAN Oracle’s Sun ZFS a single solution that accelerates time to storage to an Oracle Solaris 8 branded zone Storage 7320, Oracle market for the next wave of innovative inside an Oracle Solaris 10 guest domain on Linux, Oracle VM, communications services,” says Bhaskar top of an Oracle Solaris 11 control domain. Oracle Enterprise Gorti, senior vice president and general bit.ly/Q4uj6P „ Manager, Oracle manager, Oracle Communications.

Communications bit.ly/ToRELl GROENING LINDY

ORACLE MAGAZINE JANUARY/FEBRUARY 2013

JF13_Briefs.indd 15 11/29/12 1:36 PM 16 BRIEFS

StorageTek Virtual Storage Manager System Now Two Times Faster Oracle Previews NetBeans IDE 7.3

To meet the needs of high-growth data ongoing tape operations for data protection, A preview of NetBeans IDE 7.3 is now avail- storage, Oracle’s StorageTek Virtual Storage disaster recovery, and archive. able for download and features new HTML5, Manager System 6 delivers two times the “As customers continue to contend with JavaScript, and CSS development capa- performance and more than 1.8 times the exponential data growth and the need for bilities. This free, open source integrated total disk capacity 24/7 access to mission-critical data, Oracle is development environment (IDE)enables (640 petabytes) of raising the bar with high-performance virtual developers to rapidly create Web, enterprise, the previous gen- tape capabilities that can help keep costs desktop, and mobile applications for the eration. The new down,” says James Cates, vice president of Java platform, PHP, and C/C++. New features release efficiently hardware development at Oracle. “Oracle’s include code completion for new HTML5 manages data and new StorageTek Virtual Storage Manager 6 elements, JQuery, and new CSS3 rules; a storage resources delivers major enhancements in simplicity, JavaScript editor and debugger based on with automated, scalability, and availability that enable cus- the Nashorn JavaScript project; support for policy-driven man- tomers to better manage mainframe storage responsive design–based applications; and agement that sim- environments, maximize their investments in JavaScript client generation from existing plifies deployment tape, and lower total cost of ownership.” Java REST services. and streamlines bit.ly/PJKBCh “Development teams worldwide can now leverage the new capabilities of HTML5, New Mobile Capabilities for Oracle Business Intelligence CSS3, and JavaScript to build rich user inter- faces for both mobile and Web clients,” Oracle has expanded its mobility and intui- bilities in the new release include support says Chris Tonas, vice president, application tive visualization capabilities for its business for touch and multigestural interactions; development tools at Oracle. “The preview of intelligence solutions, including a new user support for offline viewing; and fine-grained NetBeans IDE 7.3 should make it even easier experience designed for maximum pro- security privileges that allow administrators for developers to leverage Java services to ductivity and interactivity. Oracle Business to grant or revoke the ability to save offline build state-of-the-art applications quickly Intelligence Release 11.1.1.6.2, which is avail- content for specific users, roles, and groups. and more efficiently.” able in Oracle business intelligence solu- “Mobile devices, such as the Apple iPad, are .org tions including Oracle Business Intelligence becoming ubiquitous productivity-enhancing Foundation Suite and Oracle Business tools across the enterprise,” says Balaji New Mobile Support for Oracle’s Intelligence Suite Enterprise Edition, enables Yelamanchili, senior vice president, Oracle users to identify and analyze trends and take analytics and performance management PeopleSoft Applications immediate action from their preferred mobile products. “With the latest release of Oracle New mobile features device. New visualization features, such as Business Intelligence, users have access to in Oracle’s PeopleSoft Trellis views, allow users to quickly visualize business-altering data with the swipe of a applications take massive amounts of data in an organized finger. From a redesigned interface to new advantage of HTML5 manner, enabling them to spot anomalies visualization tools and offline access, Oracle and CSS3, making it that require further investigation. The latest Business Intelligence makes it easy for users easier for IT teams mobile features have been redesigned for to view, analyze, and act upon critical data to provide today’s easy offline access, allowing users to view, insights—wherever the job may take them.” mobile workforce with real-time access to analyze, and act on fact-based business bit.ly/ToTc89 critical business information through an insights from their mobile devices. Key capa- bit.ly/U10ipY intuitive user experience from the desktop, smartphones, and tablet devices. Oracle Identity Governance Suite Unveiled The Mobile Expenses, Mobile Approvals, and Mobile Company Directory features Oracle has introduced Oracle Identity remediation, and privileged account manage- are available with Release 9.1 of various Governance Suite, a complete, end-to-end ment. It features a drag-and-drop user inter- PeopleSoft applications at no additional cost. governance solution that enables organiza- face to support analytics-driven reporting. “The latest mobile applications for tions to address their compliance, governance, “With Oracle Identity Governance Suite, we Oracle’s PeopleSoft further demonstrate and security objectives and reduce help desk are delivering a single complete identity gov- Oracle’s commitment to providing workers involvement. A component of Oracle Identity ernance platform that dramatically simplifies on the go with access to real-time business Management 11g Release 2, Oracle Identity the identity lifecycle,” says Marc Boroditsky, data on the most-popular mobile platforms Governance Suite delivers a platform for vice president of product management, iden- available,” says Paco Aubrejuan, senior vice access request, provisioning, role lifecycle tity and access management, at Oracle. president of Oracle’s PeopleSoft applications.

management, access certification, closed loop bit.ly/RxoawX bit.ly/VGcgAE GROENING LINDY

JANUARY/FEBRUARY 2013 ORACLE.COM/ORACLEMAGAZINE

JF13_Briefs.indd 16 11/29/12 1:36 PM Simple. Adaptable. Manageable.

Solution guides for quick and easy deployment! Simple: We are committed to making our solutions the easiest to install, configure, and integrate into either existing IT systems or data centers — or new build-outs. We ship our solution as “ready to install” as possible (e.g., tool-less rack PDU installation and standard cable management features). With our easy-to-configure infrastructure, you can focus on more pressing IT concerns such as network threats.

for any IT space! Adaptable: Our solutions can be adapted to f t any IT conf guration at any time — from small IT to data centers! Vendor-neutral enclosures, for example, come in different depths, heights, and widths so you can deploy your IT in whatever space you have available — from small IT or non-dedicated spaces to even large data centers.

Monitor and manage your IT spaces from anywhere!

Manageable: Local and remote management are simplif ed with “out-of-the-box” UPS outlet control, integrated monitoring of the local environment, and energy usage reporting. Manageability over the network and robust reporting capabilities help you prevent IT problems and quickly resolve them when they do occur — from anywhere! What’s more, our life cycle services ensure optimal operations.

Easy-to-deploy IT physical infrastructure Solution guides make it easy to determine what you need to solve today’s challenges. The Integrated InfraStruxure™ solutions include everything for your IT physical infrastructure deployment: backup core of our system, vendor-neutral enclosures and rack PDUs, makes deployment incredibly power and power distribution, cooling, enclosures, and headache-free. Easily adjustable components, integrated baying brackets, pre-installed management software. Adaptable solutions scale from the leveling feet, and cable management accessories with tool-less mounting facilitate simple smallest IT spaces up to multi-megawatt data centers. and fast installation. Business-wise, Future-driven.™

Make the most of your IT space! Download our Top 3 solution design guides today! Visit www.apc.com/promo Key Code w402v Call 888-289-APCC x6482

©2012 Schneider Electric. All Rights Reserved. Schneider Electric, APC, InfraStruxure, and Business-wise, Future-driven are trademarks owned by Schneider Electric Industries SAS or its affiliated companies. All other trademarks are the property of their respective owners. www.schneider-electric.com • 998-1155587_GMA-US 18 news by Diana Reichardt

SPARC at 25 Computer History Museum event delves into the question: Why SPARC?

n 1987, a small startup called Sun I Microsystems developed its own micro- processor, called SPARC, and introduced the Sun-4, the first computer based on the new chip. On November 1, 2012, many early SPARC team members, along with Oracle President and Executive Vice President of Systems at Oracle John Fowler, convened at the Computer History Museum in Mountain View, California, for SPARC at 25: Past, Present, and Future. This event provided a look back at the history of SPARC and the early days of Sun. Stories from the Left: SPARC at 25 panelists (from left to right) David Patterson, Bill Joy, Bernard Lacroute, Anant Agrawal, participants, including all of the company’s Andy Bechtolsheim, and Rick Hetherington, with moderator Dave House. Right: Panelist Vinod Kholsa founders, illustrated the complex nature of systems design and the challenges of said that when Sun launched SPARC joined Sun in 1996 as coarchitect of Sun’s launching a high-technology company in a everyone said, “What are you trying to do? Millennium processor project. fiercely competitive industry. How can you compete against Motorola, “The Millennium project was the early part While the event was filled with details IBM, Intel, and all of the others in the micro- of threading superscalar machines,” he said. on the challenges the team faced in the late processor space?” The answer was simple, When asked what the future of SPARC holds, 1980s, one topic prompted a discussion that he said. Nobody was delivering the kind of Hetherington replied, “More cores, more surprised even the veterans of Silicon Valley: floating-point performance and technical threads—we’ll continue to turn up the clock.” Why SPARC? computing power necessary for engineering Nathan Brookwood, of semiconductor Panelist Vinod Kholsa, a Sun cofounder workstations. So Sun decided to design its market research firm Insight 64, attended and now a venture capitalist, said that the own RISC architecture and named it SPARC the 25th anniversary event as well as the only way Sun could compete at the beginning for scalable processor architecture. initial launch of SPARC in 1987. “When Scott was to use open source systems that allowed McNealy said the team knew they had a McNealy stood in front of a press confer- the company to leverage everybody else’s hit when they got the first chip back. “It was ence 25 years ago and said SPARC would work. “We had never done a chip before,” pretty clear from a price-performance stand- revolutionize the industry, few in the room, said Kholsa, and he related that there wasn’t point that we had a huge winner,” he said. including me, took him seriously,” he said in a lot of interest in doing SPARC initially, but “We had a magical cocktail that exploded in an EE Times story reporting on the anniver- the team realized they needed a way to dif- the technical marketplace.” sary.1 “But SPARC has now proven that it has ferentiate and beat the competition. Panelist Bill Joy, a Sun cofounder and a some staying power.”  Panelist Andy Bechtolsheim, cofounder key member of the architecture and soft- and chief system architect at Sun during the ware teams, said that SPARC architecture Diana Reichardt is a senior writer at Oracle. development of the SPARCstation series of was needed because he didn’t see support workstations, said the team knew the risk for symbolic computing in an instruction Next Steps was enormous, but he added that “if you set. “I wanted a hardware platform that don’t take some of those bets, you’re never would support the future direction of soft- LEARN more about SPARC systems going to be great. It could’ve broken the ware,” he said. bit.ly/Uvv6tm company, but the will to go and get it done One panelist continues to work on the EXPLORE the SPARC time line bit.ly/YDulUm

was there.” design and performance of SPARC proces- s i w

WATCH video from the event e Sun cofounder Scott McNealy, who sors today: Rick Hetherington, vice president L oracle.com/goto/sparc25 l au appeared at the event in a recorded video, of hardware development at Oracle. He S

1 “SPARC at 25: Oracle’s Larry Ellison a Chip Zealot?” EE Times, November 1, 2012

January/February 2013 Oracle.com/oraclemagazine

JF13_news.indd 18 11/29/12 1:57 PM Interview by Tom Haunert 19

Extreme Performance with Oracle Exadata X3 With a massive boost in flash and DRAM, Oracle Exadata X3 delivers faster applications.

ollowing the recent release of Oracle’s resource planning [ERP] system, and a FExadata Database Machine X3-2 and reporting system. One of the things you X3-8, Tom Haunert, editor in chief of Oracle had to worry about in the past was that one Magazine, sat down with Juan Loaiza, senior workload would swamp the performance of vice president of systems technology at a different workload. Oracle, to discuss the latest development in But now with Oracle Exadata X3 we have Oracle’s engineered systems. The following is a lot of headroom. We went from 50,000 an excerpt from that interview. Download the write I/Os per second to 1 million write I/Os full podcast at oracle.com/magcasts. per second. That means we’re able to con- Oracle Magazine: What’s new in Oracle solidate many more workloads in a database Exadata X3? cloud. We also have very powerful workload Loaiza: The big headline feature in Oracle management capabilities to prioritize across Exadata X3 is that we’ve added a massive the different workloads in a cloud. amount of flash memory and DRAM [dynamic Oracle Magazine: How does Oracle Exadata random access memory]. Previously, Oracle X3 benefit different workloads, such as Exadata was primarily a disk-based archi- data warehousing, OLTP, and packaged tecture with a lot of memory and flash to applications? accelerate the performance of disk. It is now Juan Loaiza, Senior Vice President of Systems Loaiza: Oracle Exadata X3 provides benefits for Technology, Oracle primarily a memory and flash-based architec- all kinds of applications. In data warehousing, ture. With the flash increased by four times, we can fit much more data in memory. We our compression technologies, and the extra takes advantage of the memory architecture. now have 22 terabytes of flash memory per DRAM, we think almost all active customer Before, we only cached reads in flash; now rack. If you use our Exadata Hybrid Columnar data will fit entirely in memory. we’re able to cache writes in flash. We’re also Compression, you can often fit 100 or 200 Oracle Magazine: What does the additional able to take advantage of the flash memory terabytes of data purely in flash, access it flash and the new memory architecture to achieve very high scan rates of 100 giga- much faster, and run warehouses much faster. mean for system performance and storage bytes per second. Our uncompressed data throughput from administration? We’ve also increased CPU performance. flash is 100 gigabytes per second. Loaiza: Having all this extra memory will We’re using the latest 8-core Intel Sandy On the OLTP side, the 22 terabytes of mean that applications will be able to run Bridge processors, which are much faster. flash often allows us to fit the entire OLTP much faster, and Oracle Exadata will be much And we’ve increased the amount of network database—certainly the active parts—in simpler to administer. We have a memory throughput: we have up to forty 10-gigabit flash. So the I/O throughput is much higher. hierarchy, so we automatically put the cold Ethernet ports going out to the data center. With write caching, we’re able to issue writes data on disk where it can be stored most cost Oracle Magazine: Earlier releases of Oracle directly to flash in addition to reads, and that effectively, and the hot data is automatically Exadata were sometimes called “cloud in speeds up OLTP and ERP applications. migrated into flash and DRAM. From flash, a box.” How does the latest release, Oracle We’ve also seen big improvements for we can achieve 1.5 million random I/Os per Exadata X3, fit that nickname? batch jobs because we can now service all second. That’s comparable to the perfor- Loaiza: We’ve put a lot of work into opti- I/Os from flash. The extra DRAM and flash mance of 15,000 disk drives. mizing clouds and consolidating workloads, provide big improvements across the board Oracle Magazine: What other factors con- where you have many different workloads for all different kinds of applications. tribute to Oracle Exadata X3 performance running simultaneously, such as an online Oracle Magazine: Oracle Exadata X3 systems improvements? transaction processing [OLTP] system, consume less electrical power than previous

Bo b Adler Loaiza: We have a new software release that a departmental system, an enterprise releases. How is that possible?

oracle magazine January/February 2013

JF13_interview.indd 19 11/29/12 2:03 PM 20 Interview

Loaiza: There are a number of improvements system, and they might want to expand that. Many customers are taking advantage of in Oracle Exadata to decrease the amount of So, after the expansion, the customer will the entire engineered system stack to achieve power consumed. One is that the Intel chip- have a half rack of Oracle Exadata X2 on the high performance all the way up and down sets that we use just consume less power than bottom, and the top half of the rack will be the stack with no bottlenecks at any level. they did before. Nevertheless the chips are very Oracle Exadata X3. Oracle Magazine: What about the cost and fast and hot, so we use considerable energy on Oracle Magazine: How are you seeing Oracle return on investment of these systems? fans for cooling. A lot of attention went into Exadata being used with other Oracle engi- Loaiza: We’ve left the price of the new the new systems to make sure that the airflow neered systems? Oracle Exadata X3 systems exactly the same is really good to decrease the amount of power Loaiza: Many customers are combining as the X2 systems. So, we’re delivering consumed by the fans. These and many other our engineered systems and using Oracle a lot more capacity and performance for small improvements add up to a decrease in Exadata for the database tier, Oracle the exact same price as before. In Oracle power usage of up to 30 percent. Exalogic for the middle tier or application Exadata X3, we automatically manage the Oracle Magazine: How do organizations that tier, and Oracle Exalytics to run analytics. different storage tiers to provide a system are using previous releases of Oracle Exadata It’s very effective to combine these systems that is both very cost effective and has move to Oracle Exadata X3? together—we optimize them in-house to extreme performance.  Loaiza: We make it very simple to add work together. We use a single ultra-high- capacity to an existing Oracle Exadata system speed InfiniBand fabric to connect all the Next Steps with new Oracle Exadata X3 servers. We’ve different Oracle engineered systems. always allowed a single database machine to We’re also seeing a lot of uptake of our Learn more about Oracle Exadata X3 oracle.com/exadata have servers from multiple Oracle Exadata Sun ZFS Storage Appliance, which connects generations. For example, a customer might using InfiniBand to Oracle Exadata and to Listen to the interview oracle.com/magcasts have a halfhitsw_OracleMag_DBMotoCDC_BD_1112Jan2013.pdf rack of our previous generation X2 Oracle 1 11/14/2012 Exalogic. 4:24:20 PM

C

M

Y

CM

MY

CY

CMY

K

January/February 2013 Oracle.com/oraclemagazine

JF13_interview.indd 20 11/29/12 2:24 PM Partner Excellence! Congratulations20 201212 Specialized Event Partners Sponsor of the Year – Global Logo Capgemini

Full Color Reversed

Middleware Oracle on Oracle Applications

Industry Server & Storage Database

Specialized. Recognized. Preferred.

partner.oracle.com or call 1.800.323.SELL 1 Color

Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Oracle and Java are registered trademarks of Oracle and/or its affiliates. Other names may be trademarks of their respective owners.

omg0113p021.indd 1 12/4/12 1:08 AM

PUB NOTE: Please use center marks to align page. Print Ad Job No.: 213M_CRP_PrtnrsGlbl PRODUCTION NOTES READER LASER% RELEASED Headline: Partner Excellence! Date: 10/1/2012 Project: Master Print Ad 10/1 Type: Magazine 01 2012 7.875” x 10.5” Live: 7.375” x 10” Trim: 7.875”x 10.5” Please examine these publication materials carefully. Full Page Master Bleed: 8.625”x 11.25” Any questions regarding the materials, Fonts: Univers LT Std. 75 Black, 65 Bold, 55 Roman, 45 Light, please contact Darci Terlizzi (650) 506-9775 67 Bold Condensed, 57 Condensed 22 Book Beat

Oracle ADF Real World Developer’s numerous tips and tricks for extending Oracle Partners Achieve Gold- Guide and enhancing your applications. The book Level Status By Jobinesh Purushothaman equips you with invaluable information about Oracle SOA Suite development that Packt Three Oracle partners—Globalization can usually only be gained through experi- packtpub.com Partners International, Integware, and ence. The cookbook’s recipes distill real- world experience into an easily applicable Windward—have achieved Oracle Gold Oracle Application form. Throughout the book you’ll encounter Partner status. Oracle Gold Partner status Development Framework high-level challenges such as building a reli- (Oracle ADF) in com- enables these partners to develop Oracle able Oracle SOA Suite cluster and detailed bination with Oracle PartnerNetwork specializations; makes them development problems such as avoiding JDeveloper offers visual and declarative errors in Oracle BPEL assignment state- eligible to resell Oracle Applications and approaches to enterprise application ments. Along the way you’ll also learn about industry solutions; and gives them access to development. With the help of many real- configuring identity providers and managing world examples, this book will teach you Oracle account representatives, My Oracle transaction boundaries. to build scalable rich enterprise applica- Support updates, and other services. tions using Oracle ADF. Author Jobinesh Expert MySQL, Second Edition Globalization Partners International pro- Purushothaman starts off by introducing the Oracle JDeveloper development envi- By Charles Bell vides translation services for Oracle RightNow ronment and design time features. Then Apress CX Cloud Service customers, as well as com- he shows you how to build a full-stack apress.com prehensive document, enterprise application using Oracle ADF. software, and Website You will also learn how to use Oracle ADF to This reference book is a build business services, enable validation must-have for systems translation offerings. for the data model, declaratively build user integrators, engineers, Its translation services interfaces for business services, and enable and software developers encompass all compo- security across application layers. working with MySQL server code. Author nents of Web customer Charles Bell shows you how to modify the Oracle Exalytics Revealed code, create your own storage engine, build service, including self- By Mark Rittman your own authentication plug-ins, and even service knowledgebases, e-mail response add your own functions and commands to the Oracle Press management, Web chat, virtual assistants, SQL language. Expert MySQL, Second Edition, oraclepressbooks.com also provides extensive details and examples and SMS mobile customer service. of the inner workings of MySQL and pres- Integware, a provider of product lifecycle Enable your organization ents information on key aspects of MySQL to analyze large amounts management (PLM) services and solutions internals. You’ll learn about internal query of data via rich visual for regulated industries, delivers solutions representation, how the optimizer creates dashboards using Oracle execution plans, and how to exert control over that satisfy good-quality practices in compli- Exalytics In-Memory Machine. Written by those plans for optimal performance in your ance with worldwide regulatory standards Oracle ACE Director Mark Rittman, this environment. High availability and replication e-book offers comprehensive coverage for manufacturers. During its more than 18 are also covered. of Oracle Exalytics In-Memory Machine, years in business, Integware has established Oracle’s preintegrated business intel- Managing Multimedia and Oracle-related knowledge; developed a ligence platform. Oracle Exalytics Revealed Unstructured Data in the Oracle deep understanding of PLM software, pro- begins with an overview of the product and Database its capabilities and then provides complete cesses, and industry standards; and created details on installation, configuration, By Marcelle Kratochvil best practices that are leveraged across all administration, maintenance, and creation Packt industry segments. of the in-memory adaptive data mart that packtpub.com Windward creates reporting, document powers speed-of-thought dashboards. Additionally, Rittman offers expert tips Managing Multimedia and generation, and business intelligence soft- for integrating with both Oracle and non- Unstructured Data in the ware. Its reporting tool for Oracle solutions Oracle enterprise datasources. Oracle Database will help makes report and document creation a you gain an understanding Oracle SOA Suite 11g Developer’s of how to manage all data, especially multi- simple three-step process that can be per- Cookbook media. Starting with the basic principles of formed by any end user of Microsoft Office By Antony Reynolds and unstructured data and detailing the concepts applications. Original equipment manu- behind multimedia warehouses and digital Matt Wright facturers and value-added resellers also asset management systems, this book Packt describes how to load this data, search against use and resell Windward’s reporting tools, packtpub.com it, display it intelligently, and deliver it to cus- which can be used to create financial state- tomers and users. Author Marcelle Kratochvil Whether you’re using ments, inventory reports, product-usage explains how all these concepts work within Oracle SOA Suite as an reports, purchase orders, invoices, training the Oracle Database 11g Release 2 environ- integration tool or as ment and how to tune the database effectively certificates, timesheets, licenses, and com- the foundation of your SOA, your goal is a to manage this data. pliance reports. reliable SOA implementation. Oracle SOA Suite 11g Developer’s Cookbook gives you Look for other Oracle books at globalizationpartners.com the knowledge to achieve that, through bit.ly/NjG3KM integware.com

windward.net CHEN I-HUA

JANUARY/FEBRUARY 2013 ORACLE.COM/ORACLEMAGAZINE

JF13_Partner.indd 22 11/29/12 2:40 PM PARTNER NEWS 23

Oracle Introduces Partner Tools and Programs for eVerge Group Achieves Two Oracle Enterprise Manager 12c Oracle PartnerNetwork Oracle has enhanced its partner tools and as management plug-ins, management Specializations programs related to Oracle Enterprise connectors, deployment procedures, and eVerge Group, an Oracle Platinum Partner, Manager 12c. These updates can help Oracle data masking templates. The updated has achieved Oracle PartnerNetwork partners accelerate their customers’ transi- Oracle Enterprise Manager knowledge zone Specialized status for both High Technology tion to private and public clouds. The new is a private online Oracle partner commu- and Professional Services. These new spe- tools and programs include a new Oracle nity featuring discussions about partner cializations join eVerge Group’s existing Enterprise Manager extensibility exchange, opportunities, go-to-market suggestions, specializations in Oracle’s Siebel CRM, an updated Oracle PartnerNetwork (OPN) and OPN program and portal topics. The Oracle CRM On Demand, Oracle Business Oracle Enterprise Manager knowledge zone, enhanced Oracle Enterprise Manager Intelligence Foundation, Oracle Business and Oracle Enterprise Manager extensibility extensibility kit collects tools, utilities, and Intelligence Applications, Oracle’s kit resources. documentation, including reference imple- PeopleSoft Human Capital Management, The new Oracle Enterprise Manager mentations, build-time tools for validating Oracle’s PeopleSoft PeopleTools, Oil extensibility exchange provides a central Oracle Enterprise Manager extensibility, and Gas, Public Sector, and Education place where partners can share extensions and tools for validating and packaging and Research. for Oracle Enterprise Manager’s hetero- plug-in code components. eVerge Group delivers Oracle Business geneous management ecosystem, such bit.ly/Y4GfFq Intelligence Enterprise Edition and Oracle customer relationship management, enter- Oracle, Infosys, and Wipro Codevelop PeopleSoft Migration Solutions prise performance management, enter- prise resource planning, and master data Infosys and Wipro, both Oracle Diamond the project, and both companies have management solutions to organizations Partners, are working with Oracle to undergone training on the tools and meth- throughout the Americas. develop solutions aimed at users of Oracle’s odologies that facilitate migration. The evergegroup.com PeopleSoft applications who want to work to develop a comprehensive, low-risk migrate to Oracle Fusion Applications. The path from PeopleSoft to Oracle Fusion Hitachi Consulting Achieves work will also benefit customers that want Applications is being conducted across to adopt a coexistence model (one that human capital management, financials, and Diamond-Level Status in Oracle uses both PeopleSoft and Oracle Fusion procurement applications, and applies to PartnerNetwork Applications), as well as customers that con- deployments in both software-as-a-service Hitachi Consulting has tinue to use only PeopleSoft applications. and on-premises environments. earned Oracle Diamond Both Infosys and Wipro are engaged infosys.com Partner status—the in the design, build, and test phases of wipro.com highest ranking in the Oracle PartnerNetwork Oracle Unveils New Cloud Programs for Partners Specialized program— for its commitment to codeveloping Oracle has unveiled new partner programs, Cloud Builder specialization provides part- customer-centric solutions that meet specializations, and services designed ners who sell and implement Oracle hard- business needs and help clients secure to help Oracle partners meet customer ware and software offerings with expertise, maximum benefits from their Oracle demand for public, private, and hybrid tools, and training related to building applications. cloud solutions. private clouds. Hitachi Consulting has several thou- The new Oracle Cloud Referral program The Oracle Cloud Resale program allows sand trained professionals focused on enables any Oracle PartnerNetwork qualifying Specialized partners to resell 29 Oracle specializations, which include member to receive compensation for refer- Oracle Cloud services and create a sustain- five advanced specializations (Oracle ring Oracle Cloud business to Oracle. The able revenue stream over the lifetime of E-Business Suite Financial Management; Oracle Cloud specialization, which was a customer’s Oracle Cloud subscription. Oracle E-Business Suite Supply Chain created in conjunction with Oracle’s devel- Finally, the new Oracle Platform Services for Management; Oracle’s Siebel CRM; Java opment and consulting groups, enables Independent Software Vendors (ISVs) lets Platform, Standard Edition; and Oracle partners to deliver their ISVs leverage Oracle Cloud’s secure, flexible Database), and is working toward several own rapid-start, fixed- architecture to build and deploy new appli- more advanced specializations. Hitachi scope implementa- cations or extend existing on-premises offer- Consulting is also the first Oracle Diamond tion offerings that get ings without additional infrastructure and Partner to achieve Oracle’s Agile Product customers onto Oracle platform investments. Lifecycle Management specialization.

I-HUA CHEN I-HUA Cloud. The new Oracle bit.ly/Q25M2j hitachiconsulting.com

ORACLE MAGAZINE JANUARY/FEBRUARY 2013

JF13_Partner.indd 23 11/29/12 2:40 PM 24 PARTNER NEWS

Platinum Partner Syntax Systems Achieves Oracle ChemAxon’s JChem Cartridge Is PartnerNetwork Specializations Oracle Exadata Ready Syntax Systems, an Oracle Platinum Partner, throughout North America and a supplier of ChemAxon’s JChem has attained Oracle PartnerNetwork spe- managed services and outsourcing solutions Cartridge platform has cializations for its expertise in delivering to midmarket organizations, Syntax has met achieved Oracle Exadata services related to Oracle’s JD Edwards rigorous requirements based on the needs Ready status, demon- EnterpriseOne, Oracle Accelerate for and priorities of the customer and partner strating that ChemAxon, Midsize Companies, and the wholesale community and has demonstrated expertise an Oracle Gold Partner, distribution industry. and success with planning, deploying, and fully tests and supports A provider of enterprise resource plan- managing Oracle products. JChem Cartridge version ning solutions to organizations of all sizes syntax.com 5.9 on Oracle Exadata Database Machine. Red Rock Consulting Acquires Tripoint ChemAxon provides cheminformatics software Oracle Platinum Partner Red Rock Australia and New Zealand. development platforms Consulting has acquired Oracle Gold The acquisition will help Red Rock cover and desktop applications used in biotech- Partner Tripoint Corporation, a provider of a greater breadth of Oracle applications nology, pharmaceutical, and agrochemical online managed services solutions based and increase its depth in middleware, data- industries. The company’s solutions provide on Oracle’s PeopleSoft applications. Red base, and infrastructure managed services. high-performance scientific functionality, Rock will fold the Tripoint business into Red Rock Consulting is a business unit of including structure visualization, search and its existing managed services practice, Australian IT services and solutions provider management, property prediction, virtual making the combined company the UXC, itself an Oracle Platinum Partner. synthesis, screening, and drug design. largest locally based PeopleSoft partner in uxc.com.au chemaxon.com

Polar Bears International is a trusted voice focused on funding scientific research for the survival of this magnificent animal. Polar Bears International also funds educational programs that are inspiring people to reduce their carbon emissions. Conservation through Research and Education www.polarbearsinternational.org Help Us Help the Polar Bear Photo © R&C BuChanan

JANUARY/FEBRUARY 2013 ORACLE.COM/ORACLEMAGAZINE

JF13_Partner.indd 24 11/29/12 2:41 PM Architect By Bob Rhubart 25

Roadmaps and Guardrails It’s time to revive the conversation about IT governance.

T governance is a touchy subject. Few “Excitement about technologies without making some adjust- I architects would argue the importance of ments, and in some cases you may be at least some form of governance, so why did new technologies entering uncharted territory. The outcome of five minutes of research on Google Trends that journey depends entirely on enforcing confirm that interest in IT governance has can cause people your architectural roadmap through effec- steadily declined since 2004? to take their eyes tive governance. After all, enterprise IT certainly hasn’t “Unless you have some regulation or gotten any less complex in the last eight off the ball, in guardrails around what’s going to happen, or nine years, especially given the growing terms of staying crazy things will occur,” says Stephens. And influence of cloud computing, mobile crazy is rarely mentioned as a desirable devices, social media, big data, and all those disciplined with ingredient in a successful IT strategy.  game-changing technologies. Managing that complexity is essential and requires a their IT behaviors.” carefully planned architecture—a roadmap —Eric Stephens, Oracle Enterprise Architect Bob Rhubart to guide the evolution of an organization’s ([email protected]) IT resources in the transition from today to behaviors,” says Stephens. Those cracks in is manager of the tomorrow and beyond. discipline can grow to seriously undermine architect community Governance is the process that ensures governance, which can undermine archi- on Oracle Technology an IT transition follows the company’s tecture—which in turn can cause a massive Network, the host of the architectural roadmap. It is “a set of increase in the amount of aspirin consumed Oracle Technology Network ArchBeat podcast guiding processes and directives for the by stakeholders. Reviving the conversation series, and the author of the ArchBeat blog operation of an IT function within a busi- about IT governance in your organization can (blogs.oracle.com/archbeat). ness,” explains Oracle Enterprise Architect reduce cranial pressure and help you to dust Eric Stephens. That seems rather impor- off the principles and practices on which Next Steps tant. So why isn’t there more conversation your IT foundation is based. about IT governance? Holding fast to those established prin- LISTEN to “Any time in an industry when you experi- ciples and practices will keep you grounded “By Any Other Name: Governance and Architecture” ence an explosion of something new, people when trends try to throw you off balance. bit.ly/UdnvVX tend to lose their memories and forget all “Big data, cloud, and mobile trends are “SOA Governance First Steps” of the principles and practices that came causing people to ask, ‘Now what do I do?’” bit.ly/SS5fiO before—that made them successful,” says says Hall. “What they need to do is what All ArchBeat podcasts Tim Hall, senior director of product manage- they’ve always done.” bit.ly/9X6j2T ment for Oracle Enterprise Repository, Oracle And that’s because the process for cre- READ more about IT governance “Leveraging Governance to Sustain Enterprise Service Registry, and Oracle Application ating successful architectures, whether Architecture Efforts” Integration Architecture. for new trends or not, is never completely bit.ly/TGcAlk And that’s understandable. Be honest: new. “People just need to hit the pause TOGAF framework and guidelines for when choosing conversation topics, are button for a second and very carefully think architecture governance bit.ly/TInlUs you more likely to go with innovation or about what they’re trying to achieve,” says “Is SOA Governance the Problem?” principles and practices? The latter may not Hall. “What they’ll find is that we’ve been bit.ly/RdMaFD be all that exciting, but those principles and exploring all these topics since the dawn of “SOA Governance Is a Matter of Balance” practices are what keep innovation from distributed systems. All the same problems bit.ly/YDbLvw running off the rails. are still in play here, and it’s not like we “Why Is Governance a Four-Letter Word?” “Excitement about new technologies can have to invent a ton of new things to over- bit.ly/PUuS3k cause people to take their eyes off the ball, come these challenges.“ Get more architect information oracle.com/technetwork/architect in terms of staying disciplined with their IT That doesn’t mean you can step into new

oracle magazine January/February 2013

JF13_architect.indd 25 11/29/12 2:47 PM 26 Up Close By Jeff Erickson

On Code Reviews and Standards A user group speaker gives development teams simple ways to succeed.

t was Martin D’Souza’s code that made static, two-page document that was written 5 I the entire project crumble. “I describe to 10 years ago.” A system of code reviews that it as a Jenga block tower,” he says. “My includes a discussion on standards is a simple code was the move that toppled the whole way to keep the coding standards document a thing.” Under pressure to fix the problem living and helpful resource, he says. with the applications, D’Souza, who is now For those who say that enforcing coding an Oracle ACE Director, spent a day asking standards limits creativity, D’Souza has a the question: “How did my team of talented simple rebuttal. “My usual response is that it coders get into this mess?” actually enhances creativity because devel- In analyzing what happened, the team opers are no longer worried about formatting realized that they didn’t really understand the details. They can concentrate on creative business problem. “Once we spent the time to ways to solve the business problem.” clearly state the business problem, we realized we could solve it pretty easily,” D’Souza says. Keep It Simple Hours of tedious review also reminded What keeps organizations from actively D’Souza that his team members were not pursuing code reviews and coding standards on the same page when it came to coding is a fear of the complex methodologies and standards. “We were all good coders, but we Oracle ACE Director Martin D’Souza procedures that often go with them. Better, all had our own styles and weren’t working as says D’Souza, to keep it simple. a team,” he says. learn from reviewing code with a more expe- “I think back to the original meltdown That project was many years ago, but the rienced person,” says D’Souza. “At the same that started me thinking about this,” answers he found and the simple steps he time, when you’re a senior developer and you D’Souza says. “If I had had a simple code now takes to avoid similar meltdowns have have to explain your own work, the lightbulb review in place, someone would have called become the basis of a talk D’Souza delivers might go on that your solution isn’t as solid me on it. They would have asked me about to user groups. I caught his talk, “Building as you thought.” the business problem, and I would have had a Better Team,” at a recent event held by For this reason, D’Souza recommends to tell them in plain English how I was going ODTUG, where he is a board member. that teams keep code reviews as a one-on- to solve it. I wouldn’t have been able to.” one process. He suggests having everyone He won’t make that mistake again.  Two easy Answers put his or her name on a Post-it note on a D’Souza recommends two simple practices whiteboard. When someone needs to have Jeff Erickson that can help development teams succeed: code reviewed, he or she pulls the top name. (jeffrey.x.erickson@ code reviews and coding standards. “You don’t want the same people looking at oracle.com) is a senior “Code reviews are the simplest way to each other’s code all the time,” D’Souza says. editor with Oracle reduce bugs,” says D’Souza. “You will find “And the first question we ask in code review Publishing. small bugs that might not be caught by your is always ‘What is the business problem QA team, testing team, or even automated you’re trying to solve?’” testing software.” D’Souza also recommends keeping up-to- Next Steps But, says D’Souza, code reviews can have date coding standards, which provide guide- more-extensive benefits for a development lines for, among other things, how to format READ Martin D’Souza’s blog team. When a junior developer has to review code, handle exceptions, and ensure applica- talkapex.com well o a senior developer, it’s a learning process for tion performance. “Many organizations have WATCH the interview

oracle.com/oramag/upclose H ul S. a both developers. “The junior developer can code standards,” he says. “But they are often a P

January/february 2013 Oracle.com/oraclemagazine

JF13_UpClose.indd 26 11/29/12 2:55 PM Peer-To-Peer by Blair Campbell 27

Green Is Good Peers use performance optimization, e-readers, and mobile solutions to do their part.

Kellyn Pot’Vin Giuseppe Maxia Rolando Carrasco

Company: Enkitec, a tech consulting firm Company: Continuent, a provider of database Company: S&P Solutions, a firm specializing in focused on Oracle solutions clustering and replication management software service-oriented architecture (SOA) and business Job title/description: Senior technical Job title/description: Quality assurance process management (BPM) architecture consultant, responsible for performance tuning, director, leading QA operations for the Job title/description: Oracle Enterprise Manager 12c installations and development and release of software products director, creating business opportunities in the configurations, and systems management Location: Cagliari, Sardinia, Italy Latin American market and delivering successful Location: Westminster, Colorado projects to clients, with a focus on Oracle Fusion Oracle credentials: Oracle Certified Middleware, SOA, and BPM solutions Length of time using Oracle products: Professional (MySQL 5.0 Developer, MySQL 5.0 15 years Database Administrator), with 12 years of Location: Mexico City, Mexico experience using Oracle products Oracle credentials: Oracle Unified Business Process Management Suite 11g Certified How did you get started in IT? After recov- Implementation Specialist, Oracle Service Oriented Architecture Infrastructure ering from strokes in my 20s, I was unable to What advice do you have about getting into Implementation Certified Expert, and Oracle return to my previous career. I started selling software development? The current trend is Application Grid Implementation Specialist computers at a national electronics store and being cloud-ready. Many tools and applica- found I had a knack with software. I took a tions that work well in traditional infrastruc- position with a telecommunications company tures may have trouble when deployed in the What’s your favorite tool on the job? I’ve as desktop support and became known as an cloud. Understanding the differences and been working with Oracle WebCenter Sites expert in Oracle application configuration. being able to adapt to this trend is vital for for the last few months, and it’s a great Which new features in Oracle tech- survival in IT. product for Web content delivery that should nologies are you finding most valuable? How are you using social media in your be considered for any company with needs Enhancements in Oracle Enterprise Manager work? I use it to get informed on my work- around Web presence and content pub- 12c such as metric extensions, which allow related and personal interests, and to lishing. It really creates a whole new Web administrators to create their own specific interact quickly with friends, colleagues, management experience. metrics to monitor by, and service tests and and acquaintances. Tools such as Twitter How are you using social media in your work? beacons, which allow them to record a Web are also extremely useful while on the road I use Twitter to share my work, and I also transaction and then set the test up on an and attending conferences—to organize blog at oracleradio.blogspot.com. My blog interval to verify that service is accessible. impromptu meetings, stay up to date on is targeted to the Spanish-speaking Oracle What green practices do you use in your the action, and spread the news. I also use community. I’ve been doing it since 2007, work? By eliminating CPU, I/O, and memory specialized social tools for personal matters and I normally write about the SOA and resource waste, I try to extend the life of such as book reviews and fitness. BPM stack. existing hardware—which in turn keeps older What green practices do you use in your What’s your go-to Oracle reference book hardware out of landfills. Rarely do we hear development work? We all work from home. these days? I normally rely on the books from about performance-enhancing procedures No need for office space and commuting. Packt Publishing. The authors are people who as a greener option for our environment, but We can hire the best talent without requiring have implemented the products, so what they I strive to show my company the savings and relocation, and our virtual work arrangement write comes from experience. In Mexico, I environmental value of having optimization also reduces the need for—and the useful- can’t easily get the print books from Packt, so exercises performed on a regular basis. ness of—printed paper. I generally read them on my Kindle. 

Learn more about the Oracle ACE program at oracle.com/technetwork/community/oracle-ace.

oracle magazine January/February 2013

JF13_peer.indd 27 11/29/12 3:07 PM 28

JF13_AwardsOpener_R2.indd 28 12/12/12 12:07 PM 29 2012 ORACLE EXCELLENCE AWARDS Oracle recognizes leaders who engineer innovation. BY DAVID A. KELLY, WITH ADDITIONAL REPORTING BY PATTY WADDINGTON

Oracle customers and partners continually discover innovative ways to deploy successful, groundbreaking solutions and establish best practices using Oracle technology. The Oracle Excellence Awards recognize customers and partners that have excelled in driving business value together with Oracle. This year, the Oracle Excellence Awards include 12 different award programs—with new programs for 2012—that reach across efforts ranging from leadership and tech- nology to enterprise sustainability and database administration.

The Oracle Excellence Awards include the zation; the JAVA BUSINESS INNOVATION award, CIO OF THE YEAR awards for global leaders for extreme innovation in the world of Java demonstrating outstanding performance technology; the ORACLE PARTNERNETWORK and vision in the role of chief information SPECIALIZED PARTNER OF THE YEAR awards, officer of an enterprise that uses Oracle prod- updated this year to include regional and ucts and services; the TECHNOLOGIST OF THE global programs, for excellence in database, YEAR awards, recognizing individuals for their middleware, applications, server and storage, extraordinary efforts and contributions to industry, Oracle on Oracle, and midsize cat- enterprise technology solutions as IT man- egories; the DATA WAREHOUSE LEADER OF agers and architects for cloud, virtualization, THE YEAR award, recognizing an individual and enterprise solutions; the LEADERSHIP who demonstrates excellent technical ability awards, new this year, recognizing chief and superior knowledge of Oracle data ware- financial officers, chief marketing officers, house technologies and consistently applies chief operating officers, and chief human best practices while demonstrating lead- resources officers worldwide who have dem- ership; the ORACLE FUSION MIDDLEWARE onstrated outstanding leadership and tech- INNOVATION awards, for customers using nology vision in the successful deployment of Oracle Fusion Middleware to deliver excep- Oracle solutions to simplify IT, power innova- tional business value; the ECO-ENTERPRISE tion, and drive transformational change in INNOVATION awards, for customers and their their respective lines of business or organiza- partners that are using Oracle products to tions; the new DATABASE ADMINISTRATOR OF reduce their environmental footprint while THE YEAR award, given to an individual who reducing costs; and the PROACTIVE SUPPORT: demonstrates excellent technical ability and CHAMPION awards, for customers or partners superior knowledge of Oracle Database and driving the proactive adoption of support Oracle engineered systems within the organi- tools and resources.

ORACLE MAGAZINE JANUARY/FEBRUARY 2013

JF13_AwardsOpener_R2.indd 29 12/12/12 12:07 PM ORACLE EXCELLENCE AWARDS

CIO OF THE YEAR | JAPAN Seiji Nishikawa Communication infrastructures support tens of millions of devices and drive new business initiatives at giant telecom.

or Seiji Nishikawa, executive vice presi- commitments to information system strate- DOCOMO is pursuing several new business dent and CIO of Japan’s NTT DOCOMO gies, and strong leadership to guide proj- opportunities, such as providing advanced Ftelecommunications company and ects to their successful conclusion without mobile services, creating partnerships with winner of the Oracle Excellence Award for CIO fearing the risks,” says Nishikawa. other industries and services, and providing of the Year—Japan, being a good CIO requires That’s no small task for the CIO of one of new cloud computing services. more than just technical knowledge. It also Japan’s biggest telecommunications com- “Our most important mission is to secure requires fearlessness. panies. NTT DOCOMO is a ¥4 trillion mobile the communication infrastructures needed “CIOs need a thorough knowledge of IT telecommunications carrier supporting to link people to each other,” says Nishikawa. and the business, an ability to accurately more than 60 million mobile phones. Like “That’s why our information systems have explain the value of IT, an ability to negotiate many telecommunications companies, NTT to be reliable at mission-critical levels. Additionally, to create new value and tackle the challenge of new markets, our informa- tion systems must feature low latency and high scalability. Oracle provides solutions that meet all these requirements.” According to Nishikawa, NTT DOCOMO takes a best-of-breed approach to systems development, which has resulted in the com- pany’s reliance on a range of Oracle solutions, including Oracle’s SPARC servers, Oracle Database (including Oracle Real Application Clusters and Oracle Data Guard), Oracle Fusion Middleware, and Oracle Exadata. “Not only does Oracle offer the high reli- ability, performance, and security mission- critical systems require, but it also continues to invest in developments to ensure con- tinuing innovation,” says Nishikawa. Nishikawa points out that one of the most significant tasks for a CIO is to develop team structures that ensure secure and stable oper- ation, but he doesn’t shy away from making big decisions or advocating for change. “Sometimes there’s a tendency for compa- nies to try to keep existing systems going for just a few more years,” says Nishikawa. “But I believe CIOs also need to take risks and dem- onstrate leadership in putting new systems and needed transformations in place.”

Name: Seiji Nishikawa Job title: Executive vice president and CIO Company: NTT DOCOMO Location: Tokyo, Japan

WINNER SPECS WINNER Award: CIO of the Year— Japan, 2012 JENSEN WALKER/GETTY IMAGES JENSEN WALKER/GETTY

JANUARY/FEBRUARY 2013 ORACLE.COM/ORACLEMAGAZINE

JF13_CIO_awards.indd 30 12/3/12 12:32 PM 31

Name: Victor Orlovski cs Job title: CIO Company: Sberbank Location: Moscow, Russia

er Spe nn er Award: CIO of the Year—

Wi Europe, Middle East, and Africa, 2012

In order to stay competitive, the company realized it needed to consolidate. “I championed the idea that we needed one single platform for every piece of function- ality across all regions,” says Orlovski. “But due to our size, we found that there were very few solutions worldwide that could meet our requirements for data consistency and performance. That’s why we selected Oracle solutions for the core of our new, unified architecture.” So far, Orlovski’s biggest challenge has been centralizing the massive amount of data for the bank’s core business and accounting functions to enable consistent growth and improve flexibility and time to market for the new products. That’s where solutions such as Oracle Database and Oracle GoldenGate come in. In addition, with its customer focus, Oracle CRM applications became a core component of Sberbank’s new IT architecture. With its consolidated architecture, Sberbank can look beyond existing day-to- day operations to new initiatives that will CIO of the Year | Europe, Middle East, and Africa drive future growth. For example, Orlovski envisions a time when Sberbank’s more than Victor Orlovski 1 million midsize business customers might buy trusted third-party products through Unified architecture opens door to innovation for Sberbank’s retail network. “Technology Russia’s biggest bank. becomes the biggest competitive driver,” says Orlovski. “It can become the biggest competitive advantage if used correctly, or o be successful as CIO, I have to evolve than 20,000 branches. The bank processes the biggest competitive disadvantage if not every day,” says Victor Orlovski, CIO of more than 160 million transactions a day, used correctly.” T Russia’s Sberbank and winner of the including 8.5 million face-to-face interac- For Orlovski, helping transform an insti- Oracle Excellence Award for CIO of the Year— tions. Its IT systems need to support more tution as large and historic as Sberbank is Europe, Middle East, and Africa. “I have to than 200,000 internal users, as well as 106 what keeps his job interesting. “Being CIO learn something new every day.” million consumers and more than 1 million of a bank like Sberbank is a big challenge Established in 1841, the Savings Bank of corporate customers. and really hard work,” says Orlovski. “But the Russian Federation (Sberbank) is now Five years ago, when Orlovski joined the there are very few projects going on around the largest credit institution in Russia and bank, it had a range of internal systems. the world that have as much potential to Commonwealth of Independent States “Legally, we were just one bank,” says bring big changes to so many people. It’s countries and has the second-largest Orlovski. “But from a technology perspective, a once-in-a-lifetime opportunity to build branch network in the world, with more we were 17 independent banks.” something special.”

oracle magazine January/February 2013

JF13_CIO_awards.indd 31 12/3/12 12:33 PM ORACLE EXCELLENCE AWARDS

Name: Dr. Jung Hee Song Job title: Senior executive vice president and CIO Company: KT Corporation Location: Seoul, Korea

WINNER SPECS WINNER Award: CIO of the Year— Asia Pacific, 2012

KT selected an integrated suite of Oracle Communications applications as the basis for its next-generation billing, service delivery, and operational support systems. The Oracle-based solution is helping KT to transform its business platform by enabling it to offer a broader range of integrated services while increasing customer satisfac- tion and reducing operational and network costs. In addition to Oracle Communications solutions, KT relies on a range of other Oracle products, including Oracle Database, Oracle Fusion Middleware, Siebel Customer Relationship Management, and Oracle WebLogic Server. For KT, Oracle was a natural fit for its next- generation infrastructure. “Oracle products have a solid track record in telecom,” says Dr. Song. When it came time to implement the new systems, KT decided to keep customization to a minimum. While Song and her team did need to make some modifications for spe- cific tax and regulatory requirements related to the Korean market, they tried to use the off-the-shelf Oracle solutions as much as possible. That not only minimized system CIO OF THE YEAR | ASIA PACIFIC implementation costs but also delivered the added benefit of changing the company’s Dr. Jung Hee Song business processes and best practices to global standards. KT’s business and IT trans- Customer-focused growth drives business formation project started in 2010 and will be transformation for Korean telecom. completed in 2014. Being CIO is a demanding job, but seeing the business transformation that the new IT t’s not unusual for large companies Hee Song, senior executive vice president and systems have helped bring about within KT is to create IT solutions focused on their CIO of KT and winner of the Oracle Excellence very satisfying for Song. “We’ve moved from Iemployees. But Korea’s KT Corporation, a Award for CIO of the Year—Asia Pacific. being a traditional, hierarchically oriented global leader in telecommunications, chose In 2009 KT merged with its mobile company to a more transparent and dynamic a different approach. It designed its new IT subsidiary, KTF, to provide both fixed and one, where employees are free to commu- architecture around its customers. wireless communications services. As CIO, nicate and collaborate,” says Song. “It not “Rather than just focus on making an one of Song’s key challenges was not only to only allows us to bring products and services efficient IT system, we tried to build a new IT integrate the two different core systems from to market more quickly, but our employees system that could align all our services into the individual companies, but to do so from actually get more satisfaction from being

one package for the customer,” says Dr. Jung the perspective of the customer. more productive and effective.” IMAGES KIM/GETTY JAE-HYUN

JANUARY/FEBRUARY 2013 ORACLE.COM/ORACLEMAGAZINE

JF13_CIO_awards.indd 32 12/3/12 12:33 PM 33

CIO of the Year | North America Cormac Lynch Consolidation brings process improvements to business—and recognition to IT.

IOs often face decisions about how cations, we knew we had no choice but to cuts to success,” says Lynch. “The key has much change they should attempt to implement all of the desired improvements been to balance the local demands of opera- C drive through an organization. But for at once,” says Lynch. Knowing they’d only tions with the company’s goal of standard- Cormac Lynch, CIO of the Rig Solutions Group have one shot to reengineer NOV’s systems ization, while maintaining our customer at National Oilwell Varco (NOV) and winner and business processes, Lynch and his team commitments.” of the Oracle Excellence Award for CIO of the decided to go all in—from replacing legacy A Fortune 200 company, NOV provides Year—North America, being overly conserva- enterprise resource planning (ERP) systems products and services to the oil and gas tive on project scope was not an option. across diverse engineer-to-order manufac- industry. NOV has experienced dramatic “We were challenged with legacy IT turing locations to implementing complete growth over the last 10 years, both organic systems that had been operating for more product lifecycle management, master data and through numerous acquisitions. While than 20 years and could no longer support management, and business intelligence. all that growth has been good for the bottom new business capabilities, and due to the “We realized the magnitude of this line, it led to several systems with duplicate dependency required among various appli- project but also knew there were no short- functionality, including more than 30 legacy ERP systems in the Rig Solutions Group. To solve the problem, NOV initiated a con- solidation project focused on reducing the number of legacy systems through migra- tion to a set of Oracle-based solutions. The company standardized on Oracle E-Business Suite for core business processes, Oracle’s Demantra for spare parts forecasting, and Oracle Fusion Middleware SOA solutions for integration. So far, NOV has rolled out the new Oracle-based solution to 11 of its 35 global manufacturing locations, with addi- tional ongoing deployments. “We used this project as a catalyst to change the organizational culture,” says Lynch. “In four years, we’ve transformed the organization from one in which users didn’t necessarily see a lot of value in IT to one where our users understand how much value a good IT structure can provide.” His team’s focus isn’t on the IT systems themselves, says Lynch; it’s on how those systems can drive process improvements and make things more efficient for NOV while providing real-time information that’s accurate, complete, and up to date.

Name: Cormac Lynch cs Job title: CIO, Rig Solutions Group Company: National Oilwell Varco Location: Houston, Texas

er Spe nn er Award: CIO of the Year—

Wi North America, 2012 Paul S. Howell S. Paul

oracle magazine January/February 2013

JF13_CIO_awards.indd 33 12/3/12 12:33 PM ORACLE EXCELLENCE AWARDS

Name: Leandro Balbinot Job title: CIO, December 2008– October 2012 Company: Lojas Renner Location: Rio Grande do Sul, Brazil

WINNER SPECS WINNER Award: CIO of the Year— Latin America, 2012

Suite in 2006 and was one of the first companies in Brazil to deploy Oracle Retail applications. Since then, Lojas Renner has deployed other Oracle solutions, including Oracle Exadata, Oracle Exalogic, and Oracle SOA Suite. In 2010, the company started using Oracle Managed Cloud Services (for- merly Oracle On Demand) for deploying a range of IT solutions. Oracle Managed Cloud Services is a good fit for Lojas Renner because it helps the company eliminate the need to find and hire qualified Oracle engineers. But that’s not all. “Having the best possible experts directly from Oracle supporting our system is a great solution,” says Balbinot. “Oracle Managed Cloud Services has a robust and flexible infrastructure model that allows Lojas Renner to grow fast, and without being con- cerned about setting up new infrastructure.” As CIO from 2008 through 2012, Balbinot valued Lojas Renner’s relationship with Oracle. “Oracle doesn’t come to sell prod- ucts,” says Balbinot. “Oracle comes to understand problems and is able to help Lojas Renner to identify solutions that fit the company’s needs.” CIO OF THE YEAR | LATIN AMERICA The result has been an IT strategy built around innovative solutions, from early use of kiosks within Lojas Renner stores Leandro Balbinot to deployment of new solutions via Oracle Apparel retailer speeds IT change to drive business growth. Managed Cloud Services. “Innovative IT has always been important for Lojas Renner,” says Balbinot. “The focus has been on hen your business is fashion, you his work as CIO of Lojas Renner. “It basically deploying consistent, robust, flexible, and need to be able to change fast. guarantees a big reduction in stock-outs at scalable solutions to guarantee that Lojas WThat’s why one of Brazil’s largest the stores. So far it’s made a big impact and Renner will be prepared to grow fast in the apparel retailers relies on Oracle. big difference in the distribution and sales of next 10 to 20 years.” In 2011 and 2012, Lojas Renner imple- special products whose sales vary by region.” From Balbinot’s perspective, a good CIO mented a completely new supply chain Lojas Renner is the second-biggest has to know technology, but these days, he or strategy using its Oracle Retail solution. apparel retailer in Brazil, with more than 230 she also needs to know the business. “A good “With Oracle Retail and our new push-pull stores and more than 19,000 employees. CIO can’t hide behind technology anymore,” inventory model, Lojas Renner can be much Its revenues for 2011 were approximately says Balbinot. “Instead, a CIO needs to be at more precise in its inventory,” says Leandro US$1.6 billion. the table discussing important business pri- Balbinot, winner of the Oracle Excellence The company has used Oracle solutions orities and advising what types of IT invest-

Award for CIO of the Year—Latin America for for years. It implemented Oracle E-Business ments the company should make.” FRIDMAN PAULO

JANUARY/FEBRUARY 2013 ORACLE.COM/ORACLEMAGAZINE

JF13_CIO_awards.indd 34 12/3/12 12:34 PM 35

CIO of the Year | Global Business Unit Mark Dearnley Telecom redefines customer service with Oracle Communications and Oracle Retail applications.

ark Dearnley’s objective as CIO upgrading several of its legacy systems with tomers,” says Dearnley. “In the end, it comes of Vodafone UK is simple: “Our Oracle-based solutions. By standardizing on down to an awful lot of systems work, and MIT drivers are to help create an Oracle stack, automating its processes, that’s being powered by Oracle products.” the best possible experience for our cus- and avoiding costly IT customizations, As CIO, Dearnley is responsible for all of tomers,” says Dearnley, winner of the Vodafone hopes to improve business effi- the IT systems that support Vodafone’s 19 Oracle Excellence Award for CIO of the ciency compared to its existing systems. million customers in the UK. As such, he has Year—Global Business Unit. “Whether But the project isn’t just about possible to make sure that everything from customer they’re consumers or businesses, we want cost savings. It’s also about serving the cus- e-mails and call center interactions to billing to ensure that every experience they have tomer—in ways that other companies in the events and purchases and returns happens with us works really, really well.” highly competitive communications industry seamlessly and in an integrated way. That’s no easy task, considering that can’t match. Oracle applications are a big part of those Vodafone is one of the world’s largest com- “Reinventing our organization is all about seamless interactions. “We’re using a sig- munications services providers. To meet its changing our processes and ways of working nificant number of Oracle products across customer-service objective, the company is to meet the changing expectations of our cus- the whole of Vodafone,” says Dearnley. “But at Vodafone UK, the Oracle Communications and Oracle Retail applications are really powering the business transformation we’re going through and bringing us to the next level of customer service.” One way the new systems are enabling that transformation is through much faster availability of critical business data. “The Oracle Communications products are enabling us to rapidly transform the experi- ence we can give to our customers,” says Dearnley. “Oracle is enabling us to see every interaction we’re having with a customer in real time.” For Dearnley and his IT group, the choice to invest in an Oracle-based solution wasn’t hard. “With Oracle, we take things like scalability, reliability, and operability for granted. They’re not in debate,” says Dearnley. “What we were looking for were the ways the solutions work together to create an experience for our customers that sets us apart from the rest of the industry. And so far, we’re very pleased.”

Name: Mark Dearnley cs Job title: CIO Company: Vodafone UK Location: Newbury, England yt h e

er Spe nn er Award: CIO of the Year—

Wi Global Business Unit, 2012 J o h n Bl

oracle magazine January/February 2013

JF13_CIO_awards.indd 35 12/3/12 12:36 PM ORACLE EXCELLENCE AWARDS

TECHNOLOGIST OF THE YEAR | IT MANAGER Olgay Tas¸ Technologist leads top-to-bottom IT transformation for Turkish giant.

urkey’s largest internet service pro- Taş led TTNET’s aptly named Service vider, TTNET, knows what its 6 million Excellence Program, a wholesale transfor- T customers want—and can get it to mation that encompassed new customer them faster, thanks to a new IT environment relationship management (CRM), order that helped TTNET’s Olgay Taş earn the 2012 management, order integration, and Oracle Excellence Award for Technologist of orchestration middleware based on Oracle the Year—IT Manager. SOA Suite and Oracle WebLogic Server. The In less than 18 months, TTNET has entirely SOA-based architecture greatly increased the replaced its legacy systems with a next- modularity, flexibility, and extensibility of generation operations and business support TTNET’s IT environment. system based on Oracle technologies. More than 10,000 TTNET agents use the “By using Oracle solutions, we’ve moved new CRM applications. And with the new from a subscriber-focused business model infrastructure, TTNET has also significantly to a customer-focused model,” says Taş, improved its ability to launch new services, Name: Olgay Tas¸ product and service development director campaigns, and B2C and B2B offerings. Job title: Product and service at TTNET. “The new system provides a 360- “We’re able to bundle our convergent development director Company: TTNET A.S. degree view of the customer and makes services into different packages and easily Location: Istanbul, Turkey everything from customer support to sales design new campaigns,” says Taş. “Overall, WINNER SPECS WINNER Award: Oracle Excellence Award and marketing simpler for both customers we’ve decreased the time to develop new for Technologist of the Year— IT Manager, 2012

and our employees.” applications by a factor of three or four.” IMAGES ALI KABAS/GETTY

TECHNOLOGIST OF THE YEAR | VIRTUALIZATION Stephen Bartholomew Consolidation is just part of the story for Verizon enterprise architect.

or Verizon Enterprise Architect Verizon applications from dedicated physical Stephen Bartholomew, virtualization servers to virtualized servers running Oracle Fis about more than simply reducing VM on an Oracle stack. the number of servers. It’s really about “We selected Oracle VM over other virtu- optimizing price/performance. alization options because it was able to scale “Consolidation is a great story, but it up to the enterprise sizes that we needed in a only goes so far,” says Bartholomew, winner cost-effective way,” says Bartholomew. of the 2012 Oracle Excellence Award for The virtualization of Verizon’s systems Technologist of the Year—Virtualization. hasn’t just paid off in added efficiencies; it “The other side of the story is using virtu- has also made life easier for IT personnel. alization to take the applications we were Virtualization has allowed the IT group to shift running on specialized servers and shifting a lot of the work previously tackled over nights Name: Stephen Bartholomew them to Linux on Intel processors, while or weekends to the workday, making for a Job title: Enterprise architect and getting the same performance or better.” better work environment. distinguished member, technical staff Bartholomew is part of a network opera- “Everything we’ve virtualized and deployed Company: Verizon Location: Basking Ridge, New Jersey tions and network technologies group that has been successful,” says Bartholomew.

WINNER SPECS WINNER Award: Oracle Excellence Award creates and manages Verizon’s IT systems “That’s saying a lot when you’re supporting for Technologist of the Year— and applications. Over the past five years, 200,000 users on the internal Verizon Virtualization, 2012

the group has focused on shifting internal employee portal, like we are.” HOWELL S. PAUL

JANUARY/FEBRUARY 2013 ORACLE.COM/ORACLEMAGAZINE

JF13_Awards_Technologist.indd 36 11/30/12 2:20 PM 37

technologist of the Year | Enterprise Architect Arup Nanda Architect’s Oracle Exadata–based system delivers real-time data for worldwide resort company.

or Arup Nanda, senior director of With a presence in almost 100 countries, database architecture for Starwood Starwood requires IT systems able to handle FHotels and Resorts and winner more than 5,000 concurrent transactions of the 2012 Oracle Excellence Award for per second. Just as important, the company Technologist of the Year— Enterprise needs to accurately reflect what’s happening Architect, providing good service isn’t just across all its sales and marketing channels something his company’s hotels have to in a timely manner. To accomplish that, focus on. It’s also the core of the company’s Starwood turned to Oracle Exadata and new IT architecture. Oracle GoldenGate. Nanda helped to architect a transi- The new Oracle Exadata–based system tion from the worldwide resort company’s Nanda helped to design obtains real-time legacy mainframe to a new SOA. The new hotel data from around the world and quickly architecture allows the company to support makes it accessible to business stakeholders. Name: Arup Nanda interactions with a wide variety of front- “With our Oracle Exadata–based data cs Job title: Senior director of end sources, from Starwood’s Website to warehouse system, we can create real-time database architecture its call centers and even third-party sites campaigns to take advantage of high or Company: Starwood Hotels and

er Spe nn er Resorts Worldwide

etty Im ages sen /G such as Expedia. “Because we use a SOA- limited demand and optimize our inven-

Wi Location: Stamford, Connecticut based architecture and Java, we don’t have tory and profits,” says Nanda. “It has been a b rie l Award: Oracle Excellence Award to change our systems depending on who’s tremendously successful and really trans- for Technologist of the Year— Enterprise Architect, 2012

K enneth G requesting a transaction,” says Nanda. formed our business processes.”

technologist of the Year | Cloud Architect Kai Yu Dell Inc. engineer evangelizes cloud with best practices and innovative methodologies.

or Oracle ACE Director Kai Yu, winner series of best practices for virtualization of the 2012 Oracle Excellence Award and cloud computing, and he has shared Ffor Technologist of the Year—Cloud his expertise in numerous white papers and Architect and senior engineer at the Dell more than 30 Oracle Cloud technical presen- Oracle Solution Engineering Lab at Dell Inc., tations around the world. cloud computing may be in its infancy, but “At Dell, we’ve achieved a huge cost it’s still the future. savings and great improvement of flexibility “Cloud is in its early stages, but I think and manageability by implementing cloud- cloud computing is a long-term strategy based solutions,” says Yu. “Our group imple- that will play an important role in tomor- ments cloud computing models using Oracle row’s business,” says Yu. “For example, by technologies such as Oracle Real Application building private clouds, large businesses can Clusters, Oracle VM, and Oracle Enterprise Name: Kai Yu consolidate their IT infrastructure to increase Manager and provides the reference archi- cs Job title: Senior engineer/ the efficiency of IT as well as significantly tecture and the implementation best prac- solution architect improve their ability to adapt to the rapid tices of these cloud solutions based on Dell Company: Dell Inc. change of business.” PowerEdge servers and Dell network and

er Spe nn er Location: Round Rock, Texas

Wi Award: Oracle Excellence Award Yu has spent more than 17 years working storage solutions to help customers from for Technologist of the Year— with Oracle technology and solutions. Over different industries architect cloud solutions

ll H owe ul S. Cloud Architect, 2012 a P the past three years, he has developed a for their IT environments.”

oracle magazine January/February 2013

JF13_Awards_Technologist.indd 37 11/30/12 2:21 PM ORACLE EXCELLENCE AWARDS

CIO OF THE YEAR Left to right: , Chairman TECHNOLOGIST of the Board, Oracle; Cormac Lynch, National Oilwell Varco; Hari Bezwada, OF THE YEAR United States Army Program Executive Left to right: Olgay Office, Enterprise Information Tas¸, TTNET; Arup Systems; Marcos Pupo, Sales Senior Nanda, Starwood Vice President, Oracle, accepting Hotels and Resorts; for Leandro Balbinot, Lojas Renner; Steve Bartholomew, Seiji Nishikawa, NTT DOCOMO; Abby Verizon; Kai Yu, Wambach, US Women’s National Team; Dell Inc. Mark Dearnley, Vodafone UK; Sergey Ryabov, Sberbank, accepting for Victor Orlovski, Sberbank; Jung-Hee Song, KT Corporation; Jeb Dasteel, Chief Customer Officer, Oracle

LEADERSHIP LEADERSHIP: FINANCE—EUROPE, LEADERSHIP: HUMAN CAPITAL New in 2012 and held in conjunction with MIDDLE EAST, AND AFRICA MANAGEMENT—ASIA PACIFIC Oracle OpenWorld events worldwide, these Giulio Carone, Chief Financial Officer, Julie Carroll, Director, People and Capability annual awards honor the individual achieve- Enel S.p.A. Services, Leighton Contractors Pty Ltd. ments of chief financial officers, chief human resources officers, chief operating LEADERSHIP: FINANCE—ASIA PACIFIC LEADERSHIP: SUPPLY CHAIN MANAGEMENT— officers, and chief marketing officers world- Henry Hon, Group Chief Financial Officer, NORTH AMERICA wide in the categories of finance, human Telstra International Group Leslie Clark, Vice President, Engineering and capital management, supply chain manage- Supply Chain, Elkay Manufacturing Company ment, and marketing. LEADERSHIP: HUMAN CAPITAL MANAGEMENT—LATIN AMERICA LEADERSHIP: MARKETING—NORTH AMERICA LEADERSHIP: FINANCE—NORTH AMERICA Leonardo Fernandez, Senior Vice President John Miller, Chief Marketing Officer, NBC Frank Calderoni, Executive Vice President of Human Resources Operations, Nación Sports Group and NBC Universal and Chief Financial Officer, Cisco Systems Servicios S.A. LEADERSHIP: MARKETING—LATIN AMERICA LEADERSHIP: FINANCE—LATIN AMERICA LEADERSHIP: HUMAN CAPITAL Roni Cunha Bueno, Chief Marketing Officer, Jayme Gomes da Fonseca Júnior, Chief MANAGEMENT—EUROPE, MIDDLE EAST, Netshoes S.A. Financial Officer, Construtora Norberto AND AFRICA

Odebrecht S.A. Stephen Kelly, Chief People Officer, Logica PHOTOGRAPHY ORANGE

JANUARY/FEBRUARY 2013 ORACLE.COM/ORACLEMAGAZINE

JF13_Awards_Other.indd 38 12/3/12 12:50 PM LEADERSHIP Leadership in Finance winners with Oracle representatives (left to right): Jeff Henley, Chairman of the Board, Oracle; Dilson Zanatta, Construtora Odebrecht, Latin America (accepting on behalf of Jayme Gomes da Fonseca Júnior, Construtora Odebrecht); Henry Hon, Telstra International, Asia Pacific; Abby Wambach, US Women’s National Team; Giulio Carone, Enel S.p.A., EMEA; Frank Calderoni, Cisco Systems, North America; Jeb Dasteel, Chief Customer Officer, Oracle

DATABASE ADMINISTRATOR OF THE YEAR Left photo, left to right: Jörg Otto, IDS GmbH—Analysis and Reporting Services, a company of Allianz; Tom Kyte, Architect, Oracle; Rahul Pednekar, Bank of America

Right photo, left to right: Çetin Özbütün, Vice President of Data Warehouse and Language Technology, Oracle; Jangwon Park, SK 11st

DATABASE ADMINISTRATOR OF ORACLE DATABASE ADMINISTRATOR OF THE SPECIALIZED PARTNER OF THE YEAR YEAR—NORTH AMERICA THE YEAR Brand-new in 2012, the Database Rahul Pednekar, Database Administrator, The Specialized Partner of the Year awards Administrator of the Year award honors Bank of America recognize Oracle PartnerNetwork Specialized an individual who demonstrates technical partners for their commitment to delivering ability with and superior knowledge of Oracle JAVA BUSINESS INNOVATION innovative, specialized solutions and services Database and Oracle engineered systems The Java Business Innovation award rec- based on Oracle hardware and software. within his or her organization. ognizes achievement using the Oracle Java Embedded platform to drive innovation SPECIALIZED PARTNER OF THE ORACLE DATABASE ADMINISTRATOR OF THE within business or product development. YEAR—GLOBAL YEAR—EUROPE, MIDDLE EAST, AND AFRICA DATABASE: NEC Corporation Jörg Otto, Database Administrator, IDS John Sublett, Chief Technology MIDDLEWARE: Accenture GmbH—Analysis and Reporting Services, a Officer, Tridium APPLICATIONS: Deloitte Consulting company of Allianz SERVER AND STORAGE SYSTEMS: ORACLE DATABASE ADMINISTRATOR OF THE Maplesoft Technology YEAR—ASIA PACIFIC INDUSTRY: Mannai Trading Company Jangwon Park, Database Administrator, ORACLE ON ORACLE: Capgemini España, S.L.U. SK 11st ORANGE PHOTOGRAPHY ORANGE

ORACLE MAGAZINE JANUARY/FEBRUARY 2013

JF13_Awards_Other.indd 39 12/3/12 12:51 PM ORACLE EXCELLENCE AWARDS

JAVA BUSINESS INNOVATION SPECIALIZED PARTNER OF THE YEAR—GLOBAL John Sublett (left), Jeff Henley (left), Chairman of the Board, Oracle; Jack Gulas, Maplesoft Tridium; Judson Technology; Francisco Bermúdez, Capgemini España, S.L.U.; Kelley Althoff, Senior Vice O’Hara, US Women’s National Team; Patrick Sullivan, Accenture; Nabil President, Oracle Khalil, Mannai Trading Company; Akinori Itou, NEC Corporation; Nidal Haddad, Deloitte Consulting; Jeb Dasteel, Chief Customer Officer, Oracle

SPECIALIZED PARTNER OF THE YEAR— CLOUD COMPUTING: Deloitte Consulting REGIONAL SYSTEMS INTEGRATOR/RESELLER EUROPE, MIDDLE EAST, AND AFRICA INTEGRATION AND SOA: TechDemocracy APPLICATIONS MOMENTUM: KPIT DATABASE: Inforsacom Informationssysteme SECURITY AND IDENTITY MANAGEMENT: PwC ORACLE DATABASE APPLIANCE: Cintra Software GmbH ORACLE WEBCENTER: Keste and Services MIDDLEWARE: egabi Solutions GLOBAL SYSTEMS INTEGRATOR TECHNOLOGY ORACLE ON ORACLE: Cloud Creek Systems APPLICATIONS: Accenture MOMENTUM: Accenture SERVER AND STORAGE SYSTEMS: Maplesoft SERVER AND STORAGE SYSTEMS: Mannai REGIONAL SYSTEMS INTEGRATOR/RESELLER Technology Trading Company TECHNOLOGY MOMENTUM: Predictive ENGINEERED SYSTEMS MOMENTUM: Accenture INDUSTRY: Mannai Trading Company Technologies HARDWARE MOMENTUM: Maplesoft ORACLE ON ORACLE: Capgemini España, S.L.U. BI APPLICATIONS: KPI Partners Technology ORACLE ACCELERATE FOR MIDSIZE COMPANIES: CUSTOMER RELATIONSHIP MANAGEMENT: COMMUNICATIONS, MEDIA, AND Inoapps APEX IT ENTERTAINMENT INDUSTRY: eVerge Group and FINANCIAL MANAGEMENT/EPM SOLUTION: Fadel Partners SPECIALIZED PARTNER OF THE YEAR— Infosys CONSUMER AND RETAIL INDUSTRY: Deloitte NORTH AMERICA HUMAN CAPITAL MANAGEMENT: Infosys Consulting DATABASE AND CLUSTERING: Cloud Creek SUPPLY CHAIN MANAGEMENT AND EDUCATION INDUSTRY: Rolta Systems MANUFACTURING: Deloitte Consulting FINANCIAL SERVICES INDUSTRY: PwC BI AND DATA WAREHOUSING: MarketSphere GLOBAL SYSTEMS INTEGRATOR APPLICATIONS HEALTHCARE AND LIFE SCIENCES INDUSTRY: PwC

Consulting MOMENTUM: Deloitte Consulting PHOTOGRAPHY ORANGE

JANUARY/FEBRUARY 2013 ORACLE.COM/ORACLEMAGAZINE

JF13_Awards_Other.indd 40 12/3/12 12:51 PM 41

SPECIALIZED PARTNER OF THE YEAR—EUROPE, MIDDLE EAST, AND AFRICA Winners are pictured with Specialized Partner of the Year—North America winners. Specialized Partner of the Year—Europe, Middle East, and Africa winners pictured are, first from left: Francisco Bermúdez, Capgemini España, S.L.U.; seventh from left: Ashraf Gamal, egabi Solutions; eighth from left: Ruediger Rath, Inforsacom Informationssysteme GmbH; ninth from left: Ramchandra Pawar, Mannai Trading Company.

SPECIALIZED PARTNER OF THE YEAR—NORTH AMERICA Deloitte Consulting won several Specialized Partner of the Year—North America awards. Representatives of Deloitte are pictured with Oracle Chairman of the Board Jeff Henley. Left to right: Matt Osekowski, Rachel Dimeo, Jeff Henley, Nidal Haddad, Aaron Carson, Mark Twomey, Candice Philbrick, Mark Edwards, Gary Koopman

MANUFACTURING AND DISTRIBUTION INDUSTRY: DATA WAREHOUSE LEADER OF THE YEAR— on the uniqueness of their business case, Deloitte Consulting EUROPE, MIDDLE EAST, AND AFRICA business benefits, level of impact relative PUBLIC SECTOR INDUSTRY: TechDemocracy Ferhat Şengönül, Data Warehouse Systems, to the size of the organization, complexity OIL AND GAS INDUSTRY: Deloitte Consulting Database Administrator Manager, Turkcell and magnitude of implementation, and the SERVICES INDUSTRY: ADI Strategies DATA WAREHOUSE LEADER OF THE YEAR— originality of their architecture. UTILITIES: Accenture ASIA PACIFIC INDUSTRY MOMENTUM: PwC Chris Thompson, Database Administrator ORACLE EXALOGIC Manager, Coles Supermarkets Netshoes DATA WAREHOUSE LEADER OF DATA WAREHOUSE LEADER OF THE YEAR— Claro THE YEAR NORTH AMERICA UL The Data Warehouse Leader of the Year Jeff White, Vice President of Technology, Ingersoll Rand award recognizes an individual who demon- Strategic Database Services, Epsilon strates excellent technical ability and supe- ORACLE CLOUD APPLICATION FOUNDATION rior knowledge of Oracle data warehouse ORACLE FUSION MIDDLEWARE Mazda Motor Corporation technologies and consistently applies best INNOVATION Hotelbeds Technology practices while demonstrating leadership The Oracle Fusion Middleware Innovation Globalia Corporation and sharing experience both within and awards honor Oracle customers for their Nike outside of his or her business. cutting-edge solutions using Oracle Fusion Comcast Corporation

ORANGE PHOTOGRAPHY ORANGE Middleware. Winners are selected based

ORACLE MAGAZINE JANUARY/FEBRUARY 2013

JF13_Awards_Other.indd 41 12/3/12 12:52 PM ORACLE EXCELLENCE AWARDS

DATA WAREHOUSE LEADER OF THE YEAR Left to right: Çetin Özbütün, Vice President of Data Warehouse and Language Technology, Oracle; Jeff White, Epsilon; Mert Senguner accepting for Ferhat S¸engönül, Turkcell; Chris Thompson, Coles

ECO-ENTERPRISE INNOVATION Left to right: Robert Di Stefano, Earth Rangers Centre; Tapas Roy, Raqmiyat LLC; Jeovani Salomão, Memora Processos Inovadores; Rich Morrissey, Schneider Electric; Antonio Carlos Lins, Terracap; Ali Mohamed Al Ali, Health Authority—Abu Dhabi; Jeff Henley, Chairman of the Board, Oracle; Hedi Ago, Orlando Utilities Commission; Ian Winham, Ricoh Europe; Ramanan Ramakrishna, Infosys; Rob English, Hitachi Consulting UK; Fred Knapp, North County Transit District; Mike Workman, Axiom Storage Group, Oracle Consulting; Sookhyun Cho, Korean Air; Kenneth Chang, Oracle Consulting

ORACLE SOA AND ORACLE BPM ORACLE DATA INTEGRATION ECO-ENTERPRISE INNOVATION NTT DOCOMO Raymond James The Eco-Enterprise Innovation awards honor Schneider National Wm Morrison Supermarkets customers for their use of Oracle products Amadeus to take an environmental lead, as well as to Navistar International ORACLE APPLICATION DEVELOPMENT reduce costs and improve business efficien- Motability FRAMEWORK AND ORACLE FUSION cies using green business practices. Partners DEVELOPMENT that help winning customers with their sus- ORACLE WEBCENTER Qualcomm Incorporated tainability initiatives are also honored. News Limited MICROS Systems University of Louisville Marfin Egnatia Bank CUSTOMERS AWARDED 2012 ECO- China Mobile Jiangsu ENTERPRISE INNOVATION AWARDS: Life Technologies BUSINESS ANALYTICS (ORACLE BI, ORACLE Dena Bank Los Angeles Department of Power and Water EPM, ORACLE EXALYTICS): Earth Rangers Centre for Sustainable INC Research Technology ORACLE IDENTITY MANAGEMENT Experian Grupo Pão de Açúcar Education Testing Service Hologic Health Authority—Abu Dhabi Avea Korean Air North County Transit District

Orlando Utilities Commission (OUC) PHOTOGRAPHY ORANGE

JANUARY/FEBRUARY 2013 ORACLE.COM/ORACLEMAGAZINE

JF13_Awards_Other.indd 42 12/3/12 12:53 PM 43

ORACLE FUSION MIDDLEWARE INNOVATION Left to right: Hasan Rizvi, Executive Vice President, Middleware Development, Oracle; Olivier Muller, Amadeus; Mark Foster, Principal Solutions Architect, Oracle; Loukas Rougkalas, Amadeus; Emmanuel Viguie, Amadeus

PROACTIVE SUPPORT: PROACTIVE SUPPORT: INDIVIDUAL CHAMPION EXECUTIVE CHAMPION Left to right: Alan Hall, Left to right: Chuck Senior Manager, Oracle Rozwat, Executive Vice Practice, Accenture President, Customer Australia; Medi Goker, Vice Support Services, Oracle; President of Customer Thomas Grimes, General Support, Proactive Support Electric Center, Oracle; Peter O’Brien, Manager, Oracle Competence Centre, Vodafone Group

Ricoh Europe PLC Europe is a multinational imaging and elec- PROACTIVE SUPPORT: EXECUTIVE CHAMPION Schneider Electric tronics company with a strong commitment Thomas Grimes, Chief Information Officer, Severn Trent Water to sustainability. Winham was honored for Global Enterprise Resource Planning and Terracap (Development Agency of the his leadership in reducing Ricoh’s environ- Data Services, General Electric Federal District) mental impact by leveraging Oracle’s applica- tions and underlying technology. PROACTIVE SUPPORT: INDIVIDUAL CHAMPION PARTNERS AWARDED 2012 ECO-ENTERPRISE Peter O’Brien, Manager, Oracle Competence INNOVATION AWARDS: PROACTIVE SUPPORT: CHAMPION Centre, Vodafone Group Hitachi Consulting UK The Proactive Support Executive Champion Infosys and Proactive Support Individual Champion PROACTIVE SUPPORT: INDIVIDUAL CHAMPION Memora Processos Inovadores awards honor Oracle customers or partners Alan Hall, Senior Manager, Oracle Practice, Raqmiyat LLC for driving the proactive adoption of tools Accenture Australia TeamCain and resources within their own or their cus- tomers’ companies. CHIEF SUSTAINABILITY OFFICER Oracle also awarded Ian Winham, execu- PROACTIVE SUPPORT: EXECUTIVE CHAMPION NEXT STEPS tive vice president and chief financial Vincent Biddlecomb, Executive Vice President officer at Ricoh Europe, with Oracle’s Chief and Chief Technology Officer, Transplace, MEET the winners oracle.com/us/corporate/awards

ORANGE PHOTOGRAPHY ORANGE Sustainability Officer of the Year award. Ricoh accepting on behalf of the Transplace IT team.

ORACLE MAGAZINE JANUARY/FEBRUARY 2013

JF13_Awards_Other.indd 43 12/3/12 12:54 PM Oracle Cloud Applications, Platform, Infrastructure

Oracle Oracle Managed Cloud Private Cloud

F I and R E and W A L L

Our Data Center Your Data Center

Run some of your applications in theYo Oracleu Cloud and others in your Private Cloud. You Choose.

Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Oracle and Java are registered trademarks of Oracle and/or its affiliates.

omg0113p044.indd 1 12/4/12 1:22 AM

PUB NOTE: Please use center marks to align page. Print Ad Job No.: 213M_CLD_OracleCloud2 PRODUCTION NOTES READER LASER% RELEASED Headline: O Cloud - Apps, Platform, Infrastructure Date: 10/24/2012 Project: Master Print Ad 10/24 Type: Magazine 01 2012 7.875” x 10.5” Live: 7.375” x 10” Trim: 7.875”x 10.5” Please examine these publication materials carefully. Full Page Master Bleed: 8.625”x 11.25” Any questions regarding the materials, Fonts: Univers LT Std. 75 Black, 65 Bold, 55 Roman, 45 Light, please contact Darci Terlizzi (650) 506-9775 67 Bold Condensed, 57 Condensed Database Application Developer | PL/SQL PL/SQL 101 BY STEVEN FEUERSTEIN 45

ORACLE DATABASE Wrap Your Code in a Neat Package Part 11 in a series of articles on understanding and using PL/SQL

ost PL/SQL-based applications consist Consider its advantages: Minimize program unit recompilation. M of hundreds of thousands of lines of Group related functionality. One of the most External programs (not defined in the code—and many likely run into the millions— fundamental benefits of a package is that package) can call only subprograms listed in that meet detailed, ever-changing user it can group related functionality and then the specification. If you change and recompile requirements. Business logic is implemented make that functionality available through the package body, those external programs primarily in procedures and functions, but an API. Rather than having to look through will not be invalidated. Minimizing the need PL/SQL developers need to decide where to hundreds of thousands of separate proce- to recompile code is a critical factor in admin- put those procedures and functions. In this dures and functions, you find the package istering large bodies of application logic. article, I explore how to use packages to orga- that contains the functionality you need There are many reasons to use packages, nize and expose an application’s functionality (which should be easily identifiable by its but first you need to know how to build them in ways that make it easier to build, maintain, name) and then drill down to the subpro- and take advantage of their unique features. and optimize the code base. grams you need within it. And when you In this article, I start with a simple package A package is a grouping or packaging need to add new programs to your applica- that demonstrates the power of this appli- of elements of PL/SQL code into a named tion, the package offers a “home” for that cation building block. Then I explore two program unit, stored in the database. functionality. Without packages, developers key features—package-level data and over- Packages provide a structure (both logically have a much harder time understanding loading—in more detail. and physically) in which you can organize and maintaining their code. your programs and other PL/SQL elements Hide implementation details. With a A SIMPLE PACKAGE EXAMPLE such as cursors, TYPEs, and variables. They package, you choose what to put into the Suppose that my employees table is defined also offer significant functionality, including specification for everyone to see and use and as follows: the ability to hide logic and data from view what to put into the body, which is visible and to define and manipulate “global” or only to the owner of the package. This ability SQL> desc employees session-persistent data. to hide implementation details has two A package always has a specification, critical benefits: First, you can change the Name Type which defines the package items that can be implementation without changing the speci- ———————————————————— ———————————————————— referenced from outside the package. Most fication. This means that all the programs EMPLOYEE_ID NUMBER(38) packages also have a body, which imple- that call procedures and functions in the FIRST_NAME VARCHAR2(30) ments any subprograms (procedures and package do not have to change. This feature LAST_NAME VARCHAR2(50) functions) in the package. The body can also greatly increases the flexibility you have contain private items, such as package-level for enhancing your code while limiting the I need to write a procedure, process_ variables and types, which can be referenced impact on the application. Second, you can employee, that retrieves the “full name” (last only from within the package. A package hide implementation details you don’t want name comma first name) of an employee and body can also have an initialization section, users of the package to be aware of. then performs other tasks. That’s easy enough which developers use to implement complex Improve performance. The first time you to do in PL/SQL, as shown in Listing 1. setup steps and validation for a package. invoke an element in a package, Oracle Although this code may work fine today, Database loads the entire package into it contains several “time bombs” that could WHY PACKAGES? memory. Subsequent references to other cause problems in months or years to come, The package is a powerful and important elements in the same package require no including the following: element of the PL/SQL language. It should, additional disk I/O. Also, package-level vari- • The length of the l_fullname variable is fixed in fact, be the fundamental building block of ables can be used as a session-level cache, at 100. I would have preferred to use %TYPE any PL/SQL-based application. What makes offering a variety of ways to reduce the time to declare the variable, but the full name is

I-HUA CHEN I-HUA the package so powerful and important? it takes to access data. a derived value and there is no column with

ORACLE MAGAZINE JANUARY/FEBRUARY 2013

JF13_PLSQL.indd 45 11/29/12 3:31 PM 46 PL/SQL 101

which I can attach %TYPE. So I just figured Code Listing 1: The process_employee procedure that 100 would be “big enough.” And it will

be—until the DBA increases the maximum CREATE OR REPLACE PROCEDURE process_employee ( length of either of these columns. employee_id_in IN employees.employee_id%TYPE) IS • The formula that produces a “full name” has l_fullname VARCHAR2(100); been placed right inside this procedure. And BEGIN there’s a good chance that the same concat- SELECT last_name || ',' || first_name INTO l_fullname enation appears over and over again in my FROM employees code. Why not? It’s such a simple formula! WHERE employee_id = employee_id_in; Ah, but what do I do when the users call me ... END; with some news: “We’ve changed our minds. We want to see the names as first name space last name in all reports and mes- Code Listing 2: The employee_pkg specification sages.” Uh-oh. Now I have to scour my code

for all the last-comma-first constructions. 1 CREATE OR REPLACE PACKAGE employee_pkg • Finally, because it is so easy to write SQL 2 AS 3 SUBTYPE fullname_t IS VARCHAR2 (100); inside PL/SQL programs, the query itself 4 will likely appear in many places in my 5 FUNCTION fullname ( application. Repeating SQL statements 6 last_in employees.last_name%TYPE, 7 first_in employees.first_name%TYPE) can make it very hard to optimize the 8 RETURN fullname_t; performance of my code and keep up with 9 changing user requirements. 10 FUNCTION fullname ( 11 employee_id_in IN employees.employee_id%TYPE) It would be wonderful if I could write 12 RETURN fullname_t; this procedure in a way that avoids all the 13 END employee_pkg; hard-coding and repetition: write these things once—one definition of a “full name” Code Listing 3: Block calling the employee_pkg package datatype, one representation of the formula, and one version of the query—and then call CREATE OR REPLACE PROCEDURE process_employee ( them wherever they are needed. A package employee_id_in IN employees.employee_id%TYPE) offers the perfect repository for such single- IS source implementations. l_name employee_pkg.fullname_t; employee_id_in employees.employee_id%TYPE := 1; Consider the package specification in BEGIN Listing 2. l_name := employee_pkg.fullname (employee_id_in); The employee_pkg specification essen- ... END; tially lists the different code elements that will be available for use outside the package. In line 3, I declare my own datatype called procedure and see how I can use these recompile it. But all the programs that use the fullname_t that is a subtype of the VARCHAR2 packaged elements, which are referenced packaged elements will not need to change. type. In lines 5–8, I define a function called in the form package_name.element_name. Listing 4 is the implementation of the fullname that accepts a last name and a first As shown in Listing 3, I use the subtype to body of employee_pkg. name and returns the full name. (Note that declare the l_name variable, and I call the Lines 3–11 implement the first fullname the formula itself—last comma first—is not function instead of writing a query directly function, which is really nothing more than a visible in the package specification. That’s inside the function. wrapper around the last-comma-first formula. a good thing, as you will soon see.) In lines As a result, the code implementing the Lines 13–23 implement the second fullname 10–12, I declare a second function, also called formula and the SQL query have been moved function, which gets the first and last name for fullname. This version accepts a primary key out of my procedure; the resulting code is the specified employee and combines them by for an employee and returns the full name cleaner and simpler. The same will be true of calling the first fullname function. for that employee. Having two functions with all the other programs that need to work with So what happens when my users call and the same name is an example of overloading, the full name of an employee. say, “First-space-last, please!”? I will not which I explore in more detail below. Best of all, if I need to change the formula groan and work late into the night, hunting Even though I have not yet implemented for fullname or expand the maximum size of down occurrences of “|| ‘, ‘ ||” in my code. the two functions in this package specifica- the fullname_t datatype, I will simply make Instead, I will change the implementation tion, I can now revisit the process_employee the appropriate change to the package and of my employee_pkg.fullname function

January/February 2013 Oracle.com/oraclemagazine

JF13_PLSQL.indd 46 11/29/12 3:32 PM PL/SQL 101 47

in about five seconds flat, recompile the Code Listing 4: The employee_pkg package body package body, and astound my users by

announcing that they are ready to go. 1 CREATE OR REPLACE PACKAGE BODY employee_pkg And what happens when I upgrade 2 AS 3 FUNCTION fullname ( to Oracle Database 11g and discover the 4 last_in employees.last_name%TYPE, amazing PL/SQL function result cache? I 5 first_in employees.first_name%TYPE simply add the RESULT_CACHE clause to the 6 ) 7 RETURN fullname_t function headers, recompile the package, 8 IS and then enjoy the greatly reduced CPU 9 BEGIN cycles needed to repeatedly retrieve the full 10 RETURN last_in || ', ' || first_in; 11 END; name for the same employee. 12 Ah, the power of hiding implementation 13 FUNCTION fullname (employee_id_in IN employee.employee_id%TYPE) details in packages! 14 RETURN fullname_t 15 IS 16 l_fullname fullname_t; Package-Level Data 17 BEGIN Package-level data consists of variables and 18 SELECT fullname (last_name, first_name) INTO l_fullname 19 FROM employees constants that are defined at the package 20 WHERE employee_id = employee_id_in; level—that is, not within a particular func- 21 tion or procedure in the package. The fol- 22 RETURN l_fullname; 23 END; lowing package specification, for example, 24 END employee_pkg; declares one variable and one constant at the package level: Code Listing 5: DBMS_UTILITY.GET_CPU_TIME measures

CREATE OR REPLACE PACKAGE plsql_limits IS DECLARE l_start PLS_INTEGER; c_varchar2_length CONSTANT BEGIN PLS_INTEGER := 32767; /* Get and save the starting time. */ g_start_time PLS_INTEGER; l_start := DBMS_UTILITY.get_cpu_time; END; /* Run your code. */ FOR indx IN 1 .. 10000 When you declare a variable within a LOOP NULL; subprogram or a block, it is a local variable. END LOOP; Its scope is restricted to that block, and when the block terminates, the memory for that /* Subtract starting time from current time. */ DBMS_OUTPUT.put_line ( variable is released. DBMS_UTILITY.get_cpu_time - l_start); The scope of package data, however, END; / is not an individual program or block, but rather the package as a whole. In the PL/SQL runtime architecture, package data struc- Let’s take a look at how package-level Surely most developers have better ways tures persist (hold their values) for the dura- data can be of use to you. The DBMS_ to spend their time. Perhaps a package tion of a session (rather than the duration of UTILITY package offers a function named could help. Consider, for example, the timer execution of a particular program). GET_CPU_TIME that can be used to cal- package (timer_pkg) in Listing 6. If package data is declared inside the culate the elapsed time of your code with Before I explain the timer_pkg implemen- package body, that data will persist for the hundredth-of-a-second precision. The tation, let’s look at how the package makes session but can be accessed only by ele- anonymous block in Listing 5 demonstrates it easier for developers to use the GET_CPU_ ments defined in the package itself (private how to use this function to determine how TIME utility. My previous anonymous block, data). If, on the other hand, package data long it takes to do nothing 10,000 times. in Listing 5, now looks like this: is declared inside the package specification, That’s simple enough, but it also means that data will persist for the session and that a developer who wants to take advan- BEGIN will be directly accessible (for both reading tage of this utility has to declare a local vari- timer_pkg.start_timer; and modifying) by any program that has able to hold the starting time, remember FOR indx IN 1 .. 10000 EXECUTE authority on that package and write the formula (end minus start), and LOOP (public data). then display the value. NULL;

oracle magazine January/February 2013

JF13_PLSQL.indd 47 11/29/12 3:32 PM 48 PL/SQL 101

Code Listing 6: The timer_pkg package time analysis, I will have to change only the package body and all of my users will be able

CREATE OR REPLACE PACKAGE timer_pkg to instantly take advantage of the new and IS improved technique. PROCEDURE start_timer;

PROCEDURE show_elapsed (message_in IN VARCHAR2 := NULL); Subprogram Overloading END timer_pkg; Overloading occurs when you have two or / more subprograms with the same name in a

CREATE OR REPLACE PACKAGE BODY timer_pkg program unit. You can overload subprograms IS in any declaration section; that is, this feature g_start_time NUMBER := NULL; is not available only in packages. You will,

PROCEDURE start_timer however, find that almost all overloading IS occurs inside packages. And that’s because BEGIN overloading is most helpful in APIs. g_start_time := DBMS_UTILITY.get_cpu_time; END; Overloading can greatly simplify your life and the lives of other developers. When PROCEDURE show_elapsed (message_in IN VARCHAR2 := NULL) building an API, developers often find that IS BEGIN they need to execute the same kind of logic DBMS_OUTPUT.put_line ( but for different types of data or various sce- message_in narios that require different inputs. Without || ': ' || TO_CHAR (DBMS_UTILITY.get_cpu_time - g_start_time)); overloading, you would have to come up with a different name for each variation and start_timer; users of your code would need to remember END; END timer_pkg; which is which. / With overloading, the users of your package need to know only the one name Code Listing 7: The my_output package without overloading that describes the functionality needed. The compiler then does the rest of the work: it analyzes the arguments passed to the CREATE OR REPLACE PACKAGE my_output IS subprogram and matches them up with PROCEDURE put_string (value_in IN VARCHAR2); an overloading.

PROCEDURE put_boolean (value_in IN BOOLEAN); Let’s take a look at how you can use over- loading to make it easier to display informa- PROCEDURE put_date ( tion onscreen from within a PL/SQL block. value_in IN DATE, mask_in IN VARCHAR2 DEFAULT 'YYYY-MM-DD HH24:MI:SS'); Oracle Database includes the DBMS_ END my_output; OUTPUT.PUT_LINE procedure to send text / to system output. This procedure is not overloaded. There is a single implementation END LOOP; The timer_pkg package relies on a single accepting a single VARCHAR2 value. timer_pkg.show_elapsed ('10000 package-level variable, g_start_time, to So if you pass an expression to DBMS_ Nothings'); remember the starting time between calls to OUTPUT.PUT_LINE that evaluates to a END; subprograms in the package. This is possible VARCHAR2 value, it will work just fine. / only because of the session-level persistence Because numbers, for example, are implicitly of package data. converted to a string, the following statement No need to declare a local variable, no This timer package is also a nice example will result in the display of “100” onscreen: need to understand the way the GET_CPU_ of an API, a set of subprograms that offers TIME function works (or even that it exists). an interface to underlying functionality. The BEGIN Just call the appropriate subprograms and package specification lists the tasks you can DBMS_OUTPUT.PUT_LINE (100); see how well your code is performing. And perform, and the package body hides the way END; the timer_pkg package makes it easy to the timer is implemented, taking advantage, display a message with the timing and auto- in this case, of the GET_CPU_TIME function. If, on the other hand, you try to display matically reset the start time after showing If someday Oracle comes up with a better a Boolean expression, you will get an error the elapsed time. mechanism for doing this kind of elapsed message:

January/February 2013 Oracle.com/oraclemagazine

JF13_PLSQL.indd 48 11/29/12 3:33 PM PL/SQL 101 49

Code Listing 8: The my_output package with overloading The Building Blocks of Applications It is possible to build applications in PL/SQL

CREATE OR REPLACE PACKAGE my_output without using packages. You could, instead, IS create thousands of schema-level func- PROCEDURE put_line (value_in IN VARCHAR2); tions and procedures. If you take this path,

PROCEDURE put_line (value_in IN BOOLEAN); however, I guarantee that you will come to regret it. You will soon discover that it is dif- PROCEDURE put_line ( ficult to find code and even more challenging value_in IN DATE, mask_in IN VARCHAR2 DEFAULT 'YYYY-MM-DD HH24:MI:SS'); to change existing code in your applications. END my_output; I recommend that, instead, you always / put your procedures and functions inside packages and move as much of the code in SQL> BEGIN a user of this functionality to remember or triggers and object types into packages as 2 DBMS_OUTPUT.PUT_LINE (TRUE); look up the correct name. Is the procedure possible. You will then find your sprawling 3 END; for displaying a date named “put_date” or code base easier to manage, whether it is a 4 / “put_datetime” or maybe “put_timestamp”? matter of analyzing the impact of a proposed DBMS_OUTPUT.PUT_LINE (TRUE); With overloading, however, my package change or applying a fix with minimum * specification procedures are easy to impact on existing code. ERROR at line 2: remember or look up, as shown in Listing 8. Take full advantage of overloading to sim- ORA-06550: line 2, column 4: The listing includes three procedures, all plify the API you present to the users of the PLS-00306: wrong number or types of with the same name, because they all do package. Explore ways you can use package- arguments in call to ‘PUT_LINE’ the same thing: display data. All I, as a user, level data. have to remember is that I call a procedure to The next PL/SQL 101 article will examine This happens because PL/SQL does not “put/display a line of data.” I pass it the data working with cursors in PL/SQL, from support implicit conversions from Boolean to I want to display, and the PL/SQL compiler implicit queries and explicit cursors to VARCHAR2 datatypes. automatically figures out which of the over- cursor variables.  As a result, many developers write code loadings is the right one. like this when they want to display a Boolean: I like it when smart software takes care of Steven Feuerstein the “small details” so I can stay focused on (steven.feuerstein@ IF l_student_is_registered implementing user requirements. quest.com) is Quest THEN There are many rules and restrictions for Software’s PL/SQL DBMS_OUTPUT.PUT_LINE ('TRUE'); overloading, which are beyond the scope of evangelist. He has ELSE this article. Here are a few key points to keep in published 10 books on DBMS_OUTPUT.PUT_LINE ('FALSE'); mind as you start building your own packages: Oracle PL/SQL (O’Reilly Media) and is an Oracle END IF; • Overloadings almost always involve sub- ACE Director. More information is available at programs with different numbers and/or stevenfeuerstein.com. Now there’s a recipe for reducing your types of parameters, as you saw in the productivity and introducing bloat to your my_output package in Listing 8. Next Steps code. Overloading to the rescue! • You can overload a function and a proce- I would like to make it easy to display dure with the same parameter list. DOWNLOAD Oracle Database 11g Boolean values and date values that include • Make sure the datatypes of the parameters bit.ly/fherki the time stamp (an implicit conversion of across overloadings are not too similar; TEST your PL/SQL knowledge plsqlchallenge.com a date to a string using the default format you cannot, for example, overload two pro- READ mask ignores the time). cedures whose only difference is that one PL/SQL 101, Parts 1–10 Without overloading, I need to come up uses a CHAR parameter whereas the other bit.ly/omagplsql with different procedure names for each type uses a VARCHAR2 parameter. online-only article content of data, as shown in Listing 7. When you build overloaded modules, you bit.ly/XehFFv It’s not so hard to come up with the pro- spend more time in design and implementa- READ more about overloaded subprograms cedure names, but it is much more effort for tion than you might with separate, stand- bit.ly/SIrrvL alone modules. This additional up-front time Oracle Database’s Edition-Based The online version of this article at bit.ly/XehFFv will be repaid handsomely down the line, Redefinition feature includes this issue’s PL/SQL Challenge question because you and others will find it much bit.ly/PukSwc and the answer to last issue’s challenge. bit.ly/Qe3f5f easier to use your programs.

oracle magazine January/February 2013

JF13_PLSQL.indd 49 11/29/12 3:33 PM Great minds don’t think alike.

To continue to lead the way in technology and science, we must develop the next generation of innovators. Steps we take today can empower young people to develop and test their own ideas and approach science, technology, engineering, and math not just as fields of study in school but as ways of understanding our world.

Join the Lawrence Hall of Science in inspiring and preparing kids from all backgrounds to do science.

lawrencehallofscience.org/brilliant

JA_Oracle2.indd 8 5/21/11 3:56 AM DBA | Performance Tuning by Arup Nanda 51

Oracle Database 11g Beginning Performance Tuning: Active Session History Identify the root cause of performance issues at a precise point in the past—even when the sessions have disconnected.

n my previous two articles on the topic of which updates one row of the TEST1 table but session, but the session that caused the issue I performance tuning (bit.ly/SEzR6t and does not commit and therefore keeps the row in this article is no longer present. The other bit.ly/U7U5IJ), you learned how to identify locked. The fourth session executes the same important view, V$SESSION_EVENT, shows the cause of performance bottlenecks occur- script, which attempts to update the same all the wait events waited for by the session, ring in real time and view the summary row. But the row is locked by the third session, but, as with the V$SESSION view, it will show of what happened in the past. Although so the fourth session waits until the lock is the data only if the session is still active in these processes provide information to help gone and the row is available for locking. the database. The view V$SESSTAT shows resolve performance issues in many cases, The test1.sql and test2.sql scripts are the resource usage for a session and can offer there are times when you would like to know designed to consume significant amounts clues to which sessions have consumed what precisely what happened at a specific point in of CPU, so the first two sessions will be slow amount of a resource such as redo or memory. the past. In this article, you will learn how to due to CPU contention. These sessions will However, because all the sessions that expe- identify the precise sequence of events in the run for a very long time. rienced performance issues are historical, past in a historical—not current—session. After all the sessions have waited for looking into these views will not help resolve To run the examples in this article, about 10 minutes, stop the execution in ses- the issues. You need to determine the specific execute the setup.sql script available in the sions 1 and 2 by pressing Control-C to exit events that occurred at a point in time in his- Oracle-hosted online version of this article each SQL*Plus session. In session 3, enter torical sessions. If you had enabled tracing, (at bit.ly/SuIzls). The script creates a user commit and press Enter. This will release the the trace files would have shown the events, called ARUP and creates three tables: TEST1, lock on the row, and you will see session 4 but you did not expect these issues in advance TEST2, and TEST3. In the very rare event that show “1 row updated.” Exit SQL*Plus ses- and didn’t enable tracing, because tracing a user called ARUP already exists, modify sions 3 and 4. Now all the sessions con- would have degraded performance. So how do the script to create another user with a dif- nected as ARUP are closed—and history. you now identify the cause of the performance ferent name and replace all occurrences of issues suffered by these old sessions? ARUP with that name. The sample database Past Sessions created by setup.sql will take up less than In the setup, I showed you how to simulate Active Session History 200 MB of space in your database. performance issues in three of the four ses- Fortunately, looking at performance issues in After running the setup.sql script, open sions. If these were typical business applica- old sessions is easy with an Oracle Database four SQL*Plus sessions, connected as ARUP. tions, the applications would have showed feature called Active Session History. Note In three of these sessions, execute the test1 signs of slowdown, inviting the ire of the that the use of Active Session History .sql, test2.sql, and upd1.sql scripts, respec- respective application owners and users and requires Oracle Diagnostics Pack, a licensed tively. Here is an example of one session bringing unwanted attention to you, the option of Oracle Database available since running upd1.sql on a UNIX-based system: DBA. Now that you have that attention, what Oracle Database 10g Release 1. should you do next? Every second, Active Session History polls # sqlplus arup/arup In my previous two performance tuning the database to identify the active sessions SQL> @upd1.sql articles, you learned how to find the clues and dumps relevant information about each to the sources of performance issues in ses- of them—such as the user ID, state, the In the fourth session, execute upd1.sql sions. Unfortunately, those techniques will be machine it is connected from, and the SQL again. This last session will hang, because the of no help in this case. The V$SESSION view it is executing—into a special area in the third session has already executed upd1.sql, shows the reason for a performance issue in a system global area (SGA) of the database

oracle magazine January/February 2013

JF13_Tuning.indd 51 11/29/12 3:48 PM 52 Tuning

instance called the ASH buffer. So even captured this data on all active sessions. tive work—not in a WAITING state—this though a session is no longer present in the USER_ID. The numerical user ID (not the column will show how long the session database instance, the ASH buffer has cap- username) of the database user who created waited for the last wait event. tured its information. In addition, because this session. SQL_ID. The ID of the SQL statement the Active Session History records activities every SESSION_ID. The session ID (SID) of the session was executing at the time the second, it can show a second-by-second session. sample was taken. snapshot of the activities in a session. In SESSION_STATE. The state the session was SQL_CHILD_NUMBER. The child number of other words, Active Session History can show in when Active Session History took the the cursor. If this is the only version of the a movie of the activities of the session instead sample. It shows WAITING if the session was cursor, the child number will be 0. of a single picture. (Note that when the ASH waiting for something; otherwise, it shows Knowing the meaning of the V$ACTIVE_ buffer is filled, the data is written to disk and ON CPU to indicate that the session was SESSION_HISTORY columns, you can identify the snapshots are taken every 10 seconds doing productive work. what it was that historical sessions were rather than every second.) EVENT. If the session was in a WAITING waiting for. To begin the identification, you You can examine the contents of the ASH state (in the SESSION_STATE column), this need to pose two questions to the application buffer in a view named V$ACTIVE_SESSION_ column will show the wait event the session owners or users executing the SQL state- HISTORY. Here are a few of the important was waiting for. ments that experienced slow performance: columns of the V$ACTIVE_SESSION_ TIME_WAITED. If the session was in a 1. Which username was used to connect to HISTORY view: WAITING state, this column will show how the database? SAMPLE_ID. The unique identifier of the long it had been waiting when Active Session 2. What was the time interval (start and end Active Session History record. History took the sample. times) of the period when the perfor- SAMPLE_TIME. When Active Session History WAIT_TIME. If the session is doing produc- mance issues occurred?

Code Listing 1: Checking the past activities of all sessions of a user ARUP

col event format a30 col sample_time format a25 select session_id, sample_time, session_state, event, wait_time, time_waited, sql_id, sql_child_number CH# from v$active_session_history where user_id = 92 and sample_time between to_date('29-SEP-12 04.55.00 PM','dd-MON-yy hh:mi:ss PM') and to_date('29-SEP-12 05.05.00 PM','dd-MON-yy hh:mi:ss PM') order by session_id, sample_time;

SESSION SESSION_ID SAMPLE_TIME _STATE EVENT WAIT_TIME TIME_WAITED SQL_ID CH# —————————————— ————————————————————————————————————— —————————— ———————————————————————————————————————————— —————————————— ———————————————— —————————————————— ———— 39 29-SEP-12 04.55.02.379 PM WAITING enq: TX - row lock contention 0 0 fx60htyzmz6wv 0 39 29-SEP-12 04.55.03.379 PM WAITING enq: TX - row lock contention 0 0 fx60htyzmz6wv 0 39 29-SEP-12 04.55.04.379 PM WAITING enq: TX - row lock contention 0 0 fx60htyzmz6wv 0 39 29-SEP-12 04.55.05.379 PM WAITING enq: TX - row lock contention 0 0 fx60htyzmz6wv 0 39 29-SEP-12 04.55.06.379 PM WAITING enq: TX - row lock contention 0 0 fx60htyzmz6wv 0 39 29-SEP-12 04.55.07.389 PM WAITING enq: TX - row lock contention 0 0 fx60htyzmz6wv 0 … output truncated … 39 29-SEP-12 05.16.52.078 PM WAITING enq: TX - row lock contention 0 1310761160 44 29-SEP-12 04.55.34.419 PM WAITING resmgr:cpu quantum 0 109984 92ty3097fqfwg 0 44 29-SEP-12 04.55.35.419 PM ON CPU 110005 0 a5wts2yzmws18 0 44 29-SEP-12 04.55.36.419 PM WAITING resmgr:cpu quantum 0 110016 61q5r7d0ztn6n 0 44 29-SEP-12 04.55.37.419 PM ON CPU 109984 0 7bnf79qwyy9k8 0 44 29-SEP-12 04.55.38.419 PM WAITING resmgr:cpu quantum 0 107874 7b0jbugzatdcr 0 44 29-SEP-12 04.55.39.419 PM WAITING resmgr:cpu quantum 0 107962 fngb4y81xr57x 0 … output truncated … 46 29-SEP-12 04.57.18.555 PM ON CPU 110984 0 f7kmq72a8h7pt 0 46 29-SEP-12 04.57.19.555 PM WAITING resmgr:cpu quantum 0 110981 f7kmq72a8h7pt 0 46 29-SEP-12 04.57.20.555 PM ON CPU 110982 0 f7kmq72a8h7pt 0 46 29-SEP-12 04.57.21.555 PM WAITING resmgr:cpu quantum 0 111974 f7kmq72a8h7pt 0 46 29-SEP-12 04.57.22.555 PM ON CPU 112986 0 f7kmq72a8h7pt 0 46 29-SEP-12 04.57.23.555 PM WAITING resmgr:cpu quantum 0 111998 f7kmq72a8h7pt 0 46 29-SEP-12 04.57.24.555 PM WAITING resmgr:cpu quantum 0 108975 f7kmq72a8h7pt 0 … output truncated …

January/February 2013 Oracle.com/oraclemagazine

JF13_Tuning.indd 52 11/29/12 3:48 PM Tuning 53

Because you ran the setup script as the was in a WAITING state, the value of the statement with SQL_ID fx60htyzmz6wv and user ARUP, the answer to the first ques- WAIT_TIME column is irrelevant, so it shows child number (CH#) 0. tion is ARUP. Next, you need to find out the up as 0. Because the session was still in a You can get that SQL statement text with USER_ID of the ARUP user by issuing the WAITING state when Active Session History this query: following SQL: captured the state, the TIME_WAITED column shows 0. When the session finally select SQL_TEXT select user_id got the lock, it could do what it had to do from v$sql from dba_users and stopped waiting. At that point, the total where sql_id = 'fx60htyzmz6wv'; where username = 'ARUP'; time the session had waited was updated in Active Session History, shown in the first SQL_TEXT USER_ID boldface line in the Listing 1 output (sample ———————————————————————————————————————————————— ————————————— time 29-SEP-12 05.16.52.078): 1,310,761,160 update test1 set status = 'D' where 92 microseconds (shown in the TIME_WAITED object_id = :b1 column), or about 22 minutes. This is such an Now suppose the user told you that the important property of Active Session History The SQL statement includes an UPDATE performance issues occurred between that I repeat: Seeing 0 in the WAIT_TIME that had to lock the row. Because the 4:55 p.m. and 5:05 p.m. on September 29. column does not mean that the session didn’t row had already been locked by another With this information, you can query the wait at all. It simply means that the session session, it was not possible for this session V$ACTIVE_SESSION_HISTORY view to find was waiting for some event for more than one (SESSION_ID 39) to succeed and it therefore out the activities of the ARUP sessions (with second because the previous WAIT_TIME had to wait. The next logical questions from USER_ID 92) within that period, as shown in and TIME_WAITED column values showed 0. the user would perhaps be which specific Listing 1. (The output has been truncated to fit You should look at the last occurrence of the row on which table the SQL statement and the space available.) Because Active Session wait event (the EVENT column value) for that the session were waiting for and which History collects information on all active ses- session in Active Session History to determine session had locked the row. These are also sions, you need to order the output by SID, what the total wait time really was. very easy to find with the query shown in which identifies a session (shown under When you explain to your user that the Listing 2. The BLOCKING_SESSION column SESSION_ID), and then by the collection time cause of the delay was an unavailable lock shows the session that was holding the (shown under SAMPLE_TIME). during the period 04.55.02.379 PM to lock: the session with SESSION_ID 43. The Let’s examine the first row of the output. 05.16.52.078 PM, that person might ask Listing 2 output also shows the object ID It shows that the session identified by you what SQL statement the session was (CURRENT_OBJ#) of the table whose row SESSION_ID 39 was waiting for the “enq: executing at that time. That’s extremely easy was locked and other information neces- TX - row lock contention” event on 29-SEP-12 to get from the Listing 1 output: the session sary to get the row information. With the at 04.55.02.379 PM. Because the session with SESSION_ID 39 was executing the SQL data in the Listing 2 output, you can get

Code Listing 2: Finding the locked table and row information

select sample_time, session_state, blocking_session, current_obj#, current_file#, current_block#, current_row# from v$active_session_history where user_id = 92 and sample_time between to_date('29-SEP-12 04.55.00 PM','dd-MON-yy hh:mi:ss PM') and to_date('29-SEP-12 05.05.00 PM','dd-MON-yy hh:mi:ss PM') and session_id = 39 and event = 'enq: TX - row lock contention' order by sample_time;

SESSION SAMPLE_TIME _STATE BLOCKING_SESSION CURRENT_OBJ# CURRENT_FILE# CURRENT_BLOCK# CURRENT_ROW# ————————————————————————————————————— ——————————— ——————————————————————— ————————————————— ——————————————————— ———————————————————— —————————————————— 29-SEP-12 04.55.02.379 PM WAITING 43 121419 7 4491 48 29-SEP-12 04.55.03.379 PM WAITING 43 121419 7 4491 48 29-SEP-12 04.55.04.379 PM WAITING 43 121419 7 4491 48 29-SEP-12 04.55.05.379 PM WAITING 43 121419 7 4491 48 29-SEP-12 04.55.06.379 PM WAITING 43 121419 7 4491 48 29-SEP-12 04.55.07.389 PM WAITING 43 121419 7 4491 48 … output truncated …

oracle magazine January/February 2013

JF13_Tuning.indd 53 11/29/12 3:49 PM 54 Tuning

the ROWID of the locked row by using the Resource Contention TIME_WAITED columns show “resmgr:cpu query shown in Listing 3. The row with After uncovering the root cause of the quantum” and “109984,” respectively. This ROWID AAAdvSAAHAAABGPAAw had been slowness in session 39, you now turn your means that the session had already waited locked by the session with SESSION_ID 43 attention to session 44. Revisiting the for 109,984 microseconds, or about 0.11 and was being requested to be updated by output in Listing 1, you can see that session seconds, at that time for the “resmgr:cpu the session with SESSION_ID 39. You now 44 switched between waiting (shown quantum” event. The next line in Listing 1, have the information on why the session under SESSION_STATE as WAITING) and sampled about a second later, shows the (with SESSION_ID 39) was slow—it was doing productive work (shown as ON SESSION_STATE column value as ON CPU, waiting for a lock for 22 minutes—what CPU). Note the very first line in the output which means that the session was doing SQL statement it was executing, and what for the session with SESSION_ID 44 and productive work at that time—not waiting. specific row it was looking to lock. You have SAMPLE_TIME 29-SEP-12 04.55.34.419 You need to know why the session was successfully uncovered the root cause of PM. The SESSION_STATE column shows intermittently waiting for this wait event the performance issue in the session with WAITING, which means that the session and therefore slowing down. SESSION_ID 39. was waiting at that time. The EVENT and The “resmgr:cpu quantum” event is due to Oracle Database’s Database Resource Management feature. Database Resource Code Listing 3: Getting specific row information Management acts as a resource governor: it limits CPU consumption of individual ses- select sions when the total CPU demand from all owner||'.'||object_name||':'||nvl(subobject_name,'-') obj_name, dbms_rowid.rowid_create ( sessions goes up to more than 100 percent, 1, and it enables more-important sessions to o.data_object_id, get the CPU they need. Because the output row_wait_file#, row_wait_block#, shows the session waiting, you can conclude row_wait_row# that the CPU consumption by the session ) row_id with SESSION_ID 44 was high enough at that from v$session s, dba_objects o where sid = &sid time for Database Resource Management and o.data_object_id = s.row_wait_obj# to limit its CPU usage. Well, the applica- tion owner counters, this application is very OBJ_NAME ROW_ID important and the resource usage should not —————————————————————————— —————————————————————————— ARUP.TEST1:- AAAdvSAAHAAABGPAAw have been constrained. In that case, you may suspect that the session was under a consumer group that Code Listing 4: Listing consumer groups has a more restrictive CPU allocation than expected. So your next stop is to find out what select sample_time, session_state, event, consumer_group_id consumer group was active for the session at from v$active_session_history where user_id = 92 that time—not now. Fortunately, the process and sample_time between for finding this information is straightforward. to_date('29-SEP-12 04.55.02 PM','dd-MON-yy hh:mi:ss PM') Active Session History records the consumer and to_date('29-SEP-12 05.05.02 PM','dd-MON-yy hh:mi:ss PM') group that was active for a session at the time and session_id = 44 of sampling and displays that information order by 1; in the CONSUMER_GROUP_ID column in SESSION the V$ACTIVE_SESSION_HISTORY view. You SAMPLE_TIME _STATE EVENT CONSUMER_GROUP_ID can see that information by using the query ————————————————————————————————————— —————————— —————————————————————————— ————————————————————————— 29-SEP-12 04.55.34.419 PM WAITING resmgr:cpu quantum 12166 shown in Listing 4. 29-SEP-12 04.55.35.419 PM ON CPU 12166 Because the session may have been under 29-SEP-12 04.55.36.419 PM WAITING resmgr:cpu quantum 12166 different consumer groups, it’s wise to select 29-SEP-12 04.55.37.419 PM ON CPU 12166 29-SEP-12 04.55.38.419 PM WAITING resmgr:cpu quantum 12166 the consumer groups for all of the sampled 29-SEP-12 04.55.39.419 PM WAITING resmgr:cpu quantum 12166 data in Active Session History for that session, 29-SEP-12 04.55.40.419 PM ON CPU 12166 rather than just one sample. In this case, the … output truncated … 29-SEP-12 04.55.37.419 PM ON CPU 12162 session was under consumer group 12166 29-SEP-12 04.55.38.419 PM ON CPU 12166 until it changed to 12162 on 29-SEP-12 at 29-SEP-12 04.55.39.419 PM ON CPU 12162 04.55.37.419 PM. To find out the names of the 29-SEP-12 04.55.40.419 PM ON CPU 12162 consumer groups, use the following query:

January/February 2013 Oracle.com/oraclemagazine

JF13_Tuning.indd 54 11/29/12 3:50 PM Tuning 55

select name against v$rsrc_consumer_group above). group in effect, the session was doing more- from v$rsrc_consumer_group The CONSUMER_GROUP_ID changed from productive work (as shown by the SESSION_ where id in (12166,12162); 12166 to 12162 at 04.55.37.419 PM. This STATE value ON CPU) than waiting with could have happened due to one of the the “resmgr:cpu quantum” event. This ID NAME three most likely reasons: a DBA manually observation may lead to many conclusions, —————— ———————————————— activated a different resource plan, a dif- but the most obvious is perhaps that the 12166 OTHER_GROUPS ferent plan was activated automatically by a APP_GROUP consumer group is less restric- 12162 APP_GROUP scheduling mechanism, or a DBA changed tive in terms of CPU allocation than OTHER_ the consumer group of the session from GROUPS. In that case, you should examine From the output of Listing 4, you can see OTHER_GROUPS to APP_GROUP (also why the OTHER_GROUPS consumer group that from 04.55.34.419 PM, the session was shown in the query against v$rsrc_ was activated earlier and, perhaps more under consumer_group_id 12166, which consumer_group above) online. Whatever importantly, whether this restriction was is OTHER_GROUPS (as shown in the query the reason, with the APP_GROUP consumer necessary or just a mistake. In any case, you have now found the root cause of the wait. The next obvious question is why Code Listing 5: Checking all events from a machine session 44 consumed so much CPU that it had to be constrained by Database Resource select event, count(1) Management. The answer lies in the SQL from v$active_session_history where machine = 'prolaps01' statement that session 44 was executing at and sample_time between that time (not now). The SQL_ID column in to_date('29-SEP-12 04.55.00 PM','dd-MON-yy hh:mi:ss PM') the output of Listing 1 was fngb4y81xr57x. and to_date('29-SEP-12 05.05.00 PM','dd-MON-yy hh:mi:ss PM') You can get the text of that SQL statement group by event with the following query: order by event;

EVENT COUNT(1) SQL> select SQL_TEXT from v$sql ———————————————————————————————————————————— —————————————— where sql_id = 'fngb4y81xr57x'; … output truncated … db file scattered read 93 db file parallel write 127 SQL_TEXT log file parallel write 134 ——————————————————————————————————————————————— db file sequential read 293 SELECT MAX(TEST1.OWNER) FROM TEST1, control file parallel write 612 control file sequential read 948 TEST2, TEST2, TEST2, TEST2, TEST2, enq: TX - row lock contention 1309 TEST2, TEST2, TEST2, TEST2, TEST2, resmgr:cpu quantum 1371 TEST2, TEST2, TEST2, TEST2, TEST2,

Code Listing 6: Selecting from the Active Session History archive

SQL> select session_id, sample_time, session_state, event,wait_time, time_waited, sql_id, sql_child_number CH# 2 from dba_hist_active_sess_history 3 where user_id = 92 4 and sample_time between 5 to_date('29-SEP-12 04.55.02 PM','dd-MON-yy hh:mi:ss PM') 6 and 7 to_date('29-SEP-12 05.05.02 PM','dd-MON-yy hh:mi:ss PM') 8 order by 1,2;

SESSION SESSION_ID SAMPLE_TIME _STATE EVENT WAIT_TIME TIME_WAITED SQL_ID CH# —————————————— ————————————————————————————————————— ————————— ——————————————————————————————————————————— —————————————— ———————————————— —————————————————— ———— 39 29-SEP-12 04.55.11.389 PM WAITING enq: TX - row lock contention 0 0 fx60htyzmz6wv 0 39 29-SEP-12 04.55.21.399 PM WAITING enq: TX - row lock contention 0 0 fx60htyzmz6wv 0 39 29-SEP-12 04.55.31.419 PM WAITING enq: TX - row lock contention 0 0 fx60htyzmz6wv 0 39 29-SEP-12 04.55.41.429 PM WAITING enq: TX - row lock contention 0 0 fx60htyzmz6wv 0 39 29-SEP-12 04.55.51.439 PM WAITING enq: TX - row lock contention 0 0 fx60htyzmz6wv 0 39 29-SEP-12 04.56.01.449 PM WAITING enq: TX - row lock contention 0 0 fx60htyzmz6wv 0 39 29-SEP-12 04.56.11.459 PM WAITING enq: TX - row lock contention 0 0 fx60htyzmz6wv 0 39 29-SEP-12 04.56.21.469 PM WAITING enq: TX - row lock contention 0 0 fx60htyzmz6wv 0 39 29-SEP-12 04.56.31.499 PM WAITING enq: TX - row lock contention 0 0 fx60htyzmz6wv 0 … output truncated …

oracle magazine January/February 2013

JF13_Tuning.indd 55 11/29/12 3:50 PM 56 Tuning

Code Listing 7: Getting row lock information from the Active Session History archive in a view called DBA_HIST_ACTIVE_SESS_ HISTORY. If you don’t find the data in the

select sample_time, session_state, blocking_session, V$ACTIVE_SESSION_HISTORY view, check owner||'.'||object_name||':'||nvl(subobject_name,'-') obj_name, for it in the DBA_HIST_ACTIVE_SESS_ dbms_ROWID.ROWID_create ( HISTORY view, as shown in Listing 6. The 1, o.data_object_id, output shows that the session was experi- current_file#, encing row lock waits—you can get the lock current_block#, current_row# and row information from the DBA_HIST_ ) row_id ACTIVE_SESS_HISTORY view by using the from dba_hist_active_sess_history s, dba_objects o query shown in Listing 7. where user_id = 92 and sample_time between to_date('29-SEP-12 04.55.02 PM','dd-MON-yy hh:mi:ss PM') Conclusion and Active Session History is a very powerful facility to_date('29-SEP-12 05.05.02 PM','dd-MON-yy hh:mi:ss PM') and event = 'enq: TX - row lock contention' inside Oracle Database that records the infor- and o.data_object_id = s.current_obj# mation on all active sessions in the database order by 1,2; instance in a buffer every second and exposes that data to you in a view called V$ACTIVE_ TEST2, TEST2, TEST2, TEST2, TEST2, sessions connected from the prolaps01 client SESSION_HISTORY and subsequently to a TEST2, TEST2, TEST2, TEST2 machine experienced locking and Resource persistent table visible in the DBA_HIST_ Manager–related waits many times. With ACTIVE_SESS_HISTORY view. Active Session You can immediately see from the output this information, you can dig further inside History offers a second-by-second record of that the query was performing a Cartesian the V$ACTIVE_SESSION_HISTORY view to the activities inside the session—even when join (joining all rows of a table with all rows of identify specific sessions and what they were that session has disconnected or ceased that another without a join condition) on a TEST2 doing earlier to have experienced these waits. activity—enabling you to go back in time and table several times. Even if the TEST2 table Although pulling specific data from Active identify what was ailing a specific session at a has a relatively small number of rows, the Session History is great for spot analysis, certain point in the past.  Cartesian join will produce a lot of logical I/Os. sometimes you may want to take a look at Because logical I/O requires CPU cycles to the entire collection of Active Session History Arup Nanda (arup@ execute, it’s hardly surprising that the session data within a time frame. Active Session proligence.com) has been consumed so much CPU that Database History reports for a specific time period are an Oracle DBA since 1993, Resource Management limited it. To resolve great for that. You can generate an Active handling all aspects of this issue, you will need to rewrite the query to Session History report from Oracle Enterprise database administration, eliminate or reduce Cartesian joins. Manager or from the command line. For from performance tuning the latter, connect to the database as a DBA to security and disaster recovery. He was Oracle More Uses user and execute the following script at the Magazine’s DBA of the Year in 2003 and received In the previous sections, you saw how SQL*Plus prompt: @$ORACLE_HOME/ an Oracle Excellence Award for Technologist of to find issues that occurred at a specific rdbms/admin/ashrpt.sql. the Year in 2012. point in the past in Active Session History. You can find more information on this Hopefully, the content gave you an idea of procedure in “NEXT STEPS.” Next Steps how powerful Active Session History is and how it can be used in many circumstances. Active Session History Archive READ Here is another example of the power and Active Session History collects information on online-only article content bit.ly/SuIzls usage of Active Session History: suppose a active sessions from the database instance “Beginning Performance Tuning” user complains that things seemed to have every second. Depending on the database bit.ly/SEzR6t been slow from a specific client machine— activity, that will lead to a lot of data collected “Performance Tuning: Diagnose the Past” prolaps01—between 4:55 p.m. and 5:05 p.m. inside the ASH buffer, but because the ASH bit.ly/U7U5IJ on September 29. Because Active Session buffer is a memory-resident structure, it has LEARN more about History also records the machine name, you only a finite amount of space. In addition, performance tuning Oracle Database 2 Day + Performance Tuning can use the query shown in Listing 5 to display when the instance goes down, the instance’s Guide 11g Release 2 (11.2) all the different events experienced by all ses- memory vanishes with it. Therefore, Oracle bit.ly/O0xhbH sions from the prolaps01 machine and how Database archives the information from the generating and using Active Session History often each event occurred. You can see from ASH buffer to a database table to make it reports bit.ly/SIsKea the Listing 5 output that during that time, the persistent. This archived table data is visible

January/February 2013 Oracle.com/oraclemagazine

JF13_Tuning.indd 56 11/29/12 3:50 PM Database Application Developer and DBA SQL 101 By Melanie Caffrey 57

Oracle Database Having Sums, Averages, and Other Grouped Data Part 9 in a series on the basics of the relational database and SQL

art 8 in this series, “Selecting a Type the SQL_101 schema that are required for this query in Listing 1 demonstrates use of the P That Is Right for You” (Oracle Magazine, article’s examples. (View the script in a text SUM aggregate function to answer this ques- November/December 2012), introduced editor for execution instructions.) tion. It adds together all the values in the common SQL date functions and showed EMPLOYEE table’s SALARY column, resulting how your queries can use them to modify The Sum of All Rows in the total value 970000. the appearance of date result set data. It All aggregate functions group data to ulti- also introduced the SYSDATE function and mately produce a single result value. Because When You Strive for Average date arithmetic and showed how they can be aggregate functions operate on multiple Another example of a business question you used to manipulate result set data to convey row values, you can use them to generate can answer by using an aggregate function is, more-meaningful results. So far, all of the summary data such as totals. For example, “What is currently the average annual salary functions discussed in this series operate you can answer budget planning questions for all employees?” Like the query in Listing 1, on single-row results. Aggregate functions such as “What is the total allotted amount the query in Listing 2 applies an aggregate (also called group functions) operate on of annual salary paid to all employees”? The function to the EMPLOYEE table’s SALARY multiple rows, enabling you to manipulate data so that it displays differently from how Code Listing 1: Display the sum of all salary values in the EMPLOYEE table it is stored in the database. This article intro- duces you to some of the more commonly SQL> set feedback on used SQL group functions, along with the SQL> select SUM(salary) from employee; GROUP BY and HAVING clauses. To try out the examples in this series, you SUM(SALARY) ————————————————— need access to an Oracle Database instance. 970000 If necessary, download and install an Oracle Database edition for your operating system 1 row selected. from bit.ly/fherki. I recommend installing Oracle Database, Express Edition 11g Release Code Listing 2: Compute the average salary value across all non-null salary values 2. If you install the Oracle Database software,

choose the installation option that enables SQL> select AVG(salary) from employee; you to create and configure a database. A new database, including sample user accounts and AVG(SALARY) ————————————————— their associated schemas, will be created for 97000 you. (Note that SQL_101 is the user account to use for the examples in this series; it’s also the 1 row selected. schema in which you’ll create database tables and other objects.) When the installation Code Listing 3: Substitute a non-null value for any null values process prompts you to specify schema pass-

words, enter and confirm passwords for SYS SQL> select AVG(NVL(salary, 0)) avg_salary and SYSTEM and make a note of them. 2 from employee; Finally—whether you installed the data- AVG_SALARY base software from scratch or have access to ——————————————— an existing Oracle Database instance—down- 88181.8182 load, unzip, and execute the SQL script avail- 1 row selected. able at bit.ly/VdVWqG to create the tables for

oracle magazine January/February 2013

JF13_SQL101.indd 57 11/29/12 4:01 PM 58 SQL 101

column. The AVG function in Listing 2 sums or COUNT(employee_id) with a call to so they are not included in the single count up the salary values and then divides the total COUNT(manager), demonstrated in Listing 6. value that is returned. by the number of employee records with non- In the EMPLOYEE table, 5 of the 11 records The query in Listing 7 demonstrates that null salary values. With the total of 970000 have no value for the MANAGER column, a call to COUNT(*) or COUNT(column_name) paid annually divided by 10 employees, the average annual salary value is 97000. Code Listing 4: Obtain a count of all employees by using COUNT(*) The EMPLOYEE table holds 11 records, but

the average-salary computation in Listing 2 SQL> select COUNT(*) considers only 10 records. This happens 2 from employee; because the AVG aggregate function ignores COUNT(*) null values. (In the EMPLOYEE table, the null ——————————————— salary value is for the employee Lori Dovichi.) 11

To substitute a non-null value for any null 1 row selected. values, you can nest a NVL function call (introduced in Part 7 of this series) inside the call to the AVG function, as demonstrated in Code Listing 5: Obtain a count of all employees by applying COUNT to the primary key column Listing 3. The average salary value returned in Listing 3 is lower than the value returned SQL> select COUNT(employee_id) 2 from employee; in Listing 2, because the null salary value for Lori Dovichi has been replaced with a 0 COUNT(EMPLOYEE_ID) and evaluated along with all other non-null ——————————————————————————— 11 salary values. Substitute non-null values for null values only when it makes sense to do so 1 row selected. from a business perspective. Code Listing 6: Apply COUNT to a column that contains null values Keeping Count As you know from previous articles in this SQL> select COUNT(manager) series, the SQL*Plus set feedback on 2 from employee; command displays a count of records that satisfy your query criteria. This method works COUNT(MANAGER) ————————————————————— well when the database quickly returns a 7 small number of records that can display 1 row selected. easily on your screen. But it’s unwieldy when you evaluate hundreds, thousands, or millions of records, because you must wait for all the Code Listing 7: COUNT(*) and COUNT(column_name) both return 0 when no rows match records in the result set to be fetched from the database and returned to your client. A SQL> select COUNT(*), COUNT(manager) more efficient alternative is to use the COUNT 2 from employee 3 where hire_date > TRUNC(SYSDATE); aggregate function, demonstrated in Listing 4. The COUNT aggregate function counts the COUNT(*) COUNT(MANAGER) number of records that satisfy the query con- —————————————— ———————————————————— 0 0 dition. The query in Listing 4 uses COUNT(*)— which returns the count of all rows that 1 row selected. satisfy the query condition—to obtain a count of all the records in the EMPLOYEE Code Listing 8: COUNT and DISTINCT obtain a count of distinct values table. COUNT(*) does not ignore null values, whereas COUNT with a column input does. SQL> select COUNT(DISTINCT manager) num_distinct_managers By comparing Listings 4 and 5, you can see 2 from employee; that the returned value is the same whether you count all columns in the EMPLOYEE table NUM_DISTINCT_MANAGERS ——————————————————————————————— with COUNT(*) or count just the primary key 3 column with COUNT(employee_id). 1 row selected. However, contrast a call to COUNT(*)

January/February 2013 Oracle.com/oraclemagazine

JF13_SQL101.indd 58 11/29/12 4:01 PM SQL 101 59

returns a result value of 0 if no rows match the not sort the results in any particular order. demonstrates the error that will occur if the query condition. The query requests a count of The query in Listing 11 shows the query from SELECT list column list and the ORDER BY all rows and a count of all manager values for Listing 10 without the ORDER BY clause. column list do not match. Similarly, an error all employee records with a hire date matching When a GROUP BY clause is followed by will occur if you do not use GROUP BY for the current day’s system date, SYSDATE. an ORDER BY clause, the columns listed in every column in the SELECT list that is not Because no one was hired on the date the the ORDER BY clause must also be included part of an aggregation operation, as shown query was run, a count value of 0 is returned. in the SELECT list. The query in Listing 12 by the query in Listing 13. This query is the If your goal is to determine a count of distinct values, you can combine the COUNT Code Listing 9: MAX and MIN obtain maximum and minimum column values aggregate function with the DISTINCT

keyword. Listing 8 shows a query that deter- SQL> select MAX(salary), MIN(salary) mines the count of DISTINCT or UNIQUE (a 2 from employee; keyword you can use instead of DISTINCT) MAX(SALARY) MIN(SALARY) MANAGER column values in the EMPLOYEE ———————————————— ————————————————— table. A count of 3 is returned. The null 300000 60000 value that exists in the MANAGER column 1 row selected. for several employees is not included in the count of distinct manager values by the call to the COUNT aggregate function. Code Listing 10: GROUP BY creates grouped categorizations

Maximizing and Minimizing SQL> select COUNT(employee_id), department_id You can certainly locate the maximum and 2 from employee 3 GROUP BY department_id minimum values within a set of row values 4 ORDER BY department_id; you’ve fetched with a well-ordered SQL statement. But if your result set is volumi- COUNT(EMPLOYEE_ID) DEPARTMENT_ID —————————————————————————— ———————————————————— nous and all you want is the maximum or the 6 10 minimum result, you don’t want to scroll to 2 20 the top or the bottom of the result set to see 2 30 1 it. You can use the MIN and MAX aggregate functions instead. The query in Listing 9 4 rows selected. uses them to display the EMPLOYEE table’s maximum and minimum salary values. Code Listing 11: No ORDER BY clause with GROUP BY clause

One by One and Group by Group SQL> select COUNT(employee_id), department_id So far the examples in this article have dis- 2 from employee cussed aggregate functions working on all 3 GROUP BY department_id; rows for a particular aggregation criterion. COUNT(EMPLOYEE_ID) DEPARTMENT_ID But you might want to do further categori- —————————————————————————— ———————————————————— zations and aggregations within your data. 2 30 The GROUP BY clause enables you to collect 1 2 20 data across multiple records and group the 6 10 results by one or more columns. Aggregate functions and GROUP BY clauses are used in 4 rows selected. tandem to determine and return an aggre- gate value for every group. For example, Code Listing 12: Error when ORDER BY clause column list doesn’t also appear in the SELECT list the query in Listing 10 obtains a count of

employees in each department. SQL> select COUNT(employee_id), department_id In Listing 10, note that one employee has 2 from employee not been assigned to a department in the 3 GROUP BY department_id 4 ORDER BY hire_date DESC; EMPLOYEE table and that person is included ORDER BY hire_date DESC as a group in the results. Note also that the * query uses an ORDER BY clause. Although ERROR at line 4: ORA-00979: not a GROUP BY expression the GROUP BY clause groups data, it does

oracle magazine January/February 2013

JF13_SQL101.indd 59 11/29/12 4:02 PM 60 SQL 101

same as the query in Listing 12, minus the Having the Last Word department is not returned in Listing 14’s GROUP BY clause. Just as a SELECT list can use a WHERE result set, because that group contains only The GROUP BY clause is necessary if your clause to filter the result set to include one employee. intent is to return multiple groups. And your only records that meet certain criteria, the The HAVING clause works primarily on intent to return multiple groups is deter- GROUP BY clause can use a similar clause to aggregate function columns, whereas the mined by the inclusion in the SELECT list of filter groups. The HAVING clause works with WHERE clause works on columns and other any column that is not part of an aggregation the GROUP BY clause to limit the results to expressions without an aggregation opera- operation. In the query in Listing 13, that groups that meet the criteria you specify. tion. I say primarily because the HAVING column is DEPARTMENT_ID in the EMPLOYEE Listing 14 expands on the query in Listing clause can use multiple operators in its table. A query that uses aggregate functions 10. Inclusion of the HAVING clause in this filtering operation. For example, the query and no GROUP BY clause always returns query eliminates any groups with fewer in Listing 15 displays a count of employees- exactly one row, even if the table you query than two employees from the result set. As per-department-and-salary groups that contains no rows at the time you query it. you can see, the group with no assigned satisfy one of two criteria, only the first of which uses an aggregate function: Code Listing 13: Error when GROUP BY does not list required column • The department has two or more employees. • The salaries of the employees in the

SQL> select COUNT(employee_id), department_id department are less than 100000. 2 from employee 3 ORDER BY department_id; Conclusion and anticipation select COUNT(employee_id), department_id * This article has shown you a few of the most ERROR at line 1: common aggregate functions and how you ORA-00937: not a single-group group function can use them to manipulate how your data is displayed. The next installment of SQL 101 Code Listing 14: HAVING clause filters groups will discuss analytic functions. 

SQL> select COUNT(employee_id), department_id 2 from employee Melanie Caffrey is 3 GROUP BY department_id a senior development 4 HAVING COUNT(employee_id) > 1 manager at Oracle. She is 5 ORDER BY department_id; a coauthor of Expert COUNT(EMPLOYEE_ID) DEPARTMENT_ID PL/SQL Practices —————————————————————————— ———————————————————— for Oracle Developers 6 10 2 20 and DBAs (Apress, 2011) and Expert Oracle 2 30 Practices: Oracle Database Administration from the Oak Table (Apress, 2010). 3 rows selected.

Next Steps Code Listing 15: HAVING clause can use multiple operators READ SQL> select COUNT(employee_id), department_id, salary SQL 101, Parts 1–8 2 from employee bit.ly/omagsql101 3 GROUP BY department_id, salary READ more about 4 HAVING (COUNT(employee_id) > 1 relational database design and concepts 5 OR salary < 100000) Oracle Database Concepts 11g Release 2 (11.2) 6 ORDER BY department_id, salary desc; bit.ly/aonqPP COUNT(EMPLOYEE_ID) DEPARTMENT_ID SALARY Oracle Database SQL Language Reference 11g —————————————————————————— ———————————————————— ——————————————— Release 2 (11.2) 1 10 80000 bit.ly/yWtbz1 1 10 70000 Oracle SQL Developer User’s Guide Release 3.1 2 10 60000 bit.ly/I9w52z 1 20 90000 aggregate functions 1 20 65000 bit.ly/WxKZFu 1 30 70000 1 75000 DOWNLOAD the sample script for this article 7 rows selected. bit.ly/VdVWqG

January/February 2013 Oracle.com/oraclemagazine

JF13_SQL101.indd 60 11/29/12 4:02 PM Database Application Developer and DBA ASK TOM BY TOM KYTE 61

ORACLE DATABASE On Promotion, Restriction, and Data Loading Our technologist provides missing links, custom sizes, and external table tips.

teven Feuerstein posted a URL that con- systems should be using Resource Manager lish an undo quota for undo space. The undo S tains all of his articles that have been already, so if your systems are not, you should quota limits the amount of undo a resource published in Oracle Magazine: oracle.com/ read up on it at bit.ly/Rbo77P. With Resource consumer group can utilize at any given technetwork/issue-archive/index-087690 Manager you can, among other things, estab- point in time. In this manner, you can limit .html (bit.ly/omagplsql). I was wondering if you had a similar link Code Listing 1: Creating the external table and could post it here.

Yes. Oracle Magazine maintains an SQL> create or replace directory my_dir as '/home/tkyte' archive of past issues and—for recurring 2 / Directory created. columns such as Ask Tom—pages that point to them all. My page of links is oracle.com/ SQL> CREATE TABLE et technetwork/issue-archive/index-093676 2 ( "EMPNO" VARCHAR2(10), 3 "ENAME" VARCHAR2(20), .html (bit.ly/omagasktomk). You can also go 4 "TELNOS" VARCHAR2(1000), to the Oracle Magazine home page at oracle 5 "SAL" VARCHAR2(10) ) 6 ORGANIZATION external .com/technetwork/oramag/magazine/home 7 ( (bit.ly/omaghome) for links to the complete 8 TYPE oracle_loader content of back issues as well as links to these 9 DEFAULT DIRECTORY MY_DIR 10 ACCESS PARAMETERS list pages—near the bottom of the home page 11 ( under FEATURED COLUMNS. 12 RECORDS DELIMITED BY NEWLINE CHARACTERSET US7ASCII 13 BADFILE 'MY_DIR':'t.bad' 14 LOGFILE 't.log_xt' UNDO SIZE RESTRICTIONS 15 READSIZE 1048576 I have some coworkers who believe that it 16 FIELDS TERMINATED BY "," OPTIONALLY ENCLOSED BY '"' LDRTRIM is a good idea to limit the size of the undo 17 MISSING FIELD VALUES ARE NULL 18 REJECT ROWS WITH ALL NULL FIELDS tablespace—in this case, to 1 GB per node 19 ( in two- to five-node Oracle Real Application 20 "EMPNO" CHAR(255) 21 TERMINATED BY "," OPTIONALLY ENCLOSED BY '"', Clusters systems. The reasoning is that it 22 "ENAME" CHAR(255) controls the size of undo and limits large 23 TERMINATED BY "," OPTIONALLY ENCLOSED BY '"', transactions. (They also do this with TEMP 24 "TELNOS" CHAR(1000) 25 TERMINATED BY "," OPTIONALLY ENCLOSED BY '"', tablespaces). I am not a fan of this practice. 26 "SAL" CHAR(255) What is your opinion? 27 TERMINATED BY "," OPTIONALLY ENCLOSED BY '"' It seems to be a strange way to limit a 28 ) 29 ) resource—and rather arbitrary. To meet the 30 location requirement “limit the size of a transaction,” 31 ( this approach would not even appear on my 32 't.dat' 33 ) list of solutions. It doesn’t limit the size of 34 ) individual transactions—it limits only the 35 / Table created. cumulative size of all concurrently executing transactions to 1 GB. You could still have a SQL> select * from et;

single transaction that is 1 GB in size. EMPNO ENAME TELNOS SAL To control the size of transactions, the ——————— ——————- ——————————————————————————————————————————————————————————————————- ————— correct method is to use Oracle Database’s 12 smith 1234556@@1234567@@876556612 1200 14 John 1234@@4567@@56789@@12345@@45778@@34566@@23456 1345

I-HUA CHEN I-HUA Resource Manager feature. Almost all

ORACLE MAGAZINE JANUARY/FEBRUARY 2013

JF13_asktom.indd 61 11/29/12 4:32 PM 62 Ask Tom

the amount of undo an application, group of porary space, depending on the needs of create table emp_contact ( empno references users, or individual users can generate. the queries and the number of concurrently emp, phone_no number(10) ) But back to this 1 GB arbitrary limit: Some executing queries. The one-size-fits-all systems will need 1 GB of undo, others will approach to undo doesn’t work in real life. I want to insert the data into the emp and need 500 MB, others will need 10 GB, and emp_contact tables. I don’t know how many others will need other sizes. The amount of Tricky Data Loading values for phone_no the file contains (the undo needed is based on I am using SQL Loader to load data into number of values for phone_no is not fixed). • The number of concurrent transactions tables from a flat file. Some sample data in How do I insert the data into the tables? • The relative size of these transactions the file might be: • The length of your longest-running queries This is tricky, because you have to turn (because you don’t want to experience 12,smith,1234556@@1234567 a single row of data into many rows in the ORA-1555, “Snapshot too old,” errors due @@876556612,1200 EMP_CONTACT table. to insufficient undo retention) With SQL Loader (the twentieth-century In the olden days—before automatic 14,John.1234@@4567@@56789 legacy data loading tool), this is not going undo management in Oracle9i Database—a @@12345@@45778@@34566@@23456,1345 to be directly possible. You could create a DBA had to size undo manually. Nowadays view on DUAL and place an INSTEAD OF this is how I would size my undo: The field values are empno, empname, INSERT trigger on that view to procedur- 1. Determine the undo retention I need to phone numbers, and salary. The table struc- ally process the data. The trigger would support. This is a function of my longest- tures are take each row inserted, parse it row by running query (undo retention must be row, and insert the row(s) into EMP and longer than that, or else I will be subject create table emp ( empno number(5) primary EMP_CONTACT. I’m not going to suggest to the dreaded ORA-1555 error) and my key, ename varchar2(10), Sal number(10,2) ) that approach, though, because it is very desire to be able to do flashback table or flashback query operations to recover from Code Listing 2: Querying the external table to output a row for each telephone number a “whoops”-type error without having to

go to backups. I’d like my undo retention SQL> select empno, ename, sal, i, to be at least three hours in most typical 2 substr( tnos, cases—for the “whoops” type of stuff— 3 instr( tnos, '@@', 1, i )+2, 4 instr( tnos, '@@', 1, i+1 ) and even longer if I can get it, because it is 5 -instr( tnos, '@@', 1, i) - 2 ) tno so much easier to do flashback operations 6 from ( than to go to backups. Flashback features 7 select to_number(et.empno) empno, 8 et.ename, have saved me more often than I can 9 to_number(et.sal) sal, count since Oracle9i Database. 10 column_value i, 2. Allow my undo segment to autoextend— 11 '@@'||et.telnos||'@@' tnos 12 from et, within reasonable limits—to satisfy the 13 table( cast( multiset( undo retention I need to support. You 14 select level don’t have to let it go to infinity, just to 15 from dual 16 connect by level <= some reasonable size. 17 (length(et.telnos) If you allow the undo tablespace to auto- 18 -length(replace(et.telnos,'@@','')))/2+1 ) extend, the database will retain undo for at 19 as sys.odciNumberList ) ) 20 ) least as long as you requested in the UNDO_ 21 / RETENTION setting, and it may retain undo even longer to permit long-running queries EMPNO ENAME SAL I TNO ——————— ——————— —————- —— ————————————— to complete. 12 smith 1200 1 1234556 Temporary tablespace space follows the 12 smith 1200 2 1234567 same sort of rules. For some systems, no 12 smith 1200 3 876556612 14 John 1345 1 1234 temporary space might be used. An online 14 John 1345 2 4567 transaction processing (OLTP) system, for 14 John 1345 3 56789 example, works with tens of rows at a time, 14 John 1345 4 12345 14 John 1345 5 45778 so there is virtually no need for temporary 14 John 1345 6 34566 space. Other systems, such as a reporting 14 John 1345 7 23456 system or a data warehouse, may need 10 rows selected. many gigabytes or even terabytes of tem-

January/february 2013 Oracle.com/oraclemagazine

JF13_asktom.indd 62 11/29/12 4:33 PM Ask Tom 63

code-intensive and does not scale very name it I. This represents the number of Last, on lines 1–5, I select the fields I need well. The trigger approach processes slow that row by each input record—as you can and parse the nth telephone number from by slow (row by row), so it doesn’t perform see, it runs from 1 to 3 for the first record the TNOS string. I use INSTR on line 3 to find well for data loading. and 1 to 7 for the second. the nth occurrence of ‘@@’ in the string and I am instead going to suggest using the data loading tool of the twenty-first century: Code Listing 3: Multitable INSERT to load rows into both the emp and emp_contact tables the external table. To test this, I start by cre-

ating the external table, as shown in Listing 1, SQL> create table emp so I can query the data as if it were in a 2 ( empno number primary key, regular database table. 3 ename varchar2(10), 4 sal number So now I can access the data to be loaded 5 ); with SQL, and once I have that ability, I can Table created.

do anything I want to it. What I need to do is SQL> create table emp_contact take each of the rows in Listing 1, parse the 2 ( empno number references emp, TELNOS string around the string ‘@@’, and 3 phone_no number 4 ); output a row for each telephone number. Table created. Using SQL, I can do that easily, as shown in \ Listing 2. SQL> insert all 2 when (i = 1) then into emp (empno,ename,sal) values (empno,ename,sal) I’ll explain the query in Listing 2 before 3 when (i > 0) then into emp_contact(empno,phone_no) values (empno,tno) I proceed to the data load. I know I need 4 select empno, ename, sal, i, to turn each row in the external table into 5 substr( tnos, 6 instr( tnos, '@@', 1, i )+2, multiple rows and that the number of rows 7 instr( tnos, '@@', 1, i+1 ) will be equal to the number of ‘@@’ strings 8 -instr( tnos, '@@', 1, i) - 2 ) tno plus one I find in the ET.TELNOS column—I 9 from ( 10 select to_number(et.empno) empno, compute that number on lines 17 and 18. 11 et.ename, Then I use a CONNECT BY to generate that 12 to_number(et.sal) sal, many rows. 13 column_value i, 14 '@@'||et.telnos||'@@' tnos On lines 13–19, I generate the set of rows I 15 from et, need for each input row: three rows for the first 16 table( cast( multiset( input record and seven rows for the second. 17 select level 18 from dual Then I join this set of data to the external table 19 connect by level <= itself—row by row. No join condition is neces- 20 (length(et.telnos) sary here when I use the construct 21 -length(replace(et.telnos,'@@','')))/2+1 ) 22 as sys.odciNumberList ) ) 23 ) SELECT * 24 / FROM some_table, TABLE( some_set ) 12 rows created. SQL> select * from emp;

The TABLE() clause executes for each EMPNO ENAME SAL row in SOME_TABLE, and those rows are ——————— ——————— ————— joined to the row that caused them to be 12 smith 1200 14 John 1345 generated. As a result, lines 12–20 have the effect of returning the first row from the ET SQL> select * from emp_contact; external table three times and the second EMPNO PHONE_NO row seven times—exactly what I need. On ——————— ————————————- 12 1234556 lines 7–11, I select and format the columns 12 1234567 I need from the output. I am converting the 12 876556612 EMPNO and SAL columns into their proper 14 1234 14 4567 datatypes, preserving the ENAME field as 14 56789 is, and adding ‘@@’ to the front and back 14 12345 of the TELNOS string, which will make it 14 45778 14 34566 easier to parse in a moment. Also, I take the 14 23456 output of my table function (the column 10 rows selected. is implicitly named COLUMN_VALUE) and

oracle magazine January/february 2013

JF13_asktom.indd 63 11/29/12 4:33 PM 64 Ask Tom

then use INSTR again to discover where the • The cardinality hint (undocumented) SQL> variable x varchar2(15) (n+1)th occurrence is on line 4. This enables • The OPT_ESTIMATE hint (undocumented) me to compute the starting character and • Dynamic sampling (Oracle Database 11g SQL> exec :x := '1,2,3,a,b,c' length of the nth telephone entry in the Release 1 and later) string, and I get the desired output. • Oracle Database’s Cardinality Feedback PL/SQL procedure successfully completed. Now in order to load the data, I need to feature (Oracle Database 11g Release 2 take the first row (where I = 1) for each group and later) SQL> select * from table(str2tbl(:x)); in Listing 2, insert it into the EMP table, and You can read about the fifth method in take all the rows in each group and insert an excellent write-up by Oracle ACE Adrian COLUMN_VALUE them into the EMP_CONTACT table. I could Billington at bit.ly/WRhizp. ———————————————————————————————————————————— do that in two passes through the data—that To demonstrate how to get and work with 1 is, just load the ET table into EMP and then the right estimated cardinality value, I’m 2 load the output of my Listing 2 query into going to use a little pipelined function I’ve 3 EMP_CONTACT. Rather than process the used many times over the years. This func- a data twice, however, I’ll use a multitable tion takes a delimited string and turns it into b insert to load both tables in one statement, a set, as shown in Listing 4. c as shown in Listing 3. Once I have that function installed, I can As you can see, I simultaneously loaded try it out by executing a query like this: 6 rows selected. the EMP and the EMP_CONTACT tables, using a single SQL statement against the Code Listing 4: Pipelined function turning delimited string into set ET external table. Using external tables as

your data loading tool offers up a world of SQL> create or replace type str2tblType as table of varchar2(30) possibilities that was just not possible with 2 / SQL Loader. Type created. SQL> create or replace Cardinalities 2 function str2tbl( p_str in varchar2, p_delim in varchar2 default ',' ) 3 return str2tblType I have a question about joining with collec- 4 PIPELINED tions and cardinality estimation. The opti- 5 as mizer is always estimating that 8,168 rows 6 l_str long default p_str || p_delim; 7 l_n number; are coming back from my collection, and 8 begin because of that, it is using inefficient plans. 9 loop The estimate of 8,168 is more than two orders 10 l_n := instr( l_str, p_delim ); 11 exit when (nvl(l_n,0) = 0); of magnitude more than the real cardinality. 12 pipe row( ltrim(rtrim(substr(l_str,1,l_n-1))) ); How can I solve this problem? 13 l_str := substr( l_str, l_n+1 ); This is a long-running issue with pipe- 14 end loop; 15 end; lined functions and collections during opti- 16 / mization. The optimizer in general doesn’t Function created. have any information about the cardinality (the number of rows) being returned by the Code Listing 5: Optimizer making 8 K cardinality estimate collection. It has to guess—and that guess is based on the block size (default statistics are SQL> select * from table(dbms_xplan.display_cursor); block-size-driven). So, for a database with an 8 K block size, the guess is about 8,000. And PLAN_TABLE_OUTPUT ————————————————————————————————————————————————————————————————————————————————————————————————————————————————— because it is unlikely that your collection has SQL_ID ddk1tv9s5pzq5, child number 0 about 8,000 elements (probably more like 8 ———————————————————————————————————————————————————————— or 80 in most cases), you can definitely arrive select * from table(str2tbl(:x)) at a suboptimal plan. Plan hash value: 2407808827 So the question is how do you get the right estimated cardinality value to the opti- ————————————————————————————————————————————————————————————————————————————————————————————————————————————————— |Id|Operation |Name |Rows|Bytes|Cost (%CPU)|Time | mizer? I’m going to demonstrate four ways ————————————————————————————————————————————————————————————————————————————————————————————————————————————————— here—and I’ll provide a pointer to a fifth way | 0|SELECT STATEMENT | | | | 29 (100)| | that uses the extensible optimizer. The four | 1| COLLECTION ITERATOR PICKLER...|STR2TBL|8168|16336| 29 (0)|00:00:01| ————————————————————————————————————————————————————————————————————————————————————————————————————————————————— methods I’ll demonstrate are

January/february 2013 Oracle.com/oraclemagazine

JF13_asktom.indd 64 11/29/12 4:34 PM Ask Tom 65

You can see the potential uses for a func- I achieve the desired result again: a cardi- As you can see, the estimated cardinality tion like this—to bind an IN list, for example nality estimate of 10. is 6 in this case, because when I executed (see bit.ly/S43Jqq for a demonstration). But The third approach I can use is dynamic the query and the sample was taken, there a problem with this function is the estimated sampling in Oracle Database 11g Release were six elements. The dynamic sampling cardinality the optimizer comes up with, as 1 and later. In order for a collection to be approach will use the cardinality it dis- shown in Listing 5. sampled, I must add a dynamic sampling covers on the hard parse of the SQL state- As you can see, there is that magic 8,168 hint to the query. Having the dynamic ment for all subsequent executions of that number in the ROWS column. The optimizer sampling level set in the session or at same cursor. assumes that the collection returned by this the system level is insufficient. Listing 8 Last, Oracle Database 11g Release 2 function is going to have more than 8,000 demonstrates the query with the dynamic and later include the Cardinality Feedback entries—you can imagine how that might sampling hint. feature. I quickly demonstrated this once affect the choices made by the optimizer regarding whether to use an index when Code Listing 6: Using the CARDINALITY hint processing a query. The first solution to this might be to use the cardinality hint, as SQL> select * from table(dbms_xplan.display_cursor); shown in Listing 6. PLAN_TABLE_OUTPUT As you can see, when I use ————————————————————————————————————————————————————————————————————————————————————————————————————————————————— CARDINALITY(SQ 10) as a hint in the query, SQL_ID bd2f8rh30z3ww, child number 0 the optimizer adjusts its estimated cardi- ———————————————————————————————————————————————————————— select /*+ cardinality(sq 10) */ * from table(str2tbl(:x)) sq nality to be the number I input—not 8,168. Note that I did not use the number 6, even Plan hash value: 2407808827 though the cardinality really was 6 in my ————————————————————————————————————————————————————————————————————————————————————————————————————————————————— example. You do not have to be exact with |Id|Operation |Name |Rows|Bytes|Cost (%CPU)|Time | the estimate; you want a number that is rep- ————————————————————————————————————————————————————————————————————————————————————————————————————————————————— resentative of the data, but it doesn’t have | 0|SELECT STATEMENT | | | | 29 (100)| | | 1| COLLECTION ITERATOR PICKLER...|STR2TBL| 10| 20| 29 (0)|00:00:01| to be perfect. Typically it should be within an ————————————————————————————————————————————————————————————————————————————————————————————————————————————————— order of magnitude of the actual value (8,168 is a full three orders of magnitude off!). This cardinality hint will work in Oracle9i Code Listing 7: Using the OPT_ESTIMATE hint Database and later. The next approach I can take in Oracle select /*+ opt_estimate(table, sq, scale_rows=0.00122429) */ * from table(str2tbl(:x)) sq Database 10g and later is the same approach a SQL profile would take: use the OPT_ Plan hash value: 2407808827 ESTIMATE hint. The OPT_ESTIMATE hint ————————————————————————————————————————————————————————————————————————————————————————————————————————————————— in this case will take three inputs: the type |Id|Operation |Name |Rows|Bytes|Cost (%CPU)|Time | of thing to apply the hint to (a table in this ————————————————————————————————————————————————————————————————————————————————————————————————————————————————— | 0|SELECT STATEMENT | | | | 29 (100)| | case), the correlation name of that table (SQ | 1| OLLECTION ITERATOR PICKLER...|STR2TBL| 10| 20| 29 (0)|00:00:01| in this case), and a scaling factor to apply to ————————————————————————————————————————————————————————————————————————————————————————————————————————————————— the optimizer’s estimate. This scaling factor is a number by which the optimizer will mul- Code Listing 8: Using the DYNAMIC SAMPLING hint tiply its estimated cardinality to arrive at the desired cardinality. In this case, the scaling factor will be select /*+ dynamic_sampling( sq, 2 ) */ * from table( str2tbl(:x,',') ) sq

Plan hash value: 2407808827 SQL> select 10/8168 from dual; ————————————————————————————————————————————————————————————————————————————————————————————————————————————————— |Id|Operation |Name |Rows|Bytes|Cost (%CPU)|Time | 10/8168 ————————————————————————————————————————————————————————————————————————————————————————————————————————————————— ———————————————— | 0|SELECT STATEMENT | | | | 11 (100)| | .00122429 | 1| COLLECTION ITERATOR PICKLER...|STR2TBL| 6| 12| 11 (0)|00:00:01| —————————————————————————————————————————————————————————————————————————————————————————————————————————————————

I want 10 instead of 8,168, so I need to use Note a scaling factor of 0.00122429. When I do ——————— - dynamic sampling used for this statement (level=2) that, I get the result in Listing 7.

oracle magazine January/february 2013

JF13_asktom.indd 65 11/29/12 4:35 PM 66 Ask Tom

before (bit.ly/Y7WSjM ). Since I wrote that query, using the newly discovered values. query. Note that the first time I execute this article, a new requirement for Cardinality For this to work with collections and bind query, the cardinality estimate is way off—it Feedback to work with collections and bind variables, you have to modify our query is that magic number 8,168 (again). However, variables has arisen, and I’ll address that here. slightly. I’ll be using a WITH factored sub- the optimizer learns from its mistake, and Cardinality Feedback works by having the query and the materialize hint to have the when I execute the query again, I get the optimizer change its cardinality estimates database physically materialize the collection result in Listing 10. after executing a query for the first time and data into a temporary table. (This is required With Cardinality Feedback, I get the observing that the actual cardinalities were for Cardinality Feedback to work with bind correct estimated cardinality. I have to make very far off from the estimated cardinalities. variables in this case.) Listing 9 demonstrates the mistake once, but the optimizer will self- That is, the optimizer starts to learn from its Cardinality Feedback using the WITH fac- correct the second time around. mistakes. If it executes a query and discovers tored subquery and the materialize hint. So, there are four of the methods for that the real row counts are far off from the With Cardinality Feedback, I would just getting the estimated cardinality for col- estimated counts, it will reoptimize the use SQ wherever I would have used the actual lections correct: the cardinality hint, the OPT_ESTIMATE hint, dynamic sampling, Code Listing 9: Using Cardinality Feedback (and the WITH factored subquery and materialize hint) and Cardinality Feedback. 

with sq as ( Tom Kyte is a database select /*+ materialize */ * evangelist in Oracle’s from table( str2tbl( :x ) ) Server Technologies ) select * division and has worked from sq for Oracle since 1993. He is the author of Expert Plan hash value: 630596523 Oracle Database Architecture (Apress, 2005, ———————————————————————————————————————————————————————————————————————————————————————————————————————————————————— 2010) and Effective Oracle by Design (Oracle |Id|Operation |Name |Rows|Bytes|Cost (%CPU)|Time | Press, 2003), among other books. ———————————————————————————————————————————————————————————————————————————————————————————————————————————————————— | 0|SELECT STATEMENT | | | | 32 (100)| | | 1| TEMP TABLE TRANSFORMATION | | | | | | Next Steps | 2| LOAD AS SELECT | | | | | | | 3| COLLECTION ITERATOR PICKLER...|STR2TBL|8168|16336| 29 (0)|00:00:01| | 4| VIEW | |8168| 135K| 3 (0)|00:00:01| ASK Tom | 5| TABLE ACCESS FULL |SYS_...|8168|16336| 3 (0)|00:00:01| Tom Kyte answers your most difficult technology ———————————————————————————————————————————————————————————————————————————————————————————————————————————————————— questions. Highlights from that forum appear in this column. 18 rows selected. asktom.oracle.com FOLLOW Tom on Twitter @OracleAskTom Code Listing 10: Getting the corrected cardinality with Cardinality Feedback READ more Tom bit.ly/omagasktomk

with sq as (select /*+ materialize */ * from table( str2tbl( :x ) ) Oracle Database Concepts 11g Release 2 (11.2) ) select * from sq bit.ly/aonqPP Expert Oracle Database Architecture: Oracle Plan hash value: 630596523 Database 9i, 10g, and 11g Programming Techniques and Solutions, Second Edition ———————————————————————————————————————————————————————————————————————————————————————————————————————————————————— amzn.to/ckGXaR |Id|Operation |Name |Rows|Bytes|Cost (%CPU)|Time | ———————————————————————————————————————————————————————————————————————————————————————————————————————————————————— DOWNLOAD Oracle Database 11g | 0|SELECT STATEMENT | | | 32 (100)| | Release 2 | 1| TEMP TABLE TRANSFORMATION | | | | | bit.ly/epBiUG | 2| LOAD AS SELECT | | | | | LEARN more about | 3| COLLECTION ITERATOR PICKLER...|STR2TBL|8168|16336| 29 (0)|00:00:01| Oracle Database’s Resource Manager feature | 4| VIEW | 6| 102 | 3 (0)|00:00:01| bit.ly/Rbo77P | 5| TABLE ACCESS FULL |SYS_...| 6| 12| 3 (0)|00:00:01| the extensible optimizer ———————————————————————————————————————————————————————————————————————————————————————————————————————————————————— bit.ly/WRhizp

Note pipelined functions ——————— bit.ly/S43Jqq - cardinality feedback used for this statement Oracle Database’s Cardinality Feedback feature 22 rows selected. bit.ly/Y7WSjM

January/february 2013 Oracle.com/oraclemagazine

JF13_asktom.indd 66 11/29/12 4:36 PM In the Field By John Matelski 67

Evolutionary Thinking Is the data scientist the next step on the information technology ladder?

eaders of public and private sector busi- Data-driven Engagement L nesses are tasked with constantly ana- Leveraging the knowledge of a broad-based lyzing the landscape of their organizations and decision-making has community is an optimal way to stay current evaluating the impact that changing business on trends, as well as to be an active partici- requirements and evolving technology capa- become pervasive in pant in relevant discussions. Independent bilities may have on them. The imperative is most organizations. Oracle Users Group (IOUG) is constantly to ensure that change is managed, and that updating, expanding, and fine-tuning its technology is leveraged in the most effective current business analytics and predictive core offerings to encompass and embrace and efficient manner possible. analytical models, and also for possible new evolving knowledge areas, and providing The role of the DBA has historically been business opportunities. You may be saying to them in preferred delivery channels to get based upon data systems engineering yourself, this sounds like the role of the busi- the information disseminated as soon as it requirements. The DBA typically designs and ness intelligence (BI) professional. I believe becomes available. recommends structural configurations to that it may be helpful to think of data sci- IOUG is now conducting industrywide maintain optimal database availability and entists and BI professionals as being on two research assessing changes in the Oracle data performance, and also designs and imple- ends of the same spectrum, with BI focused infrastructure landscape to obtain a more ments operational monitoring and adminis- on managing and reporting existing business comprehensive understanding of what role tration strategies to keep the data infrastruc- data in order to monitor or manage various the data scientist will play in organizations. ture secure and as defect-free as possible. concerns within the enterprise. In contrast, IOUG will be looking out two to three years data scientists use advanced analytical tools to determine what impact the data scientist Responsible Addition and algorithms to create predictive insights role will have in Oracle shops and how IOUG In addition to the need for DBAs and their and new-product innovations that are a can address these changes through education information design, configuration, opera- direct result of the data. Data scientists do and information sharing. IOUG welcomes tional, and administration responsibilities, not merely address business implications; your participation in this research, and as is there is also a growing need for individuals they focus on critical problems that have the the case with all of IOUG’s engagements, it who have the ability to create logic behind most value and impact to the organization. partners with recognized experts in the tech- the data, extract data, formulate models, Because the data scientist role is a new nology industry to ensure the accuracy and and apply quantitative business analytics function for most organizations, a gener- applicability of its findings. By employing the that facilitate making key proactive business ally accepted job description has not been combined power of a collective community decisions. Data-driven decision-making has defined yet. The lack of clarity poses a chal- and engaged experts, IOUG will continue to be become pervasive in most organizations. lenge to organizations that may be at the at the forefront of best practices and lessons Private sector companies make data-driven forefront of embracing this role. But it also learned in the technology community.  decisions to drive profit and gain a competi- may create exceptional opportunities for tive advantage, while public sector agencies individuals with the right skill set and who John Matelski is president of IOUG and has do so to ensure that they are making decisions have the desire to raise the profile of both been an active member in Oracle user groups that result in the most efficient and effective the function and the role. since 1997. He is currently the chief information use of taxpayer or constituent dollars. On paper, it would appear that many DBAs officer and director of IT services for DeKalb There has also been increasing interest have the prerequisite skills to be data sci- County, Georgia. in a new class of data professional that is a entists. It will be interesting to monitor how blend of both the aforementioned skill sets. the DBA and data scientist roles will evolve Next Steps Individuals who can model and mine in data organizationally, and how the positions will environments of all sizes are referred to as complement or supplement each other. As JOIN IOUG data scientists. Data scientists use a combi- the role of the data scientist becomes more ioug.org nation of their business and technical skills to prevalent, individuals and organizations will LEARN more about IOUG research activities ioug.org/researchwire investigate data, looking for ways to improve want to stay engaged in the evolution.

oracle magazine January/February 2013

JF13_InTheField.indd 67 11/29/12 4:41 PM 68 Time Capsule Flashbacks: Culture. Industry. Oracle. Oracle Magazine. BY RICH SCHWERIN

1968 HAL 9000 Dave: “Open the pod bay doors, HAL.” HAL: “I’m sorry, Dave. I’m afraid I can’t do that.” Quotes from 2001: A Space Odyssey (Metro-Goldwyn-Mayer, 1968) Keeping our eye on the inevitable.

1987 1946 SPARC Electronic Numerical Integrator and Computer (ENIAC) Microprocessor With more than 17,000 vacuum tubes and 5 million hand-soldered joints, the From the “Sunrise” 10MIPS pro- 1,800-square-foot, 25-ton ENIAC was the first general-purpose digital computer cessor to today’s state-of-the-art capable of being reprogrammed. The original programmers? All women, six of whom SPARC T4, the 25-year history of are in the Women in Technology International Hall of Fame. innovation with Oracle’s SPARC microprocessor began when developed its own RISC chip. 2011 SPARC SuperCluster T4-4 Oracle’s SPARC SuperCluster T4-4 com- bines the computing power of the SPARC T4-4 server, the scalability of Oracle Solaris 11, the database optimization of Oracle Exadata, the accelerated process-

1999 ing of Oracle’s Exalogic Elastic Cloud Software, and the unified systems man- Sun Ray 1 agement of Oracle Enterprise Manager Sun Ray clients have no moving Ops Center 12c into the world’s most effi- parts, no local operating system cient multipurpose engineered system. 2012 to manage, and no local storage. Destination: SPARC The original client, the Sun Ray 1, With the release of the SPARC T4 chip and the Oracle supported displays up to 1,280 × Solaris 11 operating system, which has been optimized 1,024 pixels. Now available, Oracle’s for SPARC, Oracle has arrived at better-than-promised Sun Ray 3 Plus Client, supports up application performance and availability. to 2,560 x 1,600 resolution for a single display or 5,120 x 1,600 total resolution across two displays, plus high-performance video, audio, and YOUR FIRST PC security, while delivering extremely What was your first personal computer? We asked our low power consumption. Facebook fans, and here’s what they said: Commodore 64 24% Intel 286 19% Commodore VIC-20 11% Sinclair ZX Spectrum 48K 8% 2008 Other 38% Oracle Exadata Database Machine YOUR TURN The original Oracle engineered system, From the abacus and punch cards to the latest smart Oracle Exadata is now in its fourth phones, the history of computational hardware is rich generation. The Exadata Database and varied. Which hardware do you use to run Oracle Machine X3-8 includes 160 CPU cores technology? What’s the one hardware device you can’t live for database server processing and 168 without? Visit Facebook/OracleMagazine and let us know.

CPU cores for storage processing. bit.ly/orclmagfb ELIZABETH SNYDER HOLBERTON FRANCES RIGHT: GLEN BECK LEFT: IN BRL BUILDING 328. THE ENIAC, WITHIN THE ORDNANCE CORPS” COMPUTERS ELECTRONIC MONOGRAPH: “HISTORICAL KEMPF, K. FROM ARMY PHOTO”, “U.S.

JANUARY/FEBRUARY 2013 ORACLE.COM/ORACLEMAGAZINE

JF13_TimeCapsule.indd 68 11/29/12 4:48 PM Photography: Guilain Grenier / ORACLE

TEAM USA

EXTREME PERFORMANCE oracleteamusa.com

© 2013 ORACLE TEAM USA. All rights reserved.

omag0113pCov3.indd 1 12/3/12 11:50 AM

ORACLE CREATIVE PERSONNEL PRODUCTION NOTES APPROVALS DATE INTERNAL RD

File Name: 112348 OTUSA_Compass_AD.ai Designer: I-Hua Chen/415.203.9048 Color: 4-color, 1-sided Designer: Job No: 112348 Art Director: Francisco Delgadillo Printed at: 100% Art Director: Description: AD Copywriter: Name/650.506.xxxx Fonts: Univers, Garamond Copywriter: Trim: 8 in (W) x 10.875 in (H) Proofer: Name/650.506.xxxx Paper: TBD Proofer Live: n/a Traffic: Samantha Pinney Other Special Instructions: Traffic: Bleed: 8.25 in (W) x 11.125 in (H) Production: Name/650.506.xxxx Production: 5 Finished: 8 in (W) x 10.875 in (H) Client: Laurent du Roure Client: 11-19-2012 Released by: I-Hua Chen Released by: