Difference between revisions of "PostgreSQL Adapter Project - Extending SQLSchemaManager"
(→Task Summary) |
(→Task Summary) |
||
Line 88: | Line 88: | ||
|- | |- | ||
| Implement <code>getSetupEtcScriptName()</code> method | | Implement <code>getSetupEtcScriptName()</code> method | ||
+ | | | ||
+ | | | ||
+ | |- | ||
+ | | Override <code>renameTable</code>[http://www.postgresql.org/docs/8.0/static/sql-altertable.html] | ||
+ | | | ||
+ | | | ||
+ | |- | ||
+ | | Override <code>renameColumn</code>[http://www.postgresql.org/docs/8.0/static/sql-altertable.html] | ||
+ | | | ||
+ | | | ||
+ | |- | ||
+ | | Override <code>renameIndex</code>[http://www.postgresql.org/docs/8.0/static/sql-alterindex.html] | ||
| | | | ||
| | | |
Revision as of 13:20, 19 January 2011
PostgreSQL Adapter for NexJ - Extending SQL Schema Manager
- SQLSchemaManager is used in maintaining database schemas (DDL)
Contents
Task Summary
Task | Status | Test Status |
---|---|---|
Extend SQLSchemaManager to support PostgreSQL | DONE | DONE |
Research and add Maximum column Precision | ||
Figure out Data Type Mapping | ||
Implement appendColumnType() method
|
||
Implement appendConcatenate() method
|
DONE | |
Implement appendPrint() method
|
||
Implement appendUpgradeStepEnd() method
|
||
Implement appendUpgradeStepStart() method
|
||
Implement appendTSExtract() method
|
||
Implement appendTSIncrement() method
|
||
Implement getCreateEtcScriptName() method
|
||
Implement getDefaultIndexspace() method
|
||
Implement getDefaultLongspace() method
|
||
Implement getDefaultTablespace() method
|
||
Implement getDropEtcScriptName() method
|
||
Implement getDynamicSQLAppender() method
|
||
Implement getGUIDExpr() method
|
||
Implement getNowExpr() method
|
||
Implement getSeparator() method
|
DONE | |
Implement getSetupEtcScriptName() method
|
||
Override renameTable [1]
|
||
Override renameColumn [2]
|
||
Override renameIndex [3]
|
Task Details
Extend SQLSchemaManager to support PostgreSQL
Create a new class PostgreSQLSchemaManager by extending SQLSchemaManager and implementing all necessary abstract classes
Research and add Maximum column Precision
Following are the Maximum column precisions we might need to establish:
(All constants are defined in PostgreSQLAdapter class)
- DEFAULT_FETCH_SIZE
- MAX_CHAR_PRECISION
- MAX_VARCHAR_PRECISION
- MAX_BINARY_PRECISION
- MAX_VARBINARY_PRECISION
- MAX_REAL_PRECISION
- TIMESTAMP_FORMAT_SQL
- TIMESTAMP_FORMAT
Figure out Data Type Mapping
http://www.postgresql.org/docs/current/static/datatype.html
- Go over all data types offered in PostgreSQL
- Map types defined in
Primitive
class
Implement appendColumnType()
method
This method appends a table column type declaration to a string buffer.
- use logic and mapping to append required column data types to incoming string.
- Test it