Difference between revisions of "PostgreSQL Adapter Project - Code Review 1 Changes"
(→General Research) |
(→PostgreSQLAdapter) |
||
Line 63: | Line 63: | ||
| Refactor escaping literals | | Refactor escaping literals | ||
* May be make use isLiteral | * May be make use isLiteral | ||
− | | | + | |'''DONE''' |
| | | | ||
|- | |- | ||
Line 69: | Line 69: | ||
* Add parentheses to enforce operation order | * Add parentheses to enforce operation order | ||
* Remove implementation of MatchNode.WEIGHT.SYMBOL | * Remove implementation of MatchNode.WEIGHT.SYMBOL | ||
− | | | + | |'''DONE''' |
| | | | ||
|- | |- | ||
Line 83: | Line 83: | ||
|- | |- | ||
| appendLiteral | | appendLiteral | ||
− | * Check if timestamp | + | * Check if timestamp accepts java.sql.timestamp.toString() format |
* If boolean constants are supported, use those instead of string 't'/'f' | * If boolean constants are supported, use those instead of string 't'/'f' | ||
− | | | + | |'''DONE''' |
| | | | ||
|- | |- | ||
Line 95: | Line 95: | ||
| isLiteral | | isLiteral | ||
* Use string.length and binary.getSize to ensure less than 1GB | * Use string.length and binary.getSize to ensure less than 1GB | ||
− | | | + | |'''DONE''' |
| | | | ||
|- | |- | ||
Line 101: | Line 101: | ||
* Ensure to_timestamp accepts milliseconds | * Ensure to_timestamp accepts milliseconds | ||
* Ensure case Primitive.TIMESTAMP_ORDINAL: returns milliseconds (extract(epoch from | * Ensure case Primitive.TIMESTAMP_ORDINAL: returns milliseconds (extract(epoch from | ||
− | | | + | |'''DONE''' |
| | | | ||
|- | |- |
Revision as of 11:31, 3 June 2011
Contents
General Research
Task | Status |
---|---|
Can postgreSQL be configured to have the where clause use case insensitive compare for string values? i.e. (select 'Q' = 'q' => should return true)
|
(DONE) |
Add UUID generation to x64 versions | |
Does extract(epoch from value) return milliseconds?
|
YES |
What encoding (UTF-8 and/or UTF-16) does PostgreSQL use for unicode? Can this be configured per column? | UTF-8 |
How is a repeatable read with exclusive lock implemented? | |
Does timestamp'value', handle java.sql.timestamp.toString()? | YES |
Does to_timestamp support milliseconds? | YES
Precision is up to microseconds(10^-6) http://www.postgresql.org/docs/7.4/static/functions-datetime.html |
Does postgreSQL have constants for boolean values? | YES
TRUE and FALSE (they are case insensitive) |
Does posrgreSQL jdbc driver support returning metadata in UpperCase | NO
Since database objects are case sensitive, returning UpperCase would make for corrupt data May be consider changing SQLManager to enforce all database object names to be lowercase |
Does renaming a column cause error if a view depends on it? | NO
View' is updated with to use the new column name |
Does lo.sql unlink large objects when table is truncated? | NO |
Classes
PostgreSQLAdapter
Task | Status | UnitTest |
---|---|---|
Implement setQueryTime with Timer object
|
DONE | |
Refactor escaping literals
|
DONE | |
appendMatchExpression
|
DONE | |
indexNameMatches
|
||
appendSuffixHint
|
||
appendLiteral
|
DONE | |
getBind
|
||
isLiteral
|
DONE | |
appendTypeConversion
|
DONE | |
isUnicode
|
||
s_bindFactoryArray[Primitive.BINARY_ORDINAL]
|
||
DUPLICATE_KEY_NAME_PATTERN
|
||
s_bindFactoryArray
|
PostgreSQLSchemaManager
Task | Status | UnitTest |
---|---|---|
Override setCustomDatabaseProperties
|
||
dropTable
|
||
getGUIDExpr
|
||
remove trigger and procedure suffix $uid | ||
getDefaultLongspace, getDefaultTablespace, getDefaultIndexspace
|
||
getPrimaryKeys
|
||
generateIndexName
|
||
appendColumnType
|
||
Refactor creating and deleting full-text search indexes
|
||
Refactor checking for BLOB column to isBLOB | ||
Refactor checking for full-text search index on a column to getFullTextIndex | ||
alterColumn - use this logic
|
||
renameColumn - use this logic for
|
||
dropIndex
|
||
appendColumnAlternation
|
||
renameTable
|
||
deleteLargeObjects
|
||
getIndexInfo
|
||
Use toMetadataCase and toDatabaseCase instead of toLowerCase/toUpperCase |
Scripts
postgresql_create.sql
Task | Status | UnitTest |
---|---|---|
postgresql_setup.sql
Task | Status | UnitTest |
---|---|---|
Add comment to enable PREPARE TRANSACTION | ||
Use template field to set location of contrib folder
|
||
Add template field to set location for tablespace, indexspace and longspace | ||
Add SQL to create tablespace, indexspace and longspace | ||
Move function creation to postgresql_create.sql |
postgresql_drop.sql
Task | Status | UnitTest |
---|---|---|
Add sql to drop custom functions |