Random Titbits for Migrating from MySQL to Oracle

Showing All Tables in a Database

In MySQL the recommended way of showing all tables in a database is to use:

SHOW TABLES;

, but in Oracle you should use:

SELECT TABLE_NAME FROM TABS;

Comment Style in Oracle SQL Files

In MySQL SQL the comment style is to use the hash (#) character at the start of each line to be commented, or a line starting with ”– ” or '/*' followed by '*/' for multi-line comments, e.g.,

# This IS a single line comment
-- This is also a single line comment
/* This
   is
   a 
   multi-line
   comment */

In Oracle the recommended method for creating comments should be that the line of comment starts with '–' for single line comment or '/*' followed by '*/' for multi-line comments, e.g.,

-- This is a single line comment
/* This
   is
   a 
   multi-line
   comment */
public/mysqltooracle.txt · Last modified: 2008/08/09 09:59 (external edit)
 
Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Noncommercial-Share Alike 3.0 Unported
Recent changes RSS feed Donate Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki