This guide details the manual migration of Oracle stored procedures, functions, and triggers to GBase 8s, covering syntax differences and specific…
This document serves as a technical guide for migrating database objects from Oracle to GBase 8s. It focuses specifically on the manual translation of stored procedures, functions, and triggers, which are often difficult to migrate automatically using standard tools. The guide aims to minimize changes to application source code while adapting the business logic to GBase 8s syntax.
The text provides detailed comparisons between Oracle and GBase 8s syntax for various database objects. It covers the migration of stored procedure definitions, input/output parameters, variable assignments, control structures (IF, WHILE, FOR loops), exception handling, dynamic SQL, and cursors. Additionally, it explains how to migrate functions and triggers, including specific strategies for handling auto-increment fields and INSERT/UPDATE/DELETE events. This manual is written in Chinese.
The only syntax difference is that GBase 8s uses 'ELIF' instead of 'ELSIF' for the else-if condition.
No, GBase 8s does not support bind variables in dynamic SQL. The conversion principle is to substitute variables directly into the SQL string before execution.
GBase 8s does not support multiple events in a single trigger. You must migrate an Oracle trigger handling all three events into three separate triggers.