Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

Oracle PL/SQL Best Practices

1,109 views

Published on

Oracle PL/SQL Best Practices
TROUG Day 2016
https://emrahmete.wordpress.com/

Published in: Data & Analytics
  • DOWNLOAD FULL eBOOK INTO AVAILABLE FORMAT ......................................................................................................................... ......................................................................................................................... 1.DOWNLOAD FULL. PDF eBook here { https://tinyurl.com/y3nhqquc } ......................................................................................................................... 1.DOWNLOAD FULL. EPUB eBook here { https://tinyurl.com/y3nhqquc } ......................................................................................................................... 1.DOWNLOAD FULL. doc eBook here { https://tinyurl.com/y3nhqquc } ......................................................................................................................... 1.DOWNLOAD FULL. PDF eBook here { https://tinyurl.com/y3nhqquc } ......................................................................................................................... 1.DOWNLOAD FULL. EPUB eBook here { https://tinyurl.com/y3nhqquc } ......................................................................................................................... 1.DOWNLOAD FULL. doc eBook here { https://tinyurl.com/y3nhqquc } ......................................................................................................................... ......................................................................................................................... ......................................................................................................................... .............. Browse by Genre Available eBooks ......................................................................................................................... Art, Biography, Business, Chick Lit, Children's, Christian, Classics, Comics, Contemporary, CookeBOOK Crime, eeBOOK Fantasy, Fiction, Graphic Novels, Historical Fiction, History, Horror, Humor And Comedy, Manga, Memoir, Music, Mystery, Non Fiction, Paranormal, Philosophy, Poetry, Psychology, Religion, Romance, Science, Science Fiction, Self Help, Suspense, Spirituality, Sports, Thriller, Travel, Young Adult,
       Reply 
    Are you sure you want to  Yes  No
    Your message goes here
  • Çok yararlı oldu.Teşekkürler.
       Reply 
    Are you sure you want to  Yes  No
    Your message goes here

Oracle PL/SQL Best Practices

  1. 1. PL/SQL Best Practıces Emrah METE Senior ETL Developer Board Member of TROUG
  2. 2. Emrah METE - Yıldız Teknik Üniversitesi – Bilgisayar Mühendisliği - İş Deneyimi - Software Developement Specialist @Turkcell Teknoloji - Senior BI Consultant @i2i-Systems - Senior BI Specialist @HititCs - Senior ETL Developer @Turkcell Teknoloji - Teknik Uzmanlık - 5+ Oracle SQL, Oracle PL/SQL, ETL, DWH, BI - Kurucu Üye ve Yönetim Kurulu Üyesi @TROUG - Moderatör @OracleTurk - Blogger - https://emrahmete.wordpress.com/ (Türkçe) - https://emrahmeteen.wordpress.com/ (İngilizce) - Oracle Certified SQL Expert - Oracle Database Developer Choice Awards 2015, SQL Category Winner!!! - Oracle ACE https://emrahmete.wordpress.com/about/
  3. 3. 1 Don't Hard Codıng
  4. 4. VARCHAR2(N) Declaration
  5. 5. Business Rules and Formulas
  6. 6. SQL STATEMENTS APPLICATION T1 T2 T3 T4 DML DML OPTIMIZE MAINTAIN DEBUG
  7. 7. SOLUTION: SQL AS A SERVICE APPLICATION DATA LAYER T3 T3 T3 T3 T3 APPLICATION DATA LAYER T3 OPTIMIZE MAINTAIN DEBUG WRITE CODE FASTER Fix Bugs Faster REUSED CODE
  8. 8. SOLUTION: SQL AS A SERVICE
  9. 9. 2 Don’t row by row processıng
  10. 10. ROW BY ROW PROCESSING
  11. 11. HOW IT WORKS
  12. 12. SOLUTION: BULK PROCESSING
  13. 13. SOLUTION: BULK PROCESSING
  14. 14. SOLUTION: BULK PROCESSING : HOW IT WORKS
  15. 15. BULK COLLECT LIMITATIONS
  16. 16. BULK PROCESSING DATASET 1 ARRAY TRANSFORMATION TABLE BULK COLLECT FORALL
  17. 17. 3 memory management
  18. 18. - PACKAGE LEVEL PARAMETERS - BULK COLLECT WITH LIMIT CLAUSE - BULK COLLECT WITH VARRAYS - USING PARALLEL PIPELINED FUNCTIONS - USING NOCOPY HINT MEMORY MANAGEMENT
  19. 19. USING NOCOPY - IN => pass by reference - OUT, IN OUT => default pass by value - NOCOPY => pass by reference + Memory Consumption + Improve Performance - Do not trust (in Exception State)
  20. 20. 4 Data cachıng
  21. 21. - Great technique for improving application performance - SGA is an huge and sophisticted for the database instance. - Also We have three other caches that we can use in PL/SQL code - Deterministic Functions - PGA Caching - Function Result Cache DATA CACHING
  22. 22. - PL/SQL Functions declared as Deterministic - Caching using PGA - Used most effectively with collections - Accessing PGA more efficient than SGA - Function Result Cache (Oracle DB 11g) DATA CACHING
  23. 23. FUNCTION RESULT CACHE
  24. 24. DETERMINISTIC
  25. 25. LiveSQL!!! https://livesql.oracle.com
  26. 26. REFERENCES - Oracle PL/SQL Best Practices - Oracle PL/SQL Programming - http://www.oracle.com/technetwork/issue-archive/2010/10-sep/o57plsql-088600.html - http://orasql.org/category/oracle/deterministic-functions/ - Practically Perfect PL/SQL with Steven Feuerstein - https://www.youtube.com/watch?v=0PSrI7iT1AQ - https://www.youtube.com/watch?v=8NoOATGP9v8 - https://www.youtube.com/watch?v=VBkRTXz5pug - https://www.youtube.com/watch?v=D7H1VKMiqj8 - https://www.youtube.com/watch?v=lxLTXcY3e80 - https://www.youtube.com/watch?v=EoyRxPxU26U
  27. 27. thanks! Any questions? @emrahmete (twitter) emrahmete@gmail.com https://emrahmete.wordpress.com

×