trafodion-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sure...@apache.org
Subject [1/2] incubator-trafodion git commit: Fix JIRA306
Date Tue, 05 Jul 2016 13:25:42 GMT
Repository: incubator-trafodion
Updated Branches:
  refs/heads/master aaf59d2af -> f1b85eebd


Fix JIRA306


Project: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/commit/000be49e
Tree: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/tree/000be49e
Diff: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/diff/000be49e

Branch: refs/heads/master
Commit: 000be49ed6472adaf0de5355cdc39e23f266952c
Parents: eb063d4
Author: ryzuo <joshuamurdoc@gmail.com>
Authored: Tue Jul 5 07:38:31 2016 +0000
Committer: ryzuo <joshuamurdoc@gmail.com>
Committed: Tue Jul 5 07:38:31 2016 +0000

----------------------------------------------------------------------
 .../odbc/src/odbc/nsksrvrcore/srvrothers.cpp    | 143 +++++++++----------
 1 file changed, 70 insertions(+), 73 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/000be49e/core/conn/odbc/src/odbc/nsksrvrcore/srvrothers.cpp
----------------------------------------------------------------------
diff --git a/core/conn/odbc/src/odbc/nsksrvrcore/srvrothers.cpp b/core/conn/odbc/src/odbc/nsksrvrcore/srvrothers.cpp
index 4075e86..e365ddc 100644
--- a/core/conn/odbc/src/odbc/nsksrvrcore/srvrothers.cpp
+++ b/core/conn/odbc/src/odbc/nsksrvrcore/srvrothers.cpp
@@ -4505,79 +4505,76 @@ odbc_SQLSvc_GetSQLCatalogs_sme_(
                 case SQL_API_SQLGETTYPEINFO :
                         // strcpy((char *)catStmtLabel, "SQL_GETTYPEINFO_UNICODE_Q1");
                        snprintf(CatalogQuery,sizeof(CatalogQuery),
-  "select distinct TYPE_NAME TYPE_NAME,"
-        "DATA_TYPE DATA_TYPE,PREC COLUMN_SIZE,"
-        "LITERAL_PREFIX LITERAL_PREFIX,"
-        "LITERAL_SUFFIX LITERAL_SUFFIX,"
-        "CREATE_PARAMS CREATE_PARAMS,"
-        "IS_NULLABLE NULLABLE,"
-        "CASE_SENSITIVE CASE_SENSITIVE,"
-        "SEARCHABLE SEARCHABLE,"
-        "UNSIGNED_ATTRIBUTE UNSIGNED_ATTRIBUTE,"
-        "FIXED_PREC_SCALE FIXED_PREC_SCALE,"
-        "AUTO_UNIQUE_VALUE AUTO_UNIQUE_VALUE,"
-        "LOCAL_TYPE_NAME LOCAL_TYPE_NAME,"
-        "MINIMUM_SCALE MINIMUM_SCALE,"
-        "MAXIMUM_SCALE MAXIMUM_SCALE,"
-        "SQL_DATA_TYPE SQL_DATA_TYPE,"
-        "SQL_DATETIME_SUB SQL_DATETIME_SUB,"
-        "NUM_PREC_RADIX NUM_PREC_RADIX,"
-        "INTERVAL_PRECISION INTERVAL_PRECISION "
- " from "
- " (VALUES "
-        "(cast('BIGINT' as varchar(128)),cast(-5 as smallint), cast(19 as integer), cast
(NULL as varchar(128)), cast (NULL as varchar(128)),"
-        "cast (NULL as varchar(128)), cast(1 as smallint), cast(0 as smallint), cast(2 as
smallint) , cast(0 as smallint), cast(0 as smallint),"
-        "cast(0 as smallint), cast('LARGEINT' as varchar(128)), cast(NULL as smallint), cast(NULL
as smallint), cast('LARGEINT' as varchar(128)),"
-        "cast(10 as smallint), cast(19 as integer), cast(20 as integer), cast(-402 as smallint),
cast(NULL as smallint), cast(NULL as smallint),"
-         "cast(0 as smallint), cast(0 as smallint), cast(3 as smallint), cast(0 as smallint)),"
-        "('BIGINT SIGNED', -5, 19, NULL, NULL, NULL, 1, 0, 2, 0, 0, 0, 'LARGEINT', NULL,
NULL, 'SIGNED LARGEINT', 10, 19, 20, -402, NULL, NULL, 0, 0, 3, 0),"
-        "('CHAR', 1, 32000, '''', '''', 'max length', 1, 1, 3, NULL, 0, NULL, 'CHARACTER',
NULL, NULL, 'CHARACTER', NULL, -1, -1, 1, NULL, NULL, 0, 0, 3, 0),"
-        "('DATE', 91, 10, '{d ''', '''}', NULL, 1, 0, 2, NULL, 0, NULL, 'DATE', NULL, NULL,
'DATE', NULL, 10, 6, 9, 1, NULL, 1, 3, 3, 0),"
-        "('DECIMAL', 3, 18, NULL, NULL, 'precision,scale', 1, 0, 2, 0, 0, 0, 'DECIMAL', 0,
18, 'DECIMAL', 10, -2, -3, 3, NULL, NULL, 0, 0, 3, 0),"
-        "('DECIMAL SIGNED', 3, 18, NULL, NULL, 'precision,scale', 1, 0, 2, 0, 0, 0, 'DECIMAL',
0, 18, 'SIGNED DECIMAL', 10, -2, -3, 3, NULL, NULL, 0, 0, 3, 0),"
-        "('DECIMAL UNSIGNED', 3, 18, NULL, NULL, 'precision,scale', 1, 0, 2, 1, 0, 0, 'DECIMAL',
0, 18, 'UNSIGNED DECIMAL', 10, -2, -3, -301, NULL, NULL, 0, 0, 3, 0),"
-        "('DOUBLE PRECISION', 8, 15, NULL, NULL, NULL, 1, 0, 2, 0, 0, 0, 'DOUBLE', NULL,
NULL, 'DOUBLE PRECISION', 2, 54, -1, 8, NULL, NULL, 0, 0, 3, 0),"
-        "('DOUBLE PRECISION', 8, 15, NULL, NULL, NULL, 1, 0, 2, 0, 0, 0, 'DOUBLE', NULL,
NULL, 'DOUBLE', 2, 54, -1, 8, NULL, NULL, 0, 0, 3, 0),"
-        "('FLOAT', 6, 15, NULL, NULL, NULL, 1, 0, 2, 0, 0, 0, 'FLOAT', NULL, NULL, 'FLOAT',
2, -2, -1, 6, NULL, NULL, 0, 0, 3, 0),"
-        "('INTEGER', 4, 10, NULL, NULL, NULL, 1, 0, 2, 0, 0, 0, 'INTEGER', NULL, NULL, 'INTEGER',
10, 10, -1, 4, NULL, NULL, 0, 0, 3, 0),"
-        "('INTEGER SIGNED', 4, 10, NULL, NULL, NULL, 1, 0, 2, 0, 0, 0, 'INTEGER', NULL, NULL,
'SIGNED INTEGER', 10, 10, -1, 4, NULL, NULL, 0, 0, 3, 0),"
-        "('INTEGER UNSIGNED', 4, 10, NULL, NULL, NULL, 1, 0, 2, 1, 0, 0, 'INTEGER', NULL,
NULL, 'UNSIGNED INTEGER', 10, 10, -1, -401, NULL, NULL, 0, 0, 3, 0),"
-        "('INTERVAL', 113, 0, '{INTERVAL ''', ''' MINUTE TO SECOND}', NULL, 1, 0, 2, 0, 0,
NULL, 'INTERVAL', 0, 0, 'INTERVAL', NULL, 3, 34, 100, 13, 2, 5, 6, 3, 0),"
-        "('INTERVAL', 105, 0, '{INTERVAL ''', ''' MINUTE}', NULL, 1, 0, 2, 0, 0, NULL, 'INTERVAL',
0, 0, 'INTERVAL', NULL, 0, 34, 100, 5, 2, 5, 5, 3, 0),"
-        "('INTERVAL', 101, 0, '{INTERVAL ''', ''' YEAR}', NULL, 1, 0, 2, 0, 0, NULL, 'INTERVAL',
0, 0, 'INTERVAL', NULL, 0, 34, 100, 1, 2, 1, 1, 3, 0),"
-        "('INTERVAL', 106, 0, '{INTERVAL ''', ''' SECOND}', NULL, 1, 0, 2, 0, 0, NULL, 'INTERVAL',
0, 0, 'INTERVAL', NULL, 0, 34, 100, 6, 2, 6, 6, 3, 0),"
-        "('INTERVAL', 104, 0, '{INTERVAL ''', ''' HOUR}', NULL, 1, 0, 2, 0, 0, NULL, 'INTERVAL',
0, 0, 'INTERVAL', NULL, 0, 34, 100, 4, 2, 4, 4, 3, 0),"
-        "('INTERVAL', 107, 0, '{INTERVAL ''', ''' YEAR TO MONTH}', NULL, 1, 0, 2, 0, 0, NULL,
'INTERVAL', 0, 0, 'INTERVAL', NULL, 3, 34, 100, 7, 2, 1, 2, 3, 0),"
-        "('INTERVAL', 108, 0, '{INTERVAL ''', ''' DAY TO HOUR}', NULL, 1, 0, 2, 0, 0, NULL,
'INTERVAL', 0, 0, 'INTERVAL', NULL, 3, 34, 100, 8, 2, 3, 4, 3, 0),"
-        "('INTERVAL', 102, 0, '{INTERVAL ''', ''' MONTH}', NULL, 1, 0, 2, 0, 0, NULL, 'INTERVAL',
0, 0, 'INTERVAL', NULL, 0, 34, 100, 2, 2, 2, 2, 3, 0),"
-        "('INTERVAL', 111, 0, '{INTERVAL ''', ''' HOUR TO MINUTE}', NULL, 1, 0, 2, 0, 0,
NULL, 'INTERVAL', 0, 0, 'INTERVAL', NULL, 3, 34, 100, 11, 2, 4, 5, 3, 0),"
-        "('INTERVAL', 112, 0, '{INTERVAL ''', ''' HOUR TO SECOND}', NULL, 1, 0, 2, 0, 0,
NULL, 'INTERVAL', 0, 0, 'INTERVAL', NULL, 6, 34, 100, 12, 2, 4, 6, 3, 0),"
-        "('INTERVAL', 110, 0, '{INTERVAL ''', ''' DAY TO SECOND}', NULL, 1, 0, 2, 0, 0, NULL,
'INTERVAL', 0, 0, 'INTERVAL', NULL, 9, 34, 100, 10, 2, 3, 6, 3, 0),"
-        "('INTERVAL', 109, 0, '{INTERVAL ''', ''' DAY TO MINUTE}', NULL, 1, 0, 2, 0, 0, NULL,
'INTERVAL', 0, 0, 'INTERVAL', NULL, 6, 34, 100, 9, 2, 3, 5, 3, 0),"
-        "('INTERVAL', 103, 0, '{INTERVAL ''', ''' DAY}', NULL, 1, 0, 2, 0, 0, NULL, 'INTERVAL',
0, 0, 'INTERVAL', NULL, 0, 34, 100, 3, 2, 3, 3, 3, 0),"
-        "('NUMERIC', 2, 128, NULL, NULL, 'precision,scale', 1, 0, 2, 0, 0, 0, 'NUMERIC',
0, 128, 'NUMERIC', 10, -2, -3, 2, NULL, NULL, 0, 0, 3, 0),"
-        "('NUMERIC SIGNED', 2, 128, NULL, NULL, 'precision,scale', 1, 0, 2, 0, 0, 0, 'NUMERIC',
0, 128, 'SIGNED NUMERIC', 10, -2, -3, 2, NULL, NULL, 0, 0, 3, 0),"
-        "('NUMERIC UNSIGNED', 2, 128, NULL, NULL, 'precision,scale', 1, 0, 2, 1, 0, 0, 'NUMERIC',
0, 128, 'UNSIGNED NUMERIC', 10, -2, -3, 2, NULL, NULL, 0, 0, 3, 0),"
-        "('REAL', 7, 7, NULL, NULL, NULL, 1, 0, 2, 0, 0, 0, 'REAL', NULL, NULL, 'REAL', 2,
22, -1, 7, NULL, NULL, 0, 0, 3, 0),"
-        "('SMALLINT', 5, 5, NULL, NULL, NULL, 1, 0, 2, 0, 0, 0, 'SMALLINT', NULL, NULL, 'SMALLINT',
10, 5, -1, 5, NULL, NULL, 0, 0, 3, 0),"
-        "('SMALLINT SIGNED', 5, 5, NULL, NULL, NULL, 1, 0, 2, 0, 0, 0, 'SMALLINT', NULL,
NULL, 'SIGNED SMALLINT', 10, 5, -1, 5, NULL, NULL, 0, 0, 3, 0),"
-        "('SMALLINT UNSIGNED', 5, 5, NULL, NULL, NULL, 1, 0, 2, 1, 0, 0, 'SMALLINT', NULL,
NULL, 'UNSIGNED SMALLINT', 10, 5, -1, -502, NULL, NULL, 0, 0, 3, 0),"
-        "('TIME', 92, 8, '{t ''', '''}', NULL, 1, 0, 2, NULL, 0, NULL, 'TIME', NULL, NULL,
'TIME', NULL, 8, 6, 9, 2, NULL, 4, 6, 3, 0),"
-        "('TIMESTAMP', 93, 26, '{ts ''', '''}', NULL, 1, 0, 2, NULL, 0, NULL, 'TIMESTAMP',
0, 6, 'TIMESTAMP', NULL, 19, 16, 9, 3, NULL, 1, 6, 3, 0),"
-        "('VARCHAR', 12, 32000, '''', '''', 'max length', 1, 1, 3, NULL, 0, NULL, 'VARCHAR',
NULL, NULL, 'VARCHAR', NULL, -1, -1, 12, NULL, NULL, 0, 0, 3, 0)"
-         " ) "
-  " dt(\"TYPE_NAME\", \"DATA_TYPE\", \"PREC\", \"LITERAL_PREFIX\", \"LITERAL_SUFFIX\", \"CREATE_PARAMS\",
\"IS_NULLABLE\", \"CASE_SENSITIVE\", \"SEARCHABLE\","
-  "\"UNSIGNED_ATTRIBUTE\", \"FIXED_PREC_SCALE\", \"AUTO_UNIQUE_VALUE\", \"LOCAL_TYPE_NAME\",
\"MINIMUM_SCALE\", \"MAXIMUM_SCALE\", \"SQL_TYPE_NAME\","
-  "\"NUM_PREC_RADIX\", \"USEPRECISION\", \"USELENGTH\", \"SQL_DATA_TYPE\", \"SQL_DATETIME_SUB\",
\"INTERVAL_PRECISION\", \"DATETIMESTARTFIELD\","
-  "\"DATETIMEENDFIELD\", \"APPLICATION_VERSION\", \"TRANSLATION_ID\")"
-" ORDER BY 2,1 FOR READ UNCOMMITTED ACCESS ;" );
-                        break;
-
-		case SQL_API_SQLPROCEDURES :
-		//	strcpy((char *)catStmtLabel, "SQL_PROCEDURES_ANSI_Q4");
-
-			if (!checkIfWildCard(catalogNm, expCatalogNm) && !metadataId)
-			{
+                               "select distinct TYPE_NAME TYPE_NAME,"
+                               "DATA_TYPE DATA_TYPE,PREC COLUMN_SIZE,"
+                               "LITERAL_PREFIX LITERAL_PREFIX,"
+                               "LITERAL_SUFFIX LITERAL_SUFFIX,"
+                               "CREATE_PARAMS CREATE_PARAMS,"
+                               "IS_NULLABLE NULLABLE,"
+                               "CASE_SENSITIVE CASE_SENSITIVE,"
+                               "SEARCHABLE SEARCHABLE,"
+                               "UNSIGNED_ATTRIBUTE UNSIGNED_ATTRIBUTE,"
+                               "FIXED_PREC_SCALE FIXED_PREC_SCALE,"
+                               "AUTO_UNIQUE_VALUE AUTO_UNIQUE_VALUE,"
+                               "LOCAL_TYPE_NAME LOCAL_TYPE_NAME,"
+                               "MINIMUM_SCALE MINIMUM_SCALE,"
+                               "MAXIMUM_SCALE MAXIMUM_SCALE,"
+                               "SQL_DATA_TYPE SQL_DATA_TYPE,"
+                               "SQL_DATETIME_SUB SQL_DATETIME_SUB,"
+                               "NUM_PREC_RADIX NUM_PREC_RADIX,"
+                               "INTERVAL_PRECISION INTERVAL_PRECISION "
+                               " from "
+                               " (VALUES "
+                               "(cast('BIGINT' as varchar(128)),cast(-5 as smallint), cast(19
as integer), cast (NULL as varchar(128)), cast (NULL as varchar(128)),"
+                               "cast (NULL as varchar(128)), cast(1 as smallint), cast(0
as smallint), cast(2 as smallint) , cast(0 as smallint), cast(0 as smallint),"
+                               "cast(0 as smallint), cast('LARGEINT' as varchar(128)), cast(NULL
as smallint), cast(NULL as smallint), cast('LARGEINT' as varchar(128)),"
+                               "cast(10 as smallint), cast(19 as integer), cast(20 as integer),
cast(-402 as smallint), cast(NULL as smallint), cast(NULL as smallint),"
+                               "cast(0 as smallint), cast(0 as smallint), cast(3 as smallint),
cast(0 as smallint)),"
+                               "('BIGINT SIGNED', -5, 19, NULL, NULL, NULL, 1, 0, 2, 0, 0,
0, 'LARGEINT', NULL, NULL, 'SIGNED LARGEINT', 10, 19, 20, -402, NULL, NULL, 0, 0, 3, 0),"
+                               "('CHAR', 1, 32000, '''', '''', 'max length', 1, 1, 3, NULL,
0, NULL, 'CHARACTER', NULL, NULL, 'CHARACTER', NULL, -1, -1, 1, NULL, NULL, 0, 0, 3, 0),"
+                               "('DATE', 9, 10, '{d ''', '''}', NULL, 1, 0, 2, NULL, 0, NULL,
'DATE', NULL, NULL, 'DATE', NULL, 10, 6, 9, 1, NULL, 1, 3, 3, 0),"
+                               "('DECIMAL', 3, 18, NULL, NULL, 'precision,scale', 1, 0, 2,
0, 0, 0, 'DECIMAL', 0, 18, 'DECIMAL', 10, -2, -3, 3, NULL, NULL, 0, 0, 3, 0),"
+                               "('DECIMAL UNSIGNED', 3, 18, NULL, NULL, 'precision,scale',
1, 0, 2, 1, 0, 0, 'DECIMAL', 0, 18, 'UNSIGNED DECIMAL', 10, -2, -3, -301, NULL, NULL, 0, 0,
3, 0),"
+                               "('DOUBLE PRECISION', 8, 15, NULL, NULL, NULL, 1, 0, 2, 0,
0, 0, 'DOUBLE', NULL, NULL, 'DOUBLE PRECISION', 2, 54, -1, 8, NULL, NULL, 0, 0, 3, 0),"
+                               "('DOUBLE PRECISION', 8, 15, NULL, NULL, NULL, 1, 0, 2, 0,
0, 0, 'DOUBLE', NULL, NULL, 'DOUBLE', 2, 54, -1, 8, NULL, NULL, 0, 0, 3, 0),"
+                               "('FLOAT', 6, 15, NULL, NULL, NULL, 1, 0, 2, 0, 0, 0, 'FLOAT',
NULL, NULL, 'FLOAT', 2, -2, -1, 6, NULL, NULL, 0, 0, 3, 0),"
+                               "('INTEGER', 4, 10, NULL, NULL, NULL, 1, 0, 2, 0, 0, 0, 'INTEGER',
NULL, NULL, 'INTEGER', 10, 10, -1, 4, NULL, NULL, 0, 0, 3, 0),"
+                               "('INTEGER UNSIGNED', 4, 10, NULL, NULL, NULL, 1, 0, 2, 1,
0, 0, 'INTEGER', NULL, NULL, 'UNSIGNED INTEGER', 10, 10, -1, -401, NULL, NULL, 0, 0, 3, 0),"
+                               "('INTERVAL', 113, 0, '{INTERVAL ''', ''' MINUTE TO SECOND}',
NULL, 1, 0, 2, 0, 0, NULL, 'INTERVAL', 0, 0, 'INTERVAL', NULL, 3, 34, 100, 13, 2, 5, 6, 3,
0),"
+                               "('INTERVAL', 105, 0, '{INTERVAL ''', ''' MINUTE}', NULL,
1, 0, 2, 0, 0, NULL, 'INTERVAL', 0, 0, 'INTERVAL', NULL, 0, 34, 100, 5, 2, 5, 5, 3, 0),"
+                               "('INTERVAL', 101, 0, '{INTERVAL ''', ''' YEAR}', NULL, 1,
0, 2, 0, 0, NULL, 'INTERVAL', 0, 0, 'INTERVAL', NULL, 0, 34, 100, 1, 2, 1, 1, 3, 0),"
+                               "('INTERVAL', 106, 0, '{INTERVAL ''', ''' SECOND}', NULL,
1, 0, 2, 0, 0, NULL, 'INTERVAL', 0, 0, 'INTERVAL', NULL, 0, 34, 100, 6, 2, 6, 6, 3, 0),"
+                               "('INTERVAL', 104, 0, '{INTERVAL ''', ''' HOUR}', NULL, 1,
0, 2, 0, 0, NULL, 'INTERVAL', 0, 0, 'INTERVAL', NULL, 0, 34, 100, 4, 2, 4, 4, 3, 0),"
+                               "('INTERVAL', 107, 0, '{INTERVAL ''', ''' YEAR TO MONTH}',
NULL, 1, 0, 2, 0, 0, NULL, 'INTERVAL', 0, 0, 'INTERVAL', NULL, 3, 34, 100, 7, 2, 1, 2, 3,
0),"
+                               "('INTERVAL', 108, 0, '{INTERVAL ''', ''' DAY TO HOUR}', NULL,
1, 0, 2, 0, 0, NULL, 'INTERVAL', 0, 0, 'INTERVAL', NULL, 3, 34, 100, 8, 2, 3, 4, 3, 0),"
+                               "('INTERVAL', 102, 0, '{INTERVAL ''', ''' MONTH}', NULL, 1,
0, 2, 0, 0, NULL, 'INTERVAL', 0, 0, 'INTERVAL', NULL, 0, 34, 100, 2, 2, 2, 2, 3, 0),"
+                               "('INTERVAL', 111, 0, '{INTERVAL ''', ''' HOUR TO MINUTE}',
NULL, 1, 0, 2, 0, 0, NULL, 'INTERVAL', 0, 0, 'INTERVAL', NULL, 3, 34, 100, 11, 2, 4, 5, 3,
0),"
+                               "('INTERVAL', 112, 0, '{INTERVAL ''', ''' HOUR TO SECOND}',
NULL, 1, 0, 2, 0, 0, NULL, 'INTERVAL', 0, 0, 'INTERVAL', NULL, 6, 34, 100, 12, 2, 4, 6, 3,
0),"
+                               "('INTERVAL', 110, 0, '{INTERVAL ''', ''' DAY TO SECOND}',
NULL, 1, 0, 2, 0, 0, NULL, 'INTERVAL', 0, 0, 'INTERVAL', NULL, 9, 34, 100, 10, 2, 3, 6, 3,
0),"
+                               "('INTERVAL', 109, 0, '{INTERVAL ''', ''' DAY TO MINUTE}',
NULL, 1, 0, 2, 0, 0, NULL, 'INTERVAL', 0, 0, 'INTERVAL', NULL, 6, 34, 100, 9, 2, 3, 5, 3,
0),"
+                               "('INTERVAL', 103, 0, '{INTERVAL ''', ''' DAY}', NULL, 1,
0, 2, 0, 0, NULL, 'INTERVAL', 0, 0, 'INTERVAL', NULL, 0, 34, 100, 3, 2, 3, 3, 3, 0),"
+                               "('NUMERIC', 2, 128, NULL, NULL, 'precision,scale', 1, 0,
2, 0, 0, 0, 'NUMERIC', 0, 128, 'NUMERIC', 10, -2, -3, 2, NULL, NULL, 0, 0, 3, 0),"
+                               "('NUMERIC UNSIGNED', 2, 128, NULL, NULL, 'precision,scale',
1, 0, 2, 1, 0, 0, 'NUMERIC', 0, 128, 'UNSIGNED NUMERIC', 10, -2, -3, 2, NULL, NULL, 0, 0,
3, 0),"
+                               "('REAL', 7, 7, NULL, NULL, NULL, 1, 0, 2, 0, 0, 0, 'REAL',
NULL, NULL, 'REAL', 2, 22, -1, 7, NULL, NULL, 0, 0, 3, 0),"
+                               "('SMALLINT', 5, 5, NULL, NULL, NULL, 1, 0, 2, 0, 0, 0, 'SMALLINT',
NULL, NULL, 'SMALLINT', 10, 5, -1, 5, NULL, NULL, 0, 0, 3, 0),"
+                               "('SMALLINT UNSIGNED', 5, 5, NULL, NULL, NULL, 1, 0, 2, 1,
0, 0, 'SMALLINT', NULL, NULL, 'UNSIGNED SMALLINT', 10, 5, -1, -502, NULL, NULL, 0, 0, 3, 0),"
+                               "('TIME', 10, 8, '{t ''', '''}', NULL, 1, 0, 2, NULL, 0, NULL,
'TIME', NULL, NULL, 'TIME', NULL, 8, 6, 9, 2, NULL, 4, 6, 3, 0),"
+                               "('TIMESTAMP', 11, 26, '{ts ''', '''}', NULL, 1, 0, 2, NULL,
0, NULL, 'TIMESTAMP', 0, 6, 'TIMESTAMP', NULL, 19, 16, 9, 3, NULL, 1, 6, 3, 0),"
+                               "('VARCHAR', 12, 32000, '''', '''', 'max length', 1, 1, 3,
NULL, 0, NULL, 'VARCHAR', NULL, NULL, 'VARCHAR', NULL, -1, -1, 12, NULL, NULL, 0, 0, 3, 0)"
+                               " ) "
+                               " dt(\"TYPE_NAME\", \"DATA_TYPE\", \"PREC\", \"LITERAL_PREFIX\",
\"LITERAL_SUFFIX\", \"CREATE_PARAMS\", \"IS_NULLABLE\", \"CASE_SENSITIVE\", \"SEARCHABLE\","
+                               "\"UNSIGNED_ATTRIBUTE\", \"FIXED_PREC_SCALE\", \"AUTO_UNIQUE_VALUE\",
\"LOCAL_TYPE_NAME\", \"MINIMUM_SCALE\", \"MAXIMUM_SCALE\", \"SQL_TYPE_NAME\","
+                               "\"NUM_PREC_RADIX\", \"USEPRECISION\", \"USELENGTH\", \"SQL_DATA_TYPE\",
\"SQL_DATETIME_SUB\", \"INTERVAL_PRECISION\", \"DATETIMESTARTFIELD\","
+                               "\"DATETIMEENDFIELD\", \"APPLICATION_VERSION\", \"TRANSLATION_ID\")"
+                               " WHERE DATA_TYPE=%d" 
+                               " ORDER BY 2,1 FOR READ UNCOMMITTED ACCESS ;", sqlType);
+                       break;
+
+                case SQL_API_SQLPROCEDURES :
+                       //	strcpy((char *)catStmtLabel, "SQL_PROCEDURES_ANSI_Q4");
+
+                       if (!checkIfWildCard(catalogNm, expCatalogNm) && !metadataId)
+                       {
 				exception_->exception_nr = odbc_SQLSvc_GetSQLCatalogs_ParamError_exn_;
 				exception_->u.ParamError.ParamDesc = SQLSVC_EXCEPTION_WILDCARD_NOT_SUPPORTED;
 				goto MapException;


Mime
View raw message