Database Compatibility for Oracle Developer's Guide Provides Detailed Information About

Database Compatibility for Oracle Developer's Guide Provides Detailed Information About

Database Compatibility for Oracle® Developer’s Guide EDB Postgres™ Advanced Server 12 March 31, 2021 Database Compatibility for Oracle® Developer’s Guide by EnterpriseDB® Corporation Copyright © 2007 - 2021 EnterpriseDB Corporation. All rights reserved. EnterpriseDB Corporation, 34 Crosby Drive, Suite 201, Bedford, MA 01730, USA T +1 781 357 3390 F +1 978 467 1307 E [email protected] www.enterprisedb.com Database Compatibility for Oracle® Developers Guide Table of Contents 1 Introduction ............................................................................................................................................ 9 1.1 What’s New ...................................................................................................................................10 1.2 Typographical Conventions Used in this Guide ............................................................................11 1.3 Configuration Parameters Compatible with Oracle Databases ......................................................11 1.3.1 edb_redwood_date .................................................................................................................13 1.3.2 edb_redwood_raw_names .....................................................................................................13 1.3.3 edb_redwood_strings .............................................................................................................14 1.3.4 edb_stmt_level_tx ..................................................................................................................16 1.3.5 oracle_home...........................................................................................................................17 1.4 About the Examples Used in this Guide ........................................................................................18 2 SQL Tutorial ..........................................................................................................................................19 2.1 Getting Started ...............................................................................................................................19 2.1.1 Sample Database ....................................................................................................................20 2.1.1.1 Sample Database Installation ............................................................................................20 2.1.1.2 Sample Database Description ...........................................................................................20 2.1.2 Creating a New Table ............................................................................................................31 2.1.3 Populating a Table With Rows ..............................................................................................32 2.1.4 Querying a Table ...................................................................................................................33 2.1.5 Joins Between Tables ............................................................................................................35 2.1.6 Aggregate Functions ..............................................................................................................39 2.1.7 Updates ..................................................................................................................................41 2.1.8 Deletions ................................................................................................................................42 2.1.9 The SQL Language ................................................................................................................43 2.2 Advanced Concepts .......................................................................................................................44 2.2.1 Views .....................................................................................................................................44 2.2.2 Foreign Keys..........................................................................................................................46 2.2.3 The ROWNUM Pseudo-Column ...........................................................................................47 2.2.4 Synonyms ..............................................................................................................................49 2.2.5 Hierarchical Queries ..............................................................................................................53 2.2.5.1 Defining the Parent/Child Relationship ............................................................................54 2.2.5.2 Selecting the Root Nodes ..................................................................................................54 2.2.5.3 Organization Tree in the Sample Application ...................................................................54 2.2.5.4 Node Level ........................................................................................................................56 2.2.5.5 Ordering the Siblings ........................................................................................................57 2.2.5.6 Retrieving the Root Node with CONNECT_BY_ROOT .................................................58 2.2.5.7 Retrieving a Path with SYS_CONNECT_BY_PATH ......................................................62 2.2.6 Multidimensional Analysis ....................................................................................................64 2.2.6.1 ROLLUP Extension ..........................................................................................................66 2.2.6.2 CUBE Extension ...............................................................................................................69 2.2.6.3 GROUPING SETS Extension ...........................................................................................73 2.2.6.4 GROUPING Function .......................................................................................................79 2.2.6.5 GROUPING_ID Function ................................................................................................82 2.3 Profile Management ......................................................................................................................85 2.3.1 Creating a New Profile ..........................................................................................................86 2.3.1.1 Creating a Password Function...........................................................................................89 2.3.2 Altering a Profile ...................................................................................................................93 2.3.3 Dropping a Profile .................................................................................................................94 2.3.4 Associating a Profile with an Existing Role ..........................................................................95 2.3.5 Unlocking a Locked Account ................................................................................................97 2.3.6 Creating a New Role Associated with a Profile .....................................................................99 2.3.7 Backing up Profile Management Functions .........................................................................101 2.4 Optimizer Hints ...........................................................................................................................102 Copyright © 2007 - 2021 EnterpriseDB Corporation. All rights reserved. 3 Database Compatibility for Oracle® Developers Guide 2.4.1 Default Optimization Modes ...............................................................................................104 2.4.2 Access Method Hints ...........................................................................................................106 2.4.3 Specifying a Join Order .......................................................................................................110 2.4.4 Joining Relations Hints ........................................................................................................111 2.4.5 Global Hints .........................................................................................................................114 2.4.6 Using the APPEND Optimizer Hint ....................................................................................117 2.4.7 Parallelism Hints ..................................................................................................................118 2.4.8 Conflicting Hints .................................................................................................................123 3 Stored Procedure Language .................................................................................................................124 3.1 Basic SPL Elements.....................................................................................................................124 3.1.1 Character Set........................................................................................................................124 3.1.2 Case Sensitivity ...................................................................................................................125 3.1.3 Identifiers .............................................................................................................................125 3.1.4 Qualifiers .............................................................................................................................125

View Full Text

Details

  • File Type
    pdf
  • Upload Time
    -
  • Content Languages
    English
  • Upload User
    Anonymous/Not logged-in
  • File Pages
    443 Page
  • File Size
    -

Download

Channel Download Status
Express Download Enable

Copyright

We respect the copyrights and intellectual property rights of all users. All uploaded documents are either original works of the uploader or authorized works of the rightful owners.

  • Not to be reproduced or distributed without explicit permission.
  • Not used for commercial purposes outside of approved use cases.
  • Not used to infringe on the rights of the original creators.
  • If you believe any content infringes your copyright, please contact us immediately.

Support

For help with questions, suggestions, or problems, please contact us