Hello,
I'm in a process of expanding my app to work with other databases and for that I need to convert the MySQL statements to
DB2, InterBase, Oracle, ODBC, PostgreSQL, SQLite2 and SQLite3.
It should be an easy task because there are only four statements I have to convert:
Code:
SELECT COLUMN_NAME, COLUMN_TYPE, IS_NULLABLE, COLUMN_KEY, COLUMN_DEFAULT, EXTRA FROM INFORMATION_SCHEMA.COLUMNS WHERE TABLE_SCHEMA='<schema_name>' AND TABLE_NAME='<table_name>'
Code:
SELECT REFERENCED_TABLE_NAME, REFERENCED_COLUMN_NAME, TABLE_NAME, COLUMN_NAME FROM INFORMATION_SCHEMA.KEY_COLUMN_USAGE WHERE REFERENCED_TABLE_SCHEMA='<schema_name>' ORDER BY REFERENCED_TABLE_NAME, TABLE_NAME, REFERENCED_COLUMN_NAME, COLUMN_NAME
Code:
SELECT name, param_list FROM mysql.proc WHERE db='<schema_name>' AND type='PROCEDURE'
Would you be so kind to tell me I it is possible to convert those statements to PostgreSQL compatible ones, and if so what is their PostgreSQL equivalent.