Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
Postgres FD Implementation
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Abuhujair Javed
Postgres FD Implementation
Commits
26dc5014
Commit
26dc5014
authored
Feb 11, 2001
by
Bruce Momjian
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
More cleanup.
parent
82b1fd1e
Changes
38
Show whitespace changes
Inline
Side-by-side
Showing
38 changed files
with
775 additions
and
553 deletions
+775
-553
src/interfaces/odbc/bind.c
src/interfaces/odbc/bind.c
+9
-9
src/interfaces/odbc/bind.h
src/interfaces/odbc/bind.h
+1
-1
src/interfaces/odbc/columninfo.c
src/interfaces/odbc/columninfo.c
+5
-5
src/interfaces/odbc/columninfo.h
src/interfaces/odbc/columninfo.h
+5
-5
src/interfaces/odbc/connection.c
src/interfaces/odbc/connection.c
+25
-25
src/interfaces/odbc/connection.h
src/interfaces/odbc/connection.h
+41
-41
src/interfaces/odbc/convert.c
src/interfaces/odbc/convert.c
+7
-7
src/interfaces/odbc/convert.h
src/interfaces/odbc/convert.h
+8
-8
src/interfaces/odbc/dlg_specific.c
src/interfaces/odbc/dlg_specific.c
+7
-7
src/interfaces/odbc/dlg_specific.h
src/interfaces/odbc/dlg_specific.h
+7
-7
src/interfaces/odbc/drvconn.c
src/interfaces/odbc/drvconn.c
+7
-7
src/interfaces/odbc/environ.c
src/interfaces/odbc/environ.c
+12
-11
src/interfaces/odbc/environ.h
src/interfaces/odbc/environ.h
+5
-5
src/interfaces/odbc/execute.c
src/interfaces/odbc/execute.c
+6
-6
src/interfaces/odbc/gpps.h
src/interfaces/odbc/gpps.h
+15
-15
src/interfaces/odbc/info.c
src/interfaces/odbc/info.c
+51
-51
src/interfaces/odbc/isql.h
src/interfaces/odbc/isql.h
+27
-27
src/interfaces/odbc/isqlext.h
src/interfaces/odbc/isqlext.h
+71
-68
src/interfaces/odbc/lobj.c
src/interfaces/odbc/lobj.c
+8
-8
src/interfaces/odbc/lobj.h
src/interfaces/odbc/lobj.h
+8
-8
src/interfaces/odbc/options.c
src/interfaces/odbc/options.c
+4
-4
src/interfaces/odbc/parse.c
src/interfaces/odbc/parse.c
+5
-5
src/interfaces/odbc/pgtypes.c
src/interfaces/odbc/pgtypes.c
+21
-21
src/interfaces/odbc/pgtypes.h
src/interfaces/odbc/pgtypes.h
+17
-17
src/interfaces/odbc/psqlodbc.h
src/interfaces/odbc/psqlodbc.h
+4
-4
src/interfaces/odbc/qresult.c
src/interfaces/odbc/qresult.c
+13
-13
src/interfaces/odbc/qresult.h
src/interfaces/odbc/qresult.h
+15
-15
src/interfaces/odbc/results.c
src/interfaces/odbc/results.c
+16
-16
src/interfaces/odbc/setup.c
src/interfaces/odbc/setup.c
+2
-2
src/interfaces/odbc/socket.c
src/interfaces/odbc/socket.c
+12
-12
src/interfaces/odbc/socket.h
src/interfaces/odbc/socket.h
+12
-12
src/interfaces/odbc/statement.c
src/interfaces/odbc/statement.c
+14
-14
src/interfaces/odbc/statement.h
src/interfaces/odbc/statement.h
+18
-18
src/interfaces/odbc/tuple.c
src/interfaces/odbc/tuple.c
+4
-4
src/interfaces/odbc/tuple.h
src/interfaces/odbc/tuple.h
+4
-4
src/interfaces/odbc/tuplelist.c
src/interfaces/odbc/tuplelist.c
+3
-3
src/interfaces/odbc/tuplelist.h
src/interfaces/odbc/tuplelist.h
+3
-3
src/tools/pgindent/pgindent
src/tools/pgindent/pgindent
+283
-65
No files found.
src/interfaces/odbc/bind.c
View file @
26dc5014
...
@@ -46,7 +46,7 @@ SQLBindParameter(
...
@@ -46,7 +46,7 @@ SQLBindParameter(
SWORD
ibScale
,
SWORD
ibScale
,
PTR
rgbValue
,
PTR
rgbValue
,
SDWORD
cbValueMax
,
SDWORD
cbValueMax
,
SDWORD
FAR
*
pcbValue
)
SDWORD
FAR
*
pcbValue
)
{
{
StatementClass
*
stmt
=
(
StatementClass
*
)
hstmt
;
StatementClass
*
stmt
=
(
StatementClass
*
)
hstmt
;
static
char
*
func
=
"SQLBindParameter"
;
static
char
*
func
=
"SQLBindParameter"
;
...
@@ -163,7 +163,7 @@ SQLBindCol(
...
@@ -163,7 +163,7 @@ SQLBindCol(
SWORD
fCType
,
SWORD
fCType
,
PTR
rgbValue
,
PTR
rgbValue
,
SDWORD
cbValueMax
,
SDWORD
cbValueMax
,
SDWORD
FAR
*
pcbValue
)
SDWORD
FAR
*
pcbValue
)
{
{
StatementClass
*
stmt
=
(
StatementClass
*
)
hstmt
;
StatementClass
*
stmt
=
(
StatementClass
*
)
hstmt
;
static
char
*
func
=
"SQLBindCol"
;
static
char
*
func
=
"SQLBindCol"
;
...
@@ -271,10 +271,10 @@ RETCODE SQL_API
...
@@ -271,10 +271,10 @@ RETCODE SQL_API
SQLDescribeParam
(
SQLDescribeParam
(
HSTMT
hstmt
,
HSTMT
hstmt
,
UWORD
ipar
,
UWORD
ipar
,
SWORD
FAR
*
pfSqlType
,
SWORD
FAR
*
pfSqlType
,
UDWORD
FAR
*
pcbColDef
,
UDWORD
FAR
*
pcbColDef
,
SWORD
FAR
*
pibScale
,
SWORD
FAR
*
pibScale
,
SWORD
FAR
*
pfNullable
)
SWORD
FAR
*
pfNullable
)
{
{
StatementClass
*
stmt
=
(
StatementClass
*
)
hstmt
;
StatementClass
*
stmt
=
(
StatementClass
*
)
hstmt
;
static
char
*
func
=
"SQLDescribeParam"
;
static
char
*
func
=
"SQLDescribeParam"
;
...
@@ -325,7 +325,7 @@ RETCODE SQL_API
...
@@ -325,7 +325,7 @@ RETCODE SQL_API
SQLParamOptions
(
SQLParamOptions
(
HSTMT
hstmt
,
HSTMT
hstmt
,
UDWORD
crow
,
UDWORD
crow
,
UDWORD
FAR
*
pirow
)
UDWORD
FAR
*
pirow
)
{
{
static
char
*
func
=
"SQLParamOptions"
;
static
char
*
func
=
"SQLParamOptions"
;
...
@@ -347,7 +347,7 @@ SQLParamOptions(
...
@@ -347,7 +347,7 @@ SQLParamOptions(
RETCODE
SQL_API
RETCODE
SQL_API
SQLNumParams
(
SQLNumParams
(
HSTMT
hstmt
,
HSTMT
hstmt
,
SWORD
FAR
*
pcpar
)
SWORD
FAR
*
pcpar
)
{
{
StatementClass
*
stmt
=
(
StatementClass
*
)
hstmt
;
StatementClass
*
stmt
=
(
StatementClass
*
)
hstmt
;
char
in_quote
=
FALSE
;
char
in_quote
=
FALSE
;
...
@@ -421,7 +421,7 @@ create_empty_bindings(int num_columns)
...
@@ -421,7 +421,7 @@ create_empty_bindings(int num_columns)
}
}
void
void
extend_bindings
(
StatementClass
*
stmt
,
int
num_columns
)
extend_bindings
(
StatementClass
*
stmt
,
int
num_columns
)
{
{
static
char
*
func
=
"extend_bindings"
;
static
char
*
func
=
"extend_bindings"
;
BindInfoClass
*
new_bindings
;
BindInfoClass
*
new_bindings
;
...
...
src/interfaces/odbc/bind.h
View file @
26dc5014
...
@@ -49,6 +49,6 @@ struct ParameterInfoClass_
...
@@ -49,6 +49,6 @@ struct ParameterInfoClass_
};
};
BindInfoClass
*
create_empty_bindings
(
int
num_columns
);
BindInfoClass
*
create_empty_bindings
(
int
num_columns
);
void
extend_bindings
(
StatementClass
*
stmt
,
int
num_columns
);
void
extend_bindings
(
StatementClass
*
stmt
,
int
num_columns
);
#endif
#endif
src/interfaces/odbc/columninfo.c
View file @
26dc5014
...
@@ -38,7 +38,7 @@ CI_Constructor()
...
@@ -38,7 +38,7 @@ CI_Constructor()
}
}
void
void
CI_Destructor
(
ColumnInfoClass
*
self
)
CI_Destructor
(
ColumnInfoClass
*
self
)
{
{
CI_free_memory
(
self
);
CI_free_memory
(
self
);
...
@@ -50,7 +50,7 @@ CI_Destructor(ColumnInfoClass * self)
...
@@ -50,7 +50,7 @@ CI_Destructor(ColumnInfoClass * self)
If self is null, then just read, don't store.
If self is null, then just read, don't store.
*/
*/
char
char
CI_read_fields
(
ColumnInfoClass
*
self
,
ConnectionClass
*
conn
)
CI_read_fields
(
ColumnInfoClass
*
self
,
ConnectionClass
*
conn
)
{
{
Int2
lf
;
Int2
lf
;
int
new_num_fields
;
int
new_num_fields
;
...
@@ -105,7 +105,7 @@ CI_read_fields(ColumnInfoClass * self, ConnectionClass * conn)
...
@@ -105,7 +105,7 @@ CI_read_fields(ColumnInfoClass * self, ConnectionClass * conn)
void
void
CI_free_memory
(
ColumnInfoClass
*
self
)
CI_free_memory
(
ColumnInfoClass
*
self
)
{
{
register
Int2
lf
;
register
Int2
lf
;
int
num_fields
=
self
->
num_fields
;
int
num_fields
=
self
->
num_fields
;
...
@@ -126,7 +126,7 @@ CI_free_memory(ColumnInfoClass * self)
...
@@ -126,7 +126,7 @@ CI_free_memory(ColumnInfoClass * self)
}
}
void
void
CI_set_num_fields
(
ColumnInfoClass
*
self
,
int
new_num_fields
)
CI_set_num_fields
(
ColumnInfoClass
*
self
,
int
new_num_fields
)
{
{
CI_free_memory
(
self
);
/* always safe to call */
CI_free_memory
(
self
);
/* always safe to call */
...
@@ -140,7 +140,7 @@ CI_set_num_fields(ColumnInfoClass * self, int new_num_fields)
...
@@ -140,7 +140,7 @@ CI_set_num_fields(ColumnInfoClass * self, int new_num_fields)
}
}
void
void
CI_set_field_info
(
ColumnInfoClass
*
self
,
int
field_num
,
char
*
new_name
,
CI_set_field_info
(
ColumnInfoClass
*
self
,
int
field_num
,
char
*
new_name
,
Oid
new_adtid
,
Int2
new_adtsize
,
Int4
new_atttypmod
)
Oid
new_adtid
,
Int2
new_adtsize
,
Int4
new_atttypmod
)
{
{
/* check bounds */
/* check bounds */
...
...
src/interfaces/odbc/columninfo.h
View file @
26dc5014
...
@@ -30,14 +30,14 @@ struct ColumnInfoClass_
...
@@ -30,14 +30,14 @@ struct ColumnInfoClass_
#define CI_get_atttypmod(self, col) (self->atttypmod[col])
#define CI_get_atttypmod(self, col) (self->atttypmod[col])
ColumnInfoClass
*
CI_Constructor
(
void
);
ColumnInfoClass
*
CI_Constructor
(
void
);
void
CI_Destructor
(
ColumnInfoClass
*
self
);
void
CI_Destructor
(
ColumnInfoClass
*
self
);
void
CI_free_memory
(
ColumnInfoClass
*
self
);
void
CI_free_memory
(
ColumnInfoClass
*
self
);
char
CI_read_fields
(
ColumnInfoClass
*
self
,
ConnectionClass
*
conn
);
char
CI_read_fields
(
ColumnInfoClass
*
self
,
ConnectionClass
*
conn
);
/* functions for setting up the fields from within the program, */
/* functions for setting up the fields from within the program, */
/* without reading from a socket */
/* without reading from a socket */
void
CI_set_num_fields
(
ColumnInfoClass
*
self
,
int
new_num_fields
);
void
CI_set_num_fields
(
ColumnInfoClass
*
self
,
int
new_num_fields
);
void
CI_set_field_info
(
ColumnInfoClass
*
self
,
int
field_num
,
char
*
new_name
,
void
CI_set_field_info
(
ColumnInfoClass
*
self
,
int
field_num
,
char
*
new_name
,
Oid
new_adtid
,
Int2
new_adtsize
,
Int4
atttypmod
);
Oid
new_adtid
,
Int2
new_adtsize
,
Int4
atttypmod
);
...
...
src/interfaces/odbc/connection.c
View file @
26dc5014
...
@@ -37,7 +37,7 @@ extern GLOBAL_VALUES globals;
...
@@ -37,7 +37,7 @@ extern GLOBAL_VALUES globals;
RETCODE
SQL_API
RETCODE
SQL_API
SQLAllocConnect
(
SQLAllocConnect
(
HENV
henv
,
HENV
henv
,
HDBC
FAR
*
phdbc
)
HDBC
FAR
*
phdbc
)
{
{
EnvironmentClass
*
env
=
(
EnvironmentClass
*
)
henv
;
EnvironmentClass
*
env
=
(
EnvironmentClass
*
)
henv
;
ConnectionClass
*
conn
;
ConnectionClass
*
conn
;
...
@@ -78,11 +78,11 @@ SQLAllocConnect(
...
@@ -78,11 +78,11 @@ SQLAllocConnect(
RETCODE
SQL_API
RETCODE
SQL_API
SQLConnect
(
SQLConnect
(
HDBC
hdbc
,
HDBC
hdbc
,
UCHAR
FAR
*
szDSN
,
UCHAR
FAR
*
szDSN
,
SWORD
cbDSN
,
SWORD
cbDSN
,
UCHAR
FAR
*
szUID
,
UCHAR
FAR
*
szUID
,
SWORD
cbUID
,
SWORD
cbUID
,
UCHAR
FAR
*
szAuthStr
,
UCHAR
FAR
*
szAuthStr
,
SWORD
cbAuthStr
)
SWORD
cbAuthStr
)
{
{
ConnectionClass
*
conn
=
(
ConnectionClass
*
)
hdbc
;
ConnectionClass
*
conn
=
(
ConnectionClass
*
)
hdbc
;
...
@@ -135,11 +135,11 @@ SQLConnect(
...
@@ -135,11 +135,11 @@ SQLConnect(
RETCODE
SQL_API
RETCODE
SQL_API
SQLBrowseConnect
(
SQLBrowseConnect
(
HDBC
hdbc
,
HDBC
hdbc
,
UCHAR
FAR
*
szConnStrIn
,
UCHAR
FAR
*
szConnStrIn
,
SWORD
cbConnStrIn
,
SWORD
cbConnStrIn
,
UCHAR
FAR
*
szConnStrOut
,
UCHAR
FAR
*
szConnStrOut
,
SWORD
cbConnStrOutMax
,
SWORD
cbConnStrOutMax
,
SWORD
FAR
*
pcbConnStrOut
)
SWORD
FAR
*
pcbConnStrOut
)
{
{
static
char
*
func
=
"SQLBrowseConnect"
;
static
char
*
func
=
"SQLBrowseConnect"
;
...
@@ -285,7 +285,7 @@ CC_Constructor()
...
@@ -285,7 +285,7 @@ CC_Constructor()
char
char
CC_Destructor
(
ConnectionClass
*
self
)
CC_Destructor
(
ConnectionClass
*
self
)
{
{
mylog
(
"enter CC_Destructor, self=%u
\n
"
,
self
);
mylog
(
"enter CC_Destructor, self=%u
\n
"
,
self
);
...
@@ -329,7 +329,7 @@ CC_Destructor(ConnectionClass * self)
...
@@ -329,7 +329,7 @@ CC_Destructor(ConnectionClass * self)
/* Return how many cursors are opened on this connection */
/* Return how many cursors are opened on this connection */
int
int
CC_cursor_count
(
ConnectionClass
*
self
)
CC_cursor_count
(
ConnectionClass
*
self
)
{
{
StatementClass
*
stmt
;
StatementClass
*
stmt
;
int
i
,
int
i
,
...
@@ -350,7 +350,7 @@ CC_cursor_count(ConnectionClass * self)
...
@@ -350,7 +350,7 @@ CC_cursor_count(ConnectionClass * self)
}
}
void
void
CC_clear_error
(
ConnectionClass
*
self
)
CC_clear_error
(
ConnectionClass
*
self
)
{
{
self
->
errornumber
=
0
;
self
->
errornumber
=
0
;
self
->
errormsg
=
NULL
;
self
->
errormsg
=
NULL
;
...
@@ -360,7 +360,7 @@ CC_clear_error(ConnectionClass * self)
...
@@ -360,7 +360,7 @@ CC_clear_error(ConnectionClass * self)
/* Used to cancel a transaction */
/* Used to cancel a transaction */
/* We are almost always in the middle of a transaction. */
/* We are almost always in the middle of a transaction. */
char
char
CC_abort
(
ConnectionClass
*
self
)
CC_abort
(
ConnectionClass
*
self
)
{
{
QResultClass
*
res
;
QResultClass
*
res
;
...
@@ -384,7 +384,7 @@ CC_abort(ConnectionClass * self)
...
@@ -384,7 +384,7 @@ CC_abort(ConnectionClass * self)
/* This is called by SQLDisconnect also */
/* This is called by SQLDisconnect also */
char
char
CC_cleanup
(
ConnectionClass
*
self
)
CC_cleanup
(
ConnectionClass
*
self
)
{
{
int
i
;
int
i
;
StatementClass
*
stmt
;
StatementClass
*
stmt
;
...
@@ -437,7 +437,7 @@ CC_cleanup(ConnectionClass * self)
...
@@ -437,7 +437,7 @@ CC_cleanup(ConnectionClass * self)
}
}
int
int
CC_set_translation
(
ConnectionClass
*
self
)
CC_set_translation
(
ConnectionClass
*
self
)
{
{
#ifdef WIN32
#ifdef WIN32
...
@@ -480,7 +480,7 @@ CC_set_translation(ConnectionClass * self)
...
@@ -480,7 +480,7 @@ CC_set_translation(ConnectionClass * self)
}
}
char
char
CC_connect
(
ConnectionClass
*
self
,
char
do_password
)
CC_connect
(
ConnectionClass
*
self
,
char
do_password
)
{
{
StartupPacket
sp
;
StartupPacket
sp
;
QResultClass
*
res
;
QResultClass
*
res
;
...
@@ -733,7 +733,7 @@ CC_connect(ConnectionClass * self, char do_password)
...
@@ -733,7 +733,7 @@ CC_connect(ConnectionClass * self, char do_password)
}
}
char
char
CC_add_statement
(
ConnectionClass
*
self
,
StatementClass
*
stmt
)
CC_add_statement
(
ConnectionClass
*
self
,
StatementClass
*
stmt
)
{
{
int
i
;
int
i
;
...
@@ -765,7 +765,7 @@ CC_add_statement(ConnectionClass * self, StatementClass * stmt)
...
@@ -765,7 +765,7 @@ CC_add_statement(ConnectionClass * self, StatementClass * stmt)
}
}
char
char
CC_remove_statement
(
ConnectionClass
*
self
,
StatementClass
*
stmt
)
CC_remove_statement
(
ConnectionClass
*
self
,
StatementClass
*
stmt
)
{
{
int
i
;
int
i
;
...
@@ -785,7 +785,7 @@ CC_remove_statement(ConnectionClass * self, StatementClass * stmt)
...
@@ -785,7 +785,7 @@ CC_remove_statement(ConnectionClass * self, StatementClass * stmt)
error message with its socket error message.
error message with its socket error message.
*/
*/
char
*
char
*
CC_create_errormsg
(
ConnectionClass
*
self
)
CC_create_errormsg
(
ConnectionClass
*
self
)
{
{
SocketClass
*
sock
=
self
->
sock
;
SocketClass
*
sock
=
self
->
sock
;
int
pos
;
int
pos
;
...
@@ -812,7 +812,7 @@ CC_create_errormsg(ConnectionClass * self)
...
@@ -812,7 +812,7 @@ CC_create_errormsg(ConnectionClass * self)
char
char
CC_get_error
(
ConnectionClass
*
self
,
int
*
number
,
char
**
message
)
CC_get_error
(
ConnectionClass
*
self
,
int
*
number
,
char
**
message
)
{
{
int
rv
;
int
rv
;
...
@@ -849,7 +849,7 @@ CC_get_error(ConnectionClass * self, int *number, char **message)
...
@@ -849,7 +849,7 @@ CC_get_error(ConnectionClass * self, int *number, char **message)
'declare cursor C3326857 for ...' and 'fetch 100 in C3326857' statements.
'declare cursor C3326857 for ...' and 'fetch 100 in C3326857' statements.
*/
*/
QResultClass
*
QResultClass
*
CC_send_query
(
ConnectionClass
*
self
,
char
*
query
,
QueryInfo
*
qi
)
CC_send_query
(
ConnectionClass
*
self
,
char
*
query
,
QueryInfo
*
qi
)
{
{
QResultClass
*
result_in
,
QResultClass
*
result_in
,
*
res
=
NULL
;
*
res
=
NULL
;
...
@@ -1142,7 +1142,7 @@ CC_send_query(ConnectionClass * self, char *query, QueryInfo * qi)
...
@@ -1142,7 +1142,7 @@ CC_send_query(ConnectionClass * self, char *query, QueryInfo * qi)
}
}
int
int
CC_send_function
(
ConnectionClass
*
self
,
int
fnid
,
void
*
result_buf
,
int
*
actual_result_len
,
int
result_is_int
,
LO_ARG
*
args
,
int
nargs
)
CC_send_function
(
ConnectionClass
*
self
,
int
fnid
,
void
*
result_buf
,
int
*
actual_result_len
,
int
result_is_int
,
LO_ARG
*
args
,
int
nargs
)
{
{
char
id
,
char
id
,
c
,
c
,
...
@@ -1289,7 +1289,7 @@ CC_send_function(ConnectionClass * self, int fnid, void *result_buf, int *actual
...
@@ -1289,7 +1289,7 @@ CC_send_function(ConnectionClass * self, int fnid, void *result_buf, int *actual
char
char
CC_send_settings
(
ConnectionClass
*
self
)
CC_send_settings
(
ConnectionClass
*
self
)
{
{
/* char ini_query[MAX_MESSAGE_LEN]; */
/* char ini_query[MAX_MESSAGE_LEN]; */
ConnInfo
*
ci
=
&
(
self
->
connInfo
);
ConnInfo
*
ci
=
&
(
self
->
connInfo
);
...
@@ -1393,7 +1393,7 @@ CC_send_settings(ConnectionClass * self)
...
@@ -1393,7 +1393,7 @@ CC_send_settings(ConnectionClass * self)
will go away and the define 'PG_TYPE_LO' will be updated.
will go away and the define 'PG_TYPE_LO' will be updated.
*/
*/
void
void
CC_lookup_lo
(
ConnectionClass
*
self
)
CC_lookup_lo
(
ConnectionClass
*
self
)
{
{
HSTMT
hstmt
;
HSTMT
hstmt
;
StatementClass
*
stmt
;
StatementClass
*
stmt
;
...
@@ -1442,7 +1442,7 @@ CC_lookup_lo(ConnectionClass * self)
...
@@ -1442,7 +1442,7 @@ CC_lookup_lo(ConnectionClass * self)
h-inoue 01-2-2001
h-inoue 01-2-2001
*/
*/
void
void
CC_initialize_pg_version
(
ConnectionClass
*
self
)
CC_initialize_pg_version
(
ConnectionClass
*
self
)
{
{
strcpy
(
self
->
pg_version
,
self
->
connInfo
.
protocol
);
strcpy
(
self
->
pg_version
,
self
->
connInfo
.
protocol
);
self
->
pg_version_number
=
(
float
)
6
.
4
;
self
->
pg_version_number
=
(
float
)
6
.
4
;
...
@@ -1455,7 +1455,7 @@ CC_initialize_pg_version(ConnectionClass * self)
...
@@ -1455,7 +1455,7 @@ CC_initialize_pg_version(ConnectionClass * self)
DJP - 25-1-2001
DJP - 25-1-2001
*/
*/
void
void
CC_lookup_pg_version
(
ConnectionClass
*
self
)
CC_lookup_pg_version
(
ConnectionClass
*
self
)
{
{
HSTMT
hstmt
;
HSTMT
hstmt
;
StatementClass
*
stmt
;
StatementClass
*
stmt
;
...
@@ -1517,7 +1517,7 @@ CC_lookup_pg_version(ConnectionClass * self)
...
@@ -1517,7 +1517,7 @@ CC_lookup_pg_version(ConnectionClass * self)
}
}
void
void
CC_log_error
(
char
*
func
,
char
*
desc
,
ConnectionClass
*
self
)
CC_log_error
(
char
*
func
,
char
*
desc
,
ConnectionClass
*
self
)
{
{
#ifdef PRN_NULLCHECK
#ifdef PRN_NULLCHECK
#define nullcheck(a) (a ? a : "(NULL)")
#define nullcheck(a) (a ? a : "(NULL)")
...
...
src/interfaces/odbc/connection.h
View file @
26dc5014
...
@@ -199,7 +199,7 @@ struct col_info
...
@@ -199,7 +199,7 @@ struct col_info
#define HINSTANCE void *
#define HINSTANCE void *
#endif
#endif
typedef
BOOL
(
FAR
WINAPI
*
DataSourceToDriverProc
)
(
UDWORD
,
typedef
BOOL
(
FAR
WINAPI
*
DataSourceToDriverProc
)
(
UDWORD
,
SWORD
,
SWORD
,
PTR
,
PTR
,
SDWORD
,
SDWORD
,
...
@@ -210,7 +210,7 @@ typedef BOOL(FAR WINAPI * DataSourceToDriverProc) (UDWORD,
...
@@ -210,7 +210,7 @@ typedef BOOL(FAR WINAPI * DataSourceToDriverProc) (UDWORD,
SWORD
,
SWORD
,
SWORD
FAR
*
);
SWORD
FAR
*
);
typedef
BOOL
(
FAR
WINAPI
*
DriverToDataSourceProc
)
(
UDWORD
,
typedef
BOOL
(
FAR
WINAPI
*
DriverToDataSourceProc
)
(
UDWORD
,
SWORD
,
SWORD
,
PTR
,
PTR
,
SDWORD
,
SDWORD
,
...
@@ -270,24 +270,24 @@ struct ConnectionClass_
...
@@ -270,24 +270,24 @@ struct ConnectionClass_
/* prototypes */
/* prototypes */
ConnectionClass
*
CC_Constructor
(
void
);
ConnectionClass
*
CC_Constructor
(
void
);
char
CC_Destructor
(
ConnectionClass
*
self
);
char
CC_Destructor
(
ConnectionClass
*
self
);
int
CC_cursor_count
(
ConnectionClass
*
self
);
int
CC_cursor_count
(
ConnectionClass
*
self
);
char
CC_cleanup
(
ConnectionClass
*
self
);
char
CC_cleanup
(
ConnectionClass
*
self
);
char
CC_abort
(
ConnectionClass
*
self
);
char
CC_abort
(
ConnectionClass
*
self
);
int
CC_set_translation
(
ConnectionClass
*
self
);
int
CC_set_translation
(
ConnectionClass
*
self
);
char
CC_connect
(
ConnectionClass
*
self
,
char
do_password
);
char
CC_connect
(
ConnectionClass
*
self
,
char
do_password
);
char
CC_add_statement
(
ConnectionClass
*
self
,
StatementClass
*
stmt
);
char
CC_add_statement
(
ConnectionClass
*
self
,
StatementClass
*
stmt
);
char
CC_remove_statement
(
ConnectionClass
*
self
,
StatementClass
*
stmt
);
char
CC_remove_statement
(
ConnectionClass
*
self
,
StatementClass
*
stmt
);
char
CC_get_error
(
ConnectionClass
*
self
,
int
*
number
,
char
**
message
);
char
CC_get_error
(
ConnectionClass
*
self
,
int
*
number
,
char
**
message
);
QResultClass
*
CC_send_query
(
ConnectionClass
*
self
,
char
*
query
,
QueryInfo
*
qi
);
QResultClass
*
CC_send_query
(
ConnectionClass
*
self
,
char
*
query
,
QueryInfo
*
qi
);
void
CC_clear_error
(
ConnectionClass
*
self
);
void
CC_clear_error
(
ConnectionClass
*
self
);
char
*
CC_create_errormsg
(
ConnectionClass
*
self
);
char
*
CC_create_errormsg
(
ConnectionClass
*
self
);
int
CC_send_function
(
ConnectionClass
*
conn
,
int
fnid
,
void
*
result_buf
,
int
*
actual_result_len
,
int
result_is_int
,
LO_ARG
*
argv
,
int
nargs
);
int
CC_send_function
(
ConnectionClass
*
conn
,
int
fnid
,
void
*
result_buf
,
int
*
actual_result_len
,
int
result_is_int
,
LO_ARG
*
argv
,
int
nargs
);
char
CC_send_settings
(
ConnectionClass
*
self
);
char
CC_send_settings
(
ConnectionClass
*
self
);
void
CC_lookup_lo
(
ConnectionClass
*
conn
);
void
CC_lookup_lo
(
ConnectionClass
*
conn
);
void
CC_lookup_pg_version
(
ConnectionClass
*
conn
);
void
CC_lookup_pg_version
(
ConnectionClass
*
conn
);
void
CC_initialize_pg_version
(
ConnectionClass
*
conn
);
void
CC_initialize_pg_version
(
ConnectionClass
*
conn
);
void
CC_log_error
(
char
*
func
,
char
*
desc
,
ConnectionClass
*
self
);
void
CC_log_error
(
char
*
func
,
char
*
desc
,
ConnectionClass
*
self
);
#endif
#endif
src/interfaces/odbc/convert.c
View file @
26dc5014
...
@@ -154,7 +154,7 @@ char *conv_to_octal(unsigned char val);
...
@@ -154,7 +154,7 @@ char *conv_to_octal(unsigned char val);
/* This is called by SQLFetch() */
/* This is called by SQLFetch() */
int
int
copy_and_convert_field_bindinfo
(
StatementClass
*
stmt
,
Int4
field_type
,
void
*
value
,
int
col
)
copy_and_convert_field_bindinfo
(
StatementClass
*
stmt
,
Int4
field_type
,
void
*
value
,
int
col
)
{
{
BindInfoClass
*
bic
=
&
(
stmt
->
bindings
[
col
]);
BindInfoClass
*
bic
=
&
(
stmt
->
bindings
[
col
]);
...
@@ -164,8 +164,8 @@ copy_and_convert_field_bindinfo(StatementClass * stmt, Int4 field_type, void *va
...
@@ -164,8 +164,8 @@ copy_and_convert_field_bindinfo(StatementClass * stmt, Int4 field_type, void *va
/* This is called by SQLGetData() */
/* This is called by SQLGetData() */
int
int
copy_and_convert_field
(
StatementClass
*
stmt
,
Int4
field_type
,
void
*
value
,
Int2
fCType
,
copy_and_convert_field
(
StatementClass
*
stmt
,
Int4
field_type
,
void
*
value
,
Int2
fCType
,
PTR
rgbValue
,
SDWORD
cbValueMax
,
SDWORD
*
pcbValue
)
PTR
rgbValue
,
SDWORD
cbValueMax
,
SDWORD
*
pcbValue
)
{
{
Int4
len
=
0
,
Int4
len
=
0
,
copy_len
=
0
;
copy_len
=
0
;
...
@@ -672,7 +672,7 @@ copy_and_convert_field(StatementClass * stmt, Int4 field_type, void *value, Int2
...
@@ -672,7 +672,7 @@ copy_and_convert_field(StatementClass * stmt, Int4 field_type, void *value, Int2
This function no longer does any dynamic memory allocation!
This function no longer does any dynamic memory allocation!
*/
*/
int
int
copy_statement_with_parameters
(
StatementClass
*
stmt
)
copy_statement_with_parameters
(
StatementClass
*
stmt
)
{
{
static
char
*
func
=
"copy_statement_with_parameters"
;
static
char
*
func
=
"copy_statement_with_parameters"
;
unsigned
int
opos
,
unsigned
int
opos
,
...
@@ -1308,7 +1308,7 @@ convert_money(char *s)
...
@@ -1308,7 +1308,7 @@ convert_money(char *s)
/* This function parses a character string for date/time info and fills in SIMPLE_TIME */
/* This function parses a character string for date/time info and fills in SIMPLE_TIME */
/* It does not zero out SIMPLE_TIME in case it is desired to initialize it with a value */
/* It does not zero out SIMPLE_TIME in case it is desired to initialize it with a value */
char
char
parse_datetime
(
char
*
buf
,
SIMPLE_TIME
*
st
)
parse_datetime
(
char
*
buf
,
SIMPLE_TIME
*
st
)
{
{
int
y
,
int
y
,
m
,
m
,
...
@@ -1610,8 +1610,8 @@ decode(char *in, char *out)
...
@@ -1610,8 +1610,8 @@ decode(char *in, char *out)
mapped to PG_TYPE_LO someday, instead of PG_TYPE_TEXT as it is now.
mapped to PG_TYPE_LO someday, instead of PG_TYPE_TEXT as it is now.
*/
*/
int
int
convert_lo
(
StatementClass
*
stmt
,
void
*
value
,
Int2
fCType
,
PTR
rgbValue
,
convert_lo
(
StatementClass
*
stmt
,
void
*
value
,
Int2
fCType
,
PTR
rgbValue
,
SDWORD
cbValueMax
,
SDWORD
*
pcbValue
)
SDWORD
cbValueMax
,
SDWORD
*
pcbValue
)
{
{
Oid
oid
;
Oid
oid
;
int
retval
,
int
retval
,
...
...
src/interfaces/odbc/convert.h
View file @
26dc5014
...
@@ -30,14 +30,14 @@ typedef struct
...
@@ -30,14 +30,14 @@ typedef struct
int
ss
;
int
ss
;
}
SIMPLE_TIME
;
}
SIMPLE_TIME
;
int
copy_and_convert_field_bindinfo
(
StatementClass
*
stmt
,
Int4
field_type
,
void
*
value
,
int
col
);
int
copy_and_convert_field_bindinfo
(
StatementClass
*
stmt
,
Int4
field_type
,
void
*
value
,
int
col
);
int
copy_and_convert_field
(
StatementClass
*
stmt
,
Int4
field_type
,
void
*
value
,
Int2
fCType
,
int
copy_and_convert_field
(
StatementClass
*
stmt
,
Int4
field_type
,
void
*
value
,
Int2
fCType
,
PTR
rgbValue
,
SDWORD
cbValueMax
,
SDWORD
*
pcbValue
);
PTR
rgbValue
,
SDWORD
cbValueMax
,
SDWORD
*
pcbValue
);
int
copy_statement_with_parameters
(
StatementClass
*
stmt
);
int
copy_statement_with_parameters
(
StatementClass
*
stmt
);
char
*
convert_escape
(
char
*
value
);
char
*
convert_escape
(
char
*
value
);
char
*
convert_money
(
char
*
s
);
char
*
convert_money
(
char
*
s
);
char
parse_datetime
(
char
*
buf
,
SIMPLE_TIME
*
st
);
char
parse_datetime
(
char
*
buf
,
SIMPLE_TIME
*
st
);
int
convert_linefeeds
(
char
*
s
,
char
*
dst
,
size_t
max
);
int
convert_linefeeds
(
char
*
s
,
char
*
dst
,
size_t
max
);
char
*
convert_special_chars
(
char
*
si
,
char
*
dst
,
int
used
);
char
*
convert_special_chars
(
char
*
si
,
char
*
dst
,
int
used
);
...
@@ -46,7 +46,7 @@ int convert_from_pgbinary(unsigned char *value, unsigned char *rgbValue, int c
...
@@ -46,7 +46,7 @@ int convert_from_pgbinary(unsigned char *value, unsigned char *rgbValue, int c
int
convert_to_pgbinary
(
unsigned
char
*
in
,
char
*
out
,
int
len
);
int
convert_to_pgbinary
(
unsigned
char
*
in
,
char
*
out
,
int
len
);
void
encode
(
char
*
in
,
char
*
out
);
void
encode
(
char
*
in
,
char
*
out
);
void
decode
(
char
*
in
,
char
*
out
);
void
decode
(
char
*
in
,
char
*
out
);
int
convert_lo
(
StatementClass
*
stmt
,
void
*
value
,
Int2
fCType
,
PTR
rgbValue
,
int
convert_lo
(
StatementClass
*
stmt
,
void
*
value
,
Int2
fCType
,
PTR
rgbValue
,
SDWORD
cbValueMax
,
SDWORD
*
pcbValue
);
SDWORD
cbValueMax
,
SDWORD
*
pcbValue
);
#endif
#endif
src/interfaces/odbc/dlg_specific.c
View file @
26dc5014
...
@@ -47,7 +47,7 @@ extern GLOBAL_VALUES globals;
...
@@ -47,7 +47,7 @@ extern GLOBAL_VALUES globals;
#ifdef WIN32
#ifdef WIN32
void
void
SetDlgStuff
(
HWND
hdlg
,
ConnInfo
*
ci
)
SetDlgStuff
(
HWND
hdlg
,
ConnInfo
*
ci
)
{
{
/*
/*
...
@@ -68,7 +68,7 @@ SetDlgStuff(HWND hdlg, ConnInfo * ci)
...
@@ -68,7 +68,7 @@ SetDlgStuff(HWND hdlg, ConnInfo * ci)
}
}
void
void
GetDlgStuff
(
HWND
hdlg
,
ConnInfo
*
ci
)
GetDlgStuff
(
HWND
hdlg
,
ConnInfo
*
ci
)
{
{
GetDlgItemText
(
hdlg
,
IDC_DESC
,
ci
->
desc
,
sizeof
(
ci
->
desc
));
GetDlgItemText
(
hdlg
,
IDC_DESC
,
ci
->
desc
,
sizeof
(
ci
->
desc
));
...
@@ -318,7 +318,7 @@ ds_optionsProc(HWND hdlg,
...
@@ -318,7 +318,7 @@ ds_optionsProc(HWND hdlg,
#endif
/* WIN32 */
#endif
/* WIN32 */
void
void
makeConnectString
(
char
*
connect_string
,
ConnInfo
*
ci
)
makeConnectString
(
char
*
connect_string
,
ConnInfo
*
ci
)
{
{
char
got_dsn
=
(
ci
->
dsn
[
0
]
!=
'\0'
);
char
got_dsn
=
(
ci
->
dsn
[
0
]
!=
'\0'
);
char
encoded_conn_settings
[
LARGE_REGISTRY_LEN
];
char
encoded_conn_settings
[
LARGE_REGISTRY_LEN
];
...
@@ -348,7 +348,7 @@ makeConnectString(char *connect_string, ConnInfo * ci)
...
@@ -348,7 +348,7 @@ makeConnectString(char *connect_string, ConnInfo * ci)
}
}
void
void
copyAttributes
(
ConnInfo
*
ci
,
char
*
attribute
,
char
*
value
)
copyAttributes
(
ConnInfo
*
ci
,
char
*
attribute
,
char
*
value
)
{
{
if
(
stricmp
(
attribute
,
"DSN"
)
==
0
)
if
(
stricmp
(
attribute
,
"DSN"
)
==
0
)
strcpy
(
ci
->
dsn
,
value
);
strcpy
(
ci
->
dsn
,
value
);
...
@@ -399,7 +399,7 @@ copyAttributes(ConnInfo * ci, char *attribute, char *value)
...
@@ -399,7 +399,7 @@ copyAttributes(ConnInfo * ci, char *attribute, char *value)
}
}
void
void
getDSNdefaults
(
ConnInfo
*
ci
)
getDSNdefaults
(
ConnInfo
*
ci
)
{
{
if
(
ci
->
port
[
0
]
==
'\0'
)
if
(
ci
->
port
[
0
]
==
'\0'
)
strcpy
(
ci
->
port
,
DEFAULT_PORT
);
strcpy
(
ci
->
port
,
DEFAULT_PORT
);
...
@@ -425,7 +425,7 @@ getDSNdefaults(ConnInfo * ci)
...
@@ -425,7 +425,7 @@ getDSNdefaults(ConnInfo * ci)
void
void
getDSNinfo
(
ConnInfo
*
ci
,
char
overwrite
)
getDSNinfo
(
ConnInfo
*
ci
,
char
overwrite
)
{
{
char
*
DSN
=
ci
->
dsn
;
char
*
DSN
=
ci
->
dsn
;
char
encoded_conn_settings
[
LARGE_REGISTRY_LEN
];
char
encoded_conn_settings
[
LARGE_REGISTRY_LEN
];
...
@@ -522,7 +522,7 @@ getDSNinfo(ConnInfo * ci, char overwrite)
...
@@ -522,7 +522,7 @@ getDSNinfo(ConnInfo * ci, char overwrite)
/* This is for datasource based options only */
/* This is for datasource based options only */
void
void
writeDSNinfo
(
ConnInfo
*
ci
)
writeDSNinfo
(
ConnInfo
*
ci
)
{
{
char
*
DSN
=
ci
->
dsn
;
char
*
DSN
=
ci
->
dsn
;
char
encoded_conn_settings
[
LARGE_REGISTRY_LEN
];
char
encoded_conn_settings
[
LARGE_REGISTRY_LEN
];
...
...
src/interfaces/odbc/dlg_specific.h
View file @
26dc5014
...
@@ -127,8 +127,8 @@
...
@@ -127,8 +127,8 @@
void
getGlobalDefaults
(
char
*
section
,
char
*
filename
,
char
override
);
void
getGlobalDefaults
(
char
*
section
,
char
*
filename
,
char
override
);
#ifdef WIN32
#ifdef WIN32
void
SetDlgStuff
(
HWND
hdlg
,
ConnInfo
*
ci
);
void
SetDlgStuff
(
HWND
hdlg
,
ConnInfo
*
ci
);
void
GetDlgStuff
(
HWND
hdlg
,
ConnInfo
*
ci
);
void
GetDlgStuff
(
HWND
hdlg
,
ConnInfo
*
ci
);
int
CALLBACK
driver_optionsProc
(
HWND
hdlg
,
int
CALLBACK
driver_optionsProc
(
HWND
hdlg
,
WORD
wMsg
,
WORD
wMsg
,
...
@@ -142,11 +142,11 @@ int CALLBACK ds_optionsProc(HWND hdlg,
...
@@ -142,11 +142,11 @@ int CALLBACK ds_optionsProc(HWND hdlg,
#endif
/* WIN32 */
#endif
/* WIN32 */
void
updateGlobals
(
void
);
void
updateGlobals
(
void
);
void
writeDSNinfo
(
ConnInfo
*
ci
);
void
writeDSNinfo
(
ConnInfo
*
ci
);
void
getDSNdefaults
(
ConnInfo
*
ci
);
void
getDSNdefaults
(
ConnInfo
*
ci
);
void
getDSNinfo
(
ConnInfo
*
ci
,
char
overwrite
);
void
getDSNinfo
(
ConnInfo
*
ci
,
char
overwrite
);
void
makeConnectString
(
char
*
connect_string
,
ConnInfo
*
ci
);
void
makeConnectString
(
char
*
connect_string
,
ConnInfo
*
ci
);
void
copyAttributes
(
ConnInfo
*
ci
,
char
*
attribute
,
char
*
value
);
void
copyAttributes
(
ConnInfo
*
ci
,
char
*
attribute
,
char
*
value
);
#endif
#endif
src/interfaces/odbc/drvconn.c
View file @
26dc5014
...
@@ -52,11 +52,11 @@
...
@@ -52,11 +52,11 @@
#include "dlg_specific.h"
#include "dlg_specific.h"
/* prototypes */
/* prototypes */
void
dconn_get_connect_attributes
(
UCHAR
FAR
*
connect_string
,
ConnInfo
*
ci
);
void
dconn_get_connect_attributes
(
UCHAR
FAR
*
connect_string
,
ConnInfo
*
ci
);
#ifdef WIN32
#ifdef WIN32
BOOL
FAR
PASCAL
dconn_FDriverConnectProc
(
HWND
hdlg
,
UINT
wMsg
,
WPARAM
wParam
,
LPARAM
lParam
);
BOOL
FAR
PASCAL
dconn_FDriverConnectProc
(
HWND
hdlg
,
UINT
wMsg
,
WPARAM
wParam
,
LPARAM
lParam
);
RETCODE
dconn_DoDialog
(
HWND
hwnd
,
ConnInfo
*
ci
);
RETCODE
dconn_DoDialog
(
HWND
hwnd
,
ConnInfo
*
ci
);
extern
HINSTANCE
NEAR
s_hModule
;
/* Saved module handle. */
extern
HINSTANCE
NEAR
s_hModule
;
/* Saved module handle. */
...
@@ -69,11 +69,11 @@ RETCODE SQL_API
...
@@ -69,11 +69,11 @@ RETCODE SQL_API
SQLDriverConnect
(
SQLDriverConnect
(
HDBC
hdbc
,
HDBC
hdbc
,
HWND
hwnd
,
HWND
hwnd
,
UCHAR
FAR
*
szConnStrIn
,
UCHAR
FAR
*
szConnStrIn
,
SWORD
cbConnStrIn
,
SWORD
cbConnStrIn
,
UCHAR
FAR
*
szConnStrOut
,
UCHAR
FAR
*
szConnStrOut
,
SWORD
cbConnStrOutMax
,
SWORD
cbConnStrOutMax
,
SWORD
FAR
*
pcbConnStrOut
,
SWORD
FAR
*
pcbConnStrOut
,
UWORD
fDriverCompletion
)
UWORD
fDriverCompletion
)
{
{
static
char
*
func
=
"SQLDriverConnect"
;
static
char
*
func
=
"SQLDriverConnect"
;
...
@@ -248,7 +248,7 @@ dialog:
...
@@ -248,7 +248,7 @@ dialog:
#ifdef WIN32
#ifdef WIN32
RETCODE
RETCODE
dconn_DoDialog
(
HWND
hwnd
,
ConnInfo
*
ci
)
dconn_DoDialog
(
HWND
hwnd
,
ConnInfo
*
ci
)
{
{
int
dialog_result
;
int
dialog_result
;
...
@@ -350,7 +350,7 @@ dconn_FDriverConnectProc(
...
@@ -350,7 +350,7 @@ dconn_FDriverConnectProc(
#endif
/* WIN32 */
#endif
/* WIN32 */
void
void
dconn_get_connect_attributes
(
UCHAR
FAR
*
connect_string
,
ConnInfo
*
ci
)
dconn_get_connect_attributes
(
UCHAR
FAR
*
connect_string
,
ConnInfo
*
ci
)
{
{
char
*
our_connect_string
;
char
*
our_connect_string
;
char
*
pair
,
char
*
pair
,
...
...
src/interfaces/odbc/environ.c
View file @
26dc5014
...
@@ -23,7 +23,7 @@ ConnectionClass *conns[MAX_CONNECTIONS];
...
@@ -23,7 +23,7 @@ ConnectionClass *conns[MAX_CONNECTIONS];
RETCODE
SQL_API
RETCODE
SQL_API
SQLAllocEnv
(
HENV
FAR
*
phenv
)
SQLAllocEnv
(
HENV
FAR
*
phenv
)
{
{
static
char
*
func
=
"SQLAllocEnv"
;
static
char
*
func
=
"SQLAllocEnv"
;
...
@@ -67,11 +67,11 @@ SQLError(
...
@@ -67,11 +67,11 @@ SQLError(
HENV
henv
,
HENV
henv
,
HDBC
hdbc
,
HDBC
hdbc
,
HSTMT
hstmt
,
HSTMT
hstmt
,
UCHAR
FAR
*
szSqlState
,
UCHAR
FAR
*
szSqlState
,
SDWORD
FAR
*
pfNativeError
,
SDWORD
FAR
*
pfNativeError
,
UCHAR
FAR
*
szErrorMsg
,
UCHAR
FAR
*
szErrorMsg
,
SWORD
cbErrorMsgMax
,
SWORD
cbErrorMsgMax
,
SWORD
FAR
*
pcbErrorMsg
)
SWORD
FAR
*
pcbErrorMsg
)
{
{
char
*
msg
;
char
*
msg
;
int
status
;
int
status
;
...
@@ -410,7 +410,8 @@ SQLError(
...
@@ -410,7 +410,8 @@ SQLError(
EnvironmentClass
EnvironmentClass
*
EN_Constructor
(
void
)
*
EN_Constructor
(
void
)
{
{
EnvironmentClass
*
rv
;
EnvironmentClass
*
rv
;
...
@@ -426,7 +427,7 @@ EnvironmentClass
...
@@ -426,7 +427,7 @@ EnvironmentClass
char
char
EN_Destructor
(
EnvironmentClass
*
self
)
EN_Destructor
(
EnvironmentClass
*
self
)
{
{
int
lf
;
int
lf
;
char
rv
=
1
;
char
rv
=
1
;
...
@@ -448,7 +449,7 @@ EN_Destructor(EnvironmentClass * self)
...
@@ -448,7 +449,7 @@ EN_Destructor(EnvironmentClass * self)
}
}
char
char
EN_get_error
(
EnvironmentClass
*
self
,
int
*
number
,
char
**
message
)
EN_get_error
(
EnvironmentClass
*
self
,
int
*
number
,
char
**
message
)
{
{
if
(
self
&&
self
->
errormsg
&&
self
->
errornumber
)
if
(
self
&&
self
->
errormsg
&&
self
->
errornumber
)
{
{
...
@@ -463,7 +464,7 @@ EN_get_error(EnvironmentClass * self, int *number, char **message)
...
@@ -463,7 +464,7 @@ EN_get_error(EnvironmentClass * self, int *number, char **message)
}
}
char
char
EN_add_connection
(
EnvironmentClass
*
self
,
ConnectionClass
*
conn
)
EN_add_connection
(
EnvironmentClass
*
self
,
ConnectionClass
*
conn
)
{
{
int
i
;
int
i
;
...
@@ -486,7 +487,7 @@ EN_add_connection(EnvironmentClass * self, ConnectionClass * conn)
...
@@ -486,7 +487,7 @@ EN_add_connection(EnvironmentClass * self, ConnectionClass * conn)
}
}
char
char
EN_remove_connection
(
EnvironmentClass
*
self
,
ConnectionClass
*
conn
)
EN_remove_connection
(
EnvironmentClass
*
self
,
ConnectionClass
*
conn
)
{
{
int
i
;
int
i
;
...
@@ -501,7 +502,7 @@ EN_remove_connection(EnvironmentClass * self, ConnectionClass * conn)
...
@@ -501,7 +502,7 @@ EN_remove_connection(EnvironmentClass * self, ConnectionClass * conn)
}
}
void
void
EN_log_error
(
char
*
func
,
char
*
desc
,
EnvironmentClass
*
self
)
EN_log_error
(
char
*
func
,
char
*
desc
,
EnvironmentClass
*
self
)
{
{
if
(
self
)
if
(
self
)
qlog
(
"ENVIRON ERROR: func=%s, desc='%s', errnum=%d, errmsg='%s'
\n
"
,
func
,
desc
,
self
->
errornumber
,
self
->
errormsg
);
qlog
(
"ENVIRON ERROR: func=%s, desc='%s', errnum=%d, errmsg='%s'
\n
"
,
func
,
desc
,
self
->
errornumber
,
self
->
errormsg
);
...
...
src/interfaces/odbc/environ.h
View file @
26dc5014
...
@@ -37,10 +37,10 @@ struct EnvironmentClass_
...
@@ -37,10 +37,10 @@ struct EnvironmentClass_
/* Environment prototypes */
/* Environment prototypes */
EnvironmentClass
*
EN_Constructor
(
void
);
EnvironmentClass
*
EN_Constructor
(
void
);
char
EN_Destructor
(
EnvironmentClass
*
self
);
char
EN_Destructor
(
EnvironmentClass
*
self
);
char
EN_get_error
(
EnvironmentClass
*
self
,
int
*
number
,
char
**
message
);
char
EN_get_error
(
EnvironmentClass
*
self
,
int
*
number
,
char
**
message
);
char
EN_add_connection
(
EnvironmentClass
*
self
,
ConnectionClass
*
conn
);
char
EN_add_connection
(
EnvironmentClass
*
self
,
ConnectionClass
*
conn
);
char
EN_remove_connection
(
EnvironmentClass
*
self
,
ConnectionClass
*
conn
);
char
EN_remove_connection
(
EnvironmentClass
*
self
,
ConnectionClass
*
conn
);
void
EN_log_error
(
char
*
func
,
char
*
desc
,
EnvironmentClass
*
self
);
void
EN_log_error
(
char
*
func
,
char
*
desc
,
EnvironmentClass
*
self
);
#endif
#endif
src/interfaces/odbc/execute.c
View file @
26dc5014
...
@@ -41,7 +41,7 @@ extern GLOBAL_VALUES globals;
...
@@ -41,7 +41,7 @@ extern GLOBAL_VALUES globals;
/* Perform a Prepare on the SQL statement */
/* Perform a Prepare on the SQL statement */
RETCODE
SQL_API
RETCODE
SQL_API
SQLPrepare
(
HSTMT
hstmt
,
SQLPrepare
(
HSTMT
hstmt
,
UCHAR
FAR
*
szSqlStr
,
UCHAR
FAR
*
szSqlStr
,
SDWORD
cbSqlStr
)
SDWORD
cbSqlStr
)
{
{
static
char
*
func
=
"SQLPrepare"
;
static
char
*
func
=
"SQLPrepare"
;
...
@@ -136,7 +136,7 @@ SQLPrepare(HSTMT hstmt,
...
@@ -136,7 +136,7 @@ SQLPrepare(HSTMT hstmt,
RETCODE
SQL_API
RETCODE
SQL_API
SQLExecDirect
(
SQLExecDirect
(
HSTMT
hstmt
,
HSTMT
hstmt
,
UCHAR
FAR
*
szSqlStr
,
UCHAR
FAR
*
szSqlStr
,
SDWORD
cbSqlStr
)
SDWORD
cbSqlStr
)
{
{
StatementClass
*
stmt
=
(
StatementClass
*
)
hstmt
;
StatementClass
*
stmt
=
(
StatementClass
*
)
hstmt
;
...
@@ -489,11 +489,11 @@ SQLCancel(
...
@@ -489,11 +489,11 @@ SQLCancel(
RETCODE
SQL_API
RETCODE
SQL_API
SQLNativeSql
(
SQLNativeSql
(
HDBC
hdbc
,
HDBC
hdbc
,
UCHAR
FAR
*
szSqlStrIn
,
UCHAR
FAR
*
szSqlStrIn
,
SDWORD
cbSqlStrIn
,
SDWORD
cbSqlStrIn
,
UCHAR
FAR
*
szSqlStr
,
UCHAR
FAR
*
szSqlStr
,
SDWORD
cbSqlStrMax
,
SDWORD
cbSqlStrMax
,
SDWORD
FAR
*
pcbSqlStr
)
SDWORD
FAR
*
pcbSqlStr
)
{
{
static
char
*
func
=
"SQLNativeSql"
;
static
char
*
func
=
"SQLNativeSql"
;
int
len
=
0
;
int
len
=
0
;
...
@@ -543,7 +543,7 @@ SQLNativeSql(
...
@@ -543,7 +543,7 @@ SQLNativeSql(
RETCODE
SQL_API
RETCODE
SQL_API
SQLParamData
(
SQLParamData
(
HSTMT
hstmt
,
HSTMT
hstmt
,
PTR
FAR
*
prgbValue
)
PTR
FAR
*
prgbValue
)
{
{
static
char
*
func
=
"SQLParamData"
;
static
char
*
func
=
"SQLParamData"
;
StatementClass
*
stmt
=
(
StatementClass
*
)
hstmt
;
StatementClass
*
stmt
=
(
StatementClass
*
)
hstmt
;
...
...
src/interfaces/odbc/gpps.h
View file @
26dc5014
src/interfaces/odbc/info.c
View file @
26dc5014
...
@@ -64,7 +64,7 @@ SQLGetInfo(
...
@@ -64,7 +64,7 @@ SQLGetInfo(
UWORD
fInfoType
,
UWORD
fInfoType
,
PTR
rgbInfoValue
,
PTR
rgbInfoValue
,
SWORD
cbInfoValueMax
,
SWORD
cbInfoValueMax
,
SWORD
FAR
*
pcbInfoValue
)
SWORD
FAR
*
pcbInfoValue
)
{
{
static
char
*
func
=
"SQLGetInfo"
;
static
char
*
func
=
"SQLGetInfo"
;
ConnectionClass
*
conn
=
(
ConnectionClass
*
)
hdbc
;
ConnectionClass
*
conn
=
(
ConnectionClass
*
)
hdbc
;
...
@@ -769,7 +769,7 @@ SQLGetTypeInfo(
...
@@ -769,7 +769,7 @@ SQLGetTypeInfo(
if
(
fSqlType
==
SQL_ALL_TYPES
||
fSqlType
==
sqlType
)
if
(
fSqlType
==
SQL_ALL_TYPES
||
fSqlType
==
sqlType
)
{
{
row
=
(
TupleNode
*
)
malloc
(
sizeof
(
TupleNode
)
+
(
15
-
1
)
*
sizeof
(
TupleField
));
row
=
(
TupleNode
*
)
malloc
(
sizeof
(
TupleNode
)
+
(
15
-
1
)
*
sizeof
(
TupleField
));
/* These values can't be NULL */
/* These values can't be NULL */
set_tuplefield_string
(
&
row
->
tuple
[
0
],
pgtype_to_name
(
stmt
,
pgType
));
set_tuplefield_string
(
&
row
->
tuple
[
0
],
pgtype_to_name
(
stmt
,
pgType
));
...
@@ -814,7 +814,7 @@ RETCODE SQL_API
...
@@ -814,7 +814,7 @@ RETCODE SQL_API
SQLGetFunctions
(
SQLGetFunctions
(
HDBC
hdbc
,
HDBC
hdbc
,
UWORD
fFunction
,
UWORD
fFunction
,
UWORD
FAR
*
pfExists
)
UWORD
FAR
*
pfExists
)
{
{
static
char
*
func
=
"SQLGetFunctions"
;
static
char
*
func
=
"SQLGetFunctions"
;
...
@@ -1097,13 +1097,13 @@ SQLGetFunctions(
...
@@ -1097,13 +1097,13 @@ SQLGetFunctions(
RETCODE
SQL_API
RETCODE
SQL_API
SQLTables
(
SQLTables
(
HSTMT
hstmt
,
HSTMT
hstmt
,
UCHAR
FAR
*
szTableQualifier
,
UCHAR
FAR
*
szTableQualifier
,
SWORD
cbTableQualifier
,
SWORD
cbTableQualifier
,
UCHAR
FAR
*
szTableOwner
,
UCHAR
FAR
*
szTableOwner
,
SWORD
cbTableOwner
,
SWORD
cbTableOwner
,
UCHAR
FAR
*
szTableName
,
UCHAR
FAR
*
szTableName
,
SWORD
cbTableName
,
SWORD
cbTableName
,
UCHAR
FAR
*
szTableType
,
UCHAR
FAR
*
szTableType
,
SWORD
cbTableType
)
SWORD
cbTableType
)
{
{
static
char
*
func
=
"SQLTables"
;
static
char
*
func
=
"SQLTables"
;
...
@@ -1372,7 +1372,7 @@ SQLTables(
...
@@ -1372,7 +1372,7 @@ SQLTables(
(
view
&&
show_views
)
||
(
view
&&
show_views
)
||
(
regular_table
&&
show_regular_tables
))
(
regular_table
&&
show_regular_tables
))
{
{
row
=
(
TupleNode
*
)
malloc
(
sizeof
(
TupleNode
)
+
(
5
-
1
)
*
sizeof
(
TupleField
));
row
=
(
TupleNode
*
)
malloc
(
sizeof
(
TupleNode
)
+
(
5
-
1
)
*
sizeof
(
TupleField
));
set_tuplefield_string
(
&
row
->
tuple
[
0
],
""
);
set_tuplefield_string
(
&
row
->
tuple
[
0
],
""
);
...
@@ -1422,13 +1422,13 @@ SQLTables(
...
@@ -1422,13 +1422,13 @@ SQLTables(
RETCODE
SQL_API
RETCODE
SQL_API
SQLColumns
(
SQLColumns
(
HSTMT
hstmt
,
HSTMT
hstmt
,
UCHAR
FAR
*
szTableQualifier
,
UCHAR
FAR
*
szTableQualifier
,
SWORD
cbTableQualifier
,
SWORD
cbTableQualifier
,
UCHAR
FAR
*
szTableOwner
,
UCHAR
FAR
*
szTableOwner
,
SWORD
cbTableOwner
,
SWORD
cbTableOwner
,
UCHAR
FAR
*
szTableName
,
UCHAR
FAR
*
szTableName
,
SWORD
cbTableName
,
SWORD
cbTableName
,
UCHAR
FAR
*
szColumnName
,
UCHAR
FAR
*
szColumnName
,
SWORD
cbColumnName
)
SWORD
cbColumnName
)
{
{
static
char
*
func
=
"SQLColumns"
;
static
char
*
func
=
"SQLColumns"
;
...
@@ -1684,7 +1684,7 @@ SQLColumns(
...
@@ -1684,7 +1684,7 @@ SQLColumns(
/* For OID fields */
/* For OID fields */
the_type
=
PG_TYPE_OID
;
the_type
=
PG_TYPE_OID
;
row
=
(
TupleNode
*
)
malloc
(
sizeof
(
TupleNode
)
+
row
=
(
TupleNode
*
)
malloc
(
sizeof
(
TupleNode
)
+
(
result_cols
-
1
)
*
sizeof
(
TupleField
));
(
result_cols
-
1
)
*
sizeof
(
TupleField
));
set_tuplefield_string
(
&
row
->
tuple
[
0
],
""
);
set_tuplefield_string
(
&
row
->
tuple
[
0
],
""
);
/* see note in SQLTables() */
/* see note in SQLTables() */
...
@@ -1713,7 +1713,7 @@ SQLColumns(
...
@@ -1713,7 +1713,7 @@ SQLColumns(
while
((
result
==
SQL_SUCCESS
)
||
(
result
==
SQL_SUCCESS_WITH_INFO
))
while
((
result
==
SQL_SUCCESS
)
||
(
result
==
SQL_SUCCESS_WITH_INFO
))
{
{
row
=
(
TupleNode
*
)
malloc
(
sizeof
(
TupleNode
)
+
row
=
(
TupleNode
*
)
malloc
(
sizeof
(
TupleNode
)
+
(
result_cols
-
1
)
*
sizeof
(
TupleField
));
(
result_cols
-
1
)
*
sizeof
(
TupleField
));
set_tuplefield_string
(
&
row
->
tuple
[
0
],
""
);
set_tuplefield_string
(
&
row
->
tuple
[
0
],
""
);
...
@@ -1821,7 +1821,7 @@ SQLColumns(
...
@@ -1821,7 +1821,7 @@ SQLColumns(
the_type
=
PG_TYPE_INT4
;
the_type
=
PG_TYPE_INT4
;
row
=
(
TupleNode
*
)
malloc
(
sizeof
(
TupleNode
)
+
row
=
(
TupleNode
*
)
malloc
(
sizeof
(
TupleNode
)
+
(
result_cols
-
1
)
*
sizeof
(
TupleField
));
(
result_cols
-
1
)
*
sizeof
(
TupleField
));
set_tuplefield_string
(
&
row
->
tuple
[
0
],
""
);
set_tuplefield_string
(
&
row
->
tuple
[
0
],
""
);
set_tuplefield_string
(
&
row
->
tuple
[
1
],
""
);
set_tuplefield_string
(
&
row
->
tuple
[
1
],
""
);
...
@@ -1859,11 +1859,11 @@ RETCODE SQL_API
...
@@ -1859,11 +1859,11 @@ RETCODE SQL_API
SQLSpecialColumns
(
SQLSpecialColumns
(
HSTMT
hstmt
,
HSTMT
hstmt
,
UWORD
fColType
,
UWORD
fColType
,
UCHAR
FAR
*
szTableQualifier
,
UCHAR
FAR
*
szTableQualifier
,
SWORD
cbTableQualifier
,
SWORD
cbTableQualifier
,
UCHAR
FAR
*
szTableOwner
,
UCHAR
FAR
*
szTableOwner
,
SWORD
cbTableOwner
,
SWORD
cbTableOwner
,
UCHAR
FAR
*
szTableName
,
UCHAR
FAR
*
szTableName
,
SWORD
cbTableName
,
SWORD
cbTableName
,
UWORD
fScope
,
UWORD
fScope
,
UWORD
fNullable
)
UWORD
fNullable
)
...
@@ -1958,7 +1958,7 @@ SQLSpecialColumns(
...
@@ -1958,7 +1958,7 @@ SQLSpecialColumns(
/* use the oid value for the rowid */
/* use the oid value for the rowid */
if
(
fColType
==
SQL_BEST_ROWID
)
if
(
fColType
==
SQL_BEST_ROWID
)
{
{
row
=
(
TupleNode
*
)
malloc
(
sizeof
(
TupleNode
)
+
(
8
-
1
)
*
sizeof
(
TupleField
));
row
=
(
TupleNode
*
)
malloc
(
sizeof
(
TupleNode
)
+
(
8
-
1
)
*
sizeof
(
TupleField
));
set_tuplefield_int2
(
&
row
->
tuple
[
0
],
SQL_SCOPE_SESSION
);
set_tuplefield_int2
(
&
row
->
tuple
[
0
],
SQL_SCOPE_SESSION
);
set_tuplefield_string
(
&
row
->
tuple
[
1
],
"oid"
);
set_tuplefield_string
(
&
row
->
tuple
[
1
],
"oid"
);
...
@@ -1977,7 +1977,7 @@ SQLSpecialColumns(
...
@@ -1977,7 +1977,7 @@ SQLSpecialColumns(
if
(
atoi
(
ci
->
row_versioning
))
if
(
atoi
(
ci
->
row_versioning
))
{
{
row
=
(
TupleNode
*
)
malloc
(
sizeof
(
TupleNode
)
+
(
8
-
1
)
*
sizeof
(
TupleField
));
row
=
(
TupleNode
*
)
malloc
(
sizeof
(
TupleNode
)
+
(
8
-
1
)
*
sizeof
(
TupleField
));
set_tuplefield_null
(
&
row
->
tuple
[
0
]);
set_tuplefield_null
(
&
row
->
tuple
[
0
]);
set_tuplefield_string
(
&
row
->
tuple
[
1
],
"xmin"
);
set_tuplefield_string
(
&
row
->
tuple
[
1
],
"xmin"
);
...
@@ -2007,11 +2007,11 @@ SQLSpecialColumns(
...
@@ -2007,11 +2007,11 @@ SQLSpecialColumns(
RETCODE
SQL_API
RETCODE
SQL_API
SQLStatistics
(
SQLStatistics
(
HSTMT
hstmt
,
HSTMT
hstmt
,
UCHAR
FAR
*
szTableQualifier
,
UCHAR
FAR
*
szTableQualifier
,
SWORD
cbTableQualifier
,
SWORD
cbTableQualifier
,
UCHAR
FAR
*
szTableOwner
,
UCHAR
FAR
*
szTableOwner
,
SWORD
cbTableOwner
,
SWORD
cbTableOwner
,
UCHAR
FAR
*
szTableName
,
UCHAR
FAR
*
szTableName
,
SWORD
cbTableName
,
SWORD
cbTableName
,
UWORD
fUnique
,
UWORD
fUnique
,
UWORD
fAccuracy
)
UWORD
fAccuracy
)
...
@@ -2255,7 +2255,7 @@ SQLStatistics(
...
@@ -2255,7 +2255,7 @@ SQLStatistics(
if
(
relhasrules
[
0
]
!=
'1'
&&
atoi
(
ci
->
show_oid_column
)
&&
atoi
(
ci
->
fake_oid_index
))
if
(
relhasrules
[
0
]
!=
'1'
&&
atoi
(
ci
->
show_oid_column
)
&&
atoi
(
ci
->
fake_oid_index
))
{
{
row
=
(
TupleNode
*
)
malloc
(
sizeof
(
TupleNode
)
+
row
=
(
TupleNode
*
)
malloc
(
sizeof
(
TupleNode
)
+
(
13
-
1
)
*
sizeof
(
TupleField
));
(
13
-
1
)
*
sizeof
(
TupleField
));
/* no table qualifier */
/* no table qualifier */
set_tuplefield_string
(
&
row
->
tuple
[
0
],
""
);
set_tuplefield_string
(
&
row
->
tuple
[
0
],
""
);
...
@@ -2300,7 +2300,7 @@ SQLStatistics(
...
@@ -2300,7 +2300,7 @@ SQLStatistics(
while
(
i
<
8
&&
fields_vector
[
i
]
!=
0
)
while
(
i
<
8
&&
fields_vector
[
i
]
!=
0
)
{
{
row
=
(
TupleNode
*
)
malloc
(
sizeof
(
TupleNode
)
+
row
=
(
TupleNode
*
)
malloc
(
sizeof
(
TupleNode
)
+
(
13
-
1
)
*
sizeof
(
TupleField
));
(
13
-
1
)
*
sizeof
(
TupleField
));
/* no table qualifier */
/* no table qualifier */
set_tuplefield_string
(
&
row
->
tuple
[
0
],
""
);
set_tuplefield_string
(
&
row
->
tuple
[
0
],
""
);
...
@@ -2396,13 +2396,13 @@ SEEYA:
...
@@ -2396,13 +2396,13 @@ SEEYA:
RETCODE
SQL_API
RETCODE
SQL_API
SQLColumnPrivileges
(
SQLColumnPrivileges
(
HSTMT
hstmt
,
HSTMT
hstmt
,
UCHAR
FAR
*
szTableQualifier
,
UCHAR
FAR
*
szTableQualifier
,
SWORD
cbTableQualifier
,
SWORD
cbTableQualifier
,
UCHAR
FAR
*
szTableOwner
,
UCHAR
FAR
*
szTableOwner
,
SWORD
cbTableOwner
,
SWORD
cbTableOwner
,
UCHAR
FAR
*
szTableName
,
UCHAR
FAR
*
szTableName
,
SWORD
cbTableName
,
SWORD
cbTableName
,
UCHAR
FAR
*
szColumnName
,
UCHAR
FAR
*
szColumnName
,
SWORD
cbColumnName
)
SWORD
cbColumnName
)
{
{
static
char
*
func
=
"SQLColumnPrivileges"
;
static
char
*
func
=
"SQLColumnPrivileges"
;
...
@@ -2422,11 +2422,11 @@ SQLColumnPrivileges(
...
@@ -2422,11 +2422,11 @@ SQLColumnPrivileges(
RETCODE
SQL_API
RETCODE
SQL_API
SQLPrimaryKeys
(
SQLPrimaryKeys
(
HSTMT
hstmt
,
HSTMT
hstmt
,
UCHAR
FAR
*
szTableQualifier
,
UCHAR
FAR
*
szTableQualifier
,
SWORD
cbTableQualifier
,
SWORD
cbTableQualifier
,
UCHAR
FAR
*
szTableOwner
,
UCHAR
FAR
*
szTableOwner
,
SWORD
cbTableOwner
,
SWORD
cbTableOwner
,
UCHAR
FAR
*
szTableName
,
UCHAR
FAR
*
szTableName
,
SWORD
cbTableName
)
SWORD
cbTableName
)
{
{
static
char
*
func
=
"SQLPrimaryKeys"
;
static
char
*
func
=
"SQLPrimaryKeys"
;
...
@@ -2547,7 +2547,7 @@ SQLPrimaryKeys(
...
@@ -2547,7 +2547,7 @@ SQLPrimaryKeys(
while
((
result
==
SQL_SUCCESS
)
||
(
result
==
SQL_SUCCESS_WITH_INFO
))
while
((
result
==
SQL_SUCCESS
)
||
(
result
==
SQL_SUCCESS_WITH_INFO
))
{
{
row
=
(
TupleNode
*
)
malloc
(
sizeof
(
TupleNode
)
+
(
result_cols
-
1
)
*
sizeof
(
TupleField
));
row
=
(
TupleNode
*
)
malloc
(
sizeof
(
TupleNode
)
+
(
result_cols
-
1
)
*
sizeof
(
TupleField
));
set_tuplefield_null
(
&
row
->
tuple
[
0
]);
set_tuplefield_null
(
&
row
->
tuple
[
0
]);
...
@@ -2598,17 +2598,17 @@ SQLPrimaryKeys(
...
@@ -2598,17 +2598,17 @@ SQLPrimaryKeys(
RETCODE
SQL_API
RETCODE
SQL_API
SQLForeignKeys
(
SQLForeignKeys
(
HSTMT
hstmt
,
HSTMT
hstmt
,
UCHAR
FAR
*
szPkTableQualifier
,
UCHAR
FAR
*
szPkTableQualifier
,
SWORD
cbPkTableQualifier
,
SWORD
cbPkTableQualifier
,
UCHAR
FAR
*
szPkTableOwner
,
UCHAR
FAR
*
szPkTableOwner
,
SWORD
cbPkTableOwner
,
SWORD
cbPkTableOwner
,
UCHAR
FAR
*
szPkTableName
,
UCHAR
FAR
*
szPkTableName
,
SWORD
cbPkTableName
,
SWORD
cbPkTableName
,
UCHAR
FAR
*
szFkTableQualifier
,
UCHAR
FAR
*
szFkTableQualifier
,
SWORD
cbFkTableQualifier
,
SWORD
cbFkTableQualifier
,
UCHAR
FAR
*
szFkTableOwner
,
UCHAR
FAR
*
szFkTableOwner
,
SWORD
cbFkTableOwner
,
SWORD
cbFkTableOwner
,
UCHAR
FAR
*
szFkTableName
,
UCHAR
FAR
*
szFkTableName
,
SWORD
cbFkTableName
)
SWORD
cbFkTableName
)
{
{
static
char
*
func
=
"SQLForeignKeys"
;
static
char
*
func
=
"SQLForeignKeys"
;
...
@@ -2974,7 +2974,7 @@ SQLForeignKeys(
...
@@ -2974,7 +2974,7 @@ SQLForeignKeys(
for
(
k
=
0
;
k
<
num_keys
;
k
++
)
for
(
k
=
0
;
k
<
num_keys
;
k
++
)
{
{
row
=
(
TupleNode
*
)
malloc
(
sizeof
(
TupleNode
)
+
(
result_cols
-
1
)
*
sizeof
(
TupleField
));
row
=
(
TupleNode
*
)
malloc
(
sizeof
(
TupleNode
)
+
(
result_cols
-
1
)
*
sizeof
(
TupleField
));
mylog
(
"%s: pk_table = '%s', pkey_ptr = '%s'
\n
"
,
func
,
pk_table
,
pkey_ptr
);
mylog
(
"%s: pk_table = '%s', pkey_ptr = '%s'
\n
"
,
func
,
pk_table
,
pkey_ptr
);
set_tuplefield_null
(
&
row
->
tuple
[
0
]);
set_tuplefield_null
(
&
row
->
tuple
[
0
]);
...
@@ -3199,7 +3199,7 @@ SQLForeignKeys(
...
@@ -3199,7 +3199,7 @@ SQLForeignKeys(
{
{
mylog
(
"pkey_ptr = '%s', fk_table = '%s', fkey_ptr = '%s'
\n
"
,
pkey_ptr
,
fk_table
,
fkey_ptr
);
mylog
(
"pkey_ptr = '%s', fk_table = '%s', fkey_ptr = '%s'
\n
"
,
pkey_ptr
,
fk_table
,
fkey_ptr
);
row
=
(
TupleNode
*
)
malloc
(
sizeof
(
TupleNode
)
+
(
result_cols
-
1
)
*
sizeof
(
TupleField
));
row
=
(
TupleNode
*
)
malloc
(
sizeof
(
TupleNode
)
+
(
result_cols
-
1
)
*
sizeof
(
TupleField
));
mylog
(
"pk_table_needed = '%s', pkey_ptr = '%s'
\n
"
,
pk_table_needed
,
pkey_ptr
);
mylog
(
"pk_table_needed = '%s', pkey_ptr = '%s'
\n
"
,
pk_table_needed
,
pkey_ptr
);
set_tuplefield_null
(
&
row
->
tuple
[
0
]);
set_tuplefield_null
(
&
row
->
tuple
[
0
]);
...
@@ -3262,13 +3262,13 @@ SQLForeignKeys(
...
@@ -3262,13 +3262,13 @@ SQLForeignKeys(
RETCODE
SQL_API
RETCODE
SQL_API
SQLProcedureColumns
(
SQLProcedureColumns
(
HSTMT
hstmt
,
HSTMT
hstmt
,
UCHAR
FAR
*
szProcQualifier
,
UCHAR
FAR
*
szProcQualifier
,
SWORD
cbProcQualifier
,
SWORD
cbProcQualifier
,
UCHAR
FAR
*
szProcOwner
,
UCHAR
FAR
*
szProcOwner
,
SWORD
cbProcOwner
,
SWORD
cbProcOwner
,
UCHAR
FAR
*
szProcName
,
UCHAR
FAR
*
szProcName
,
SWORD
cbProcName
,
SWORD
cbProcName
,
UCHAR
FAR
*
szColumnName
,
UCHAR
FAR
*
szColumnName
,
SWORD
cbColumnName
)
SWORD
cbColumnName
)
{
{
static
char
*
func
=
"SQLProcedureColumns"
;
static
char
*
func
=
"SQLProcedureColumns"
;
...
@@ -3282,11 +3282,11 @@ SQLProcedureColumns(
...
@@ -3282,11 +3282,11 @@ SQLProcedureColumns(
RETCODE
SQL_API
RETCODE
SQL_API
SQLProcedures
(
SQLProcedures
(
HSTMT
hstmt
,
HSTMT
hstmt
,
UCHAR
FAR
*
szProcQualifier
,
UCHAR
FAR
*
szProcQualifier
,
SWORD
cbProcQualifier
,
SWORD
cbProcQualifier
,
UCHAR
FAR
*
szProcOwner
,
UCHAR
FAR
*
szProcOwner
,
SWORD
cbProcOwner
,
SWORD
cbProcOwner
,
UCHAR
FAR
*
szProcName
,
UCHAR
FAR
*
szProcName
,
SWORD
cbProcName
)
SWORD
cbProcName
)
{
{
static
char
*
func
=
"SQLProcedures"
;
static
char
*
func
=
"SQLProcedures"
;
...
@@ -3300,11 +3300,11 @@ SQLProcedures(
...
@@ -3300,11 +3300,11 @@ SQLProcedures(
RETCODE
SQL_API
RETCODE
SQL_API
SQLTablePrivileges
(
SQLTablePrivileges
(
HSTMT
hstmt
,
HSTMT
hstmt
,
UCHAR
FAR
*
szTableQualifier
,
UCHAR
FAR
*
szTableQualifier
,
SWORD
cbTableQualifier
,
SWORD
cbTableQualifier
,
UCHAR
FAR
*
szTableOwner
,
UCHAR
FAR
*
szTableOwner
,
SWORD
cbTableOwner
,
SWORD
cbTableOwner
,
UCHAR
FAR
*
szTableName
,
UCHAR
FAR
*
szTableName
,
SWORD
cbTableName
)
SWORD
cbTableName
)
{
{
static
char
*
func
=
"SQLTablePrivileges"
;
static
char
*
func
=
"SQLTablePrivileges"
;
...
...
src/interfaces/odbc/isql.h
View file @
26dc5014
...
@@ -134,16 +134,16 @@ extern "C"
...
@@ -134,16 +134,16 @@ extern "C"
#endif
#endif
RETCODE
SQL_API
SQLAllocConnect
(
HENV
henv
,
RETCODE
SQL_API
SQLAllocConnect
(
HENV
henv
,
HDBC
FAR
*
phdbc
);
HDBC
FAR
*
phdbc
);
RETCODE
SQL_API
SQLAllocEnv
(
HENV
FAR
*
phenv
);
RETCODE
SQL_API
SQLAllocEnv
(
HENV
FAR
*
phenv
);
RETCODE
SQL_API
SQLAllocStmt
(
HDBC
hdbc
,
RETCODE
SQL_API
SQLAllocStmt
(
HDBC
hdbc
,
HSTMT
FAR
*
phstmt
);
HSTMT
FAR
*
phstmt
);
RETCODE
SQL_API
SQLBindCol
(
HSTMT
hstmt
,
RETCODE
SQL_API
SQLBindCol
(
HSTMT
hstmt
,
UWORD
icol
,
UWORD
icol
,
SWORD
fCType
,
SWORD
fCType
,
PTR
rgbValue
,
PTR
rgbValue
,
SDWORD
cbValueMax
,
SDWORD
cbValueMax
,
SDWORD
FAR
*
pcbValue
);
SDWORD
FAR
*
pcbValue
);
RETCODE
SQL_API
SQLCancel
(
HSTMT
hstmt
);
RETCODE
SQL_API
SQLCancel
(
HSTMT
hstmt
);
...
@@ -152,40 +152,40 @@ extern "C"
...
@@ -152,40 +152,40 @@ extern "C"
UWORD
fDescType
,
UWORD
fDescType
,
PTR
rgbDesc
,
PTR
rgbDesc
,
SWORD
cbDescMax
,
SWORD
cbDescMax
,
SWORD
FAR
*
pcbDesc
,
SWORD
FAR
*
pcbDesc
,
SDWORD
FAR
*
pfDesc
);
SDWORD
FAR
*
pfDesc
);
RETCODE
SQL_API
SQLConnect
(
HDBC
hdbc
,
RETCODE
SQL_API
SQLConnect
(
HDBC
hdbc
,
UCHAR
FAR
*
szDSN
,
UCHAR
FAR
*
szDSN
,
SWORD
cbDSN
,
SWORD
cbDSN
,
UCHAR
FAR
*
szUID
,
UCHAR
FAR
*
szUID
,
SWORD
cbUID
,
SWORD
cbUID
,
UCHAR
FAR
*
szAuthStr
,
UCHAR
FAR
*
szAuthStr
,
SWORD
cbAuthStr
);
SWORD
cbAuthStr
);
RETCODE
SQL_API
SQLDescribeCol
(
HSTMT
hstmt
,
RETCODE
SQL_API
SQLDescribeCol
(
HSTMT
hstmt
,
UWORD
icol
,
UWORD
icol
,
UCHAR
FAR
*
szColName
,
UCHAR
FAR
*
szColName
,
SWORD
cbColNameMax
,
SWORD
cbColNameMax
,
SWORD
FAR
*
pcbColName
,
SWORD
FAR
*
pcbColName
,
SWORD
FAR
*
pfSqlType
,
SWORD
FAR
*
pfSqlType
,
UDWORD
FAR
*
pcbColDef
,
UDWORD
FAR
*
pcbColDef
,
SWORD
FAR
*
pibScale
,
SWORD
FAR
*
pibScale
,
SWORD
FAR
*
pfNullable
);
SWORD
FAR
*
pfNullable
);
RETCODE
SQL_API
SQLDisconnect
(
HDBC
hdbc
);
RETCODE
SQL_API
SQLDisconnect
(
HDBC
hdbc
);
RETCODE
SQL_API
SQLError
(
HENV
henv
,
RETCODE
SQL_API
SQLError
(
HENV
henv
,
HDBC
hdbc
,
HDBC
hdbc
,
HSTMT
hstmt
,
HSTMT
hstmt
,
UCHAR
FAR
*
szSqlState
,
UCHAR
FAR
*
szSqlState
,
SDWORD
FAR
*
pfNativeError
,
SDWORD
FAR
*
pfNativeError
,
UCHAR
FAR
*
szErrorMsg
,
UCHAR
FAR
*
szErrorMsg
,
SWORD
cbErrorMsgMax
,
SWORD
cbErrorMsgMax
,
SWORD
FAR
*
pcbErrorMsg
);
SWORD
FAR
*
pcbErrorMsg
);
RETCODE
SQL_API
SQLExecDirect
(
HSTMT
hstmt
,
RETCODE
SQL_API
SQLExecDirect
(
HSTMT
hstmt
,
UCHAR
FAR
*
szSqlStr
,
UCHAR
FAR
*
szSqlStr
,
SDWORD
cbSqlStr
);
SDWORD
cbSqlStr
);
RETCODE
SQL_API
SQLExecute
(
HSTMT
hstmt
);
RETCODE
SQL_API
SQLExecute
(
HSTMT
hstmt
);
...
@@ -200,18 +200,18 @@ extern "C"
...
@@ -200,18 +200,18 @@ extern "C"
UWORD
fOption
);
UWORD
fOption
);
RETCODE
SQL_API
SQLGetCursorName
(
HSTMT
hstmt
,
RETCODE
SQL_API
SQLGetCursorName
(
HSTMT
hstmt
,
UCHAR
FAR
*
szCursor
,
UCHAR
FAR
*
szCursor
,
SWORD
cbCursorMax
,
SWORD
cbCursorMax
,
SWORD
FAR
*
pcbCursor
);
SWORD
FAR
*
pcbCursor
);
RETCODE
SQL_API
SQLNumResultCols
(
HSTMT
hstmt
,
SWORD
FAR
*
pccol
);
RETCODE
SQL_API
SQLNumResultCols
(
HSTMT
hstmt
,
SWORD
FAR
*
pccol
);
RETCODE
SQL_API
SQLPrepare
(
HSTMT
hstmt
,
UCHAR
FAR
*
szSqlStr
,
RETCODE
SQL_API
SQLPrepare
(
HSTMT
hstmt
,
UCHAR
FAR
*
szSqlStr
,
SDWORD
cbSqlStr
);
SDWORD
cbSqlStr
);
RETCODE
SQL_API
SQLRowCount
(
HSTMT
hstmt
,
SDWORD
FAR
*
pcrow
);
RETCODE
SQL_API
SQLRowCount
(
HSTMT
hstmt
,
SDWORD
FAR
*
pcrow
);
RETCODE
SQL_API
SQLSetCursorName
(
HSTMT
hstmt
,
UCHAR
FAR
*
szCursor
,
RETCODE
SQL_API
SQLSetCursorName
(
HSTMT
hstmt
,
UCHAR
FAR
*
szCursor
,
SWORD
cbCursor
);
SWORD
cbCursor
);
RETCODE
SQL_API
SQLTransact
(
HENV
henv
,
HDBC
hdbc
,
RETCODE
SQL_API
SQLTransact
(
HENV
henv
,
HDBC
hdbc
,
...
@@ -223,7 +223,7 @@ extern "C"
...
@@ -223,7 +223,7 @@ extern "C"
UDWORD
cbColDef
,
UDWORD
cbColDef
,
SWORD
ibScale
,
SWORD
ibScale
,
PTR
rgbValue
,
PTR
rgbValue
,
SDWORD
FAR
*
pcbValue
);
SDWORD
FAR
*
pcbValue
);
#ifdef __cplusplus
#ifdef __cplusplus
}
}
...
...
src/interfaces/odbc/isqlext.h
View file @
26dc5014
...
@@ -384,14 +384,16 @@ typedef struct tagDATE_STRUCT
...
@@ -384,14 +384,16 @@ typedef struct tagDATE_STRUCT
SQLSMALLINT
year
;
SQLSMALLINT
year
;
SQLUSMALLINT
month
;
SQLUSMALLINT
month
;
SQLUSMALLINT
day
;
SQLUSMALLINT
day
;
}
DATE_STRUCT
,
SQL_DATE_STRUCT
;
}
DATE_STRUCT
,
SQL_DATE_STRUCT
;
typedef
struct
tagTIME_STRUCT
typedef
struct
tagTIME_STRUCT
{
{
SQLUSMALLINT
hour
;
SQLUSMALLINT
hour
;
SQLUSMALLINT
minute
;
SQLUSMALLINT
minute
;
SQLUSMALLINT
second
;
SQLUSMALLINT
second
;
}
TIME_STRUCT
,
SQL_TIME_STRUCT
;
}
TIME_STRUCT
,
SQL_TIME_STRUCT
;
typedef
struct
tagTIMESTAMP_STRUCT
typedef
struct
tagTIMESTAMP_STRUCT
{
{
...
@@ -402,7 +404,8 @@ typedef struct tagTIMESTAMP_STRUCT
...
@@ -402,7 +404,8 @@ typedef struct tagTIMESTAMP_STRUCT
SQLUSMALLINT
minute
;
SQLUSMALLINT
minute
;
SQLUSMALLINT
second
;
SQLUSMALLINT
second
;
SQLUINTEGER
fraction
;
SQLUINTEGER
fraction
;
}
TIMESTAMP_STRUCT
,
SQL_TIMESTAMP_STRUCT
;
}
TIMESTAMP_STRUCT
,
SQL_TIMESTAMP_STRUCT
;
/* postodbc doesn't use these but what the heck */
/* postodbc doesn't use these but what the heck */
/* Don't know what SQL_MAX_NUMERIC_LEN should be so I can't include this. It's
/* Don't know what SQL_MAX_NUMERIC_LEN should be so I can't include this. It's
...
@@ -1341,22 +1344,22 @@ extern "C"
...
@@ -1341,22 +1344,22 @@ extern "C"
* function prototypes previously missing from isqlext.h
* function prototypes previously missing from isqlext.h
*/
*/
RETCODE
SQL_API
SQLColumns
(
HSTMT
hstmt
,
RETCODE
SQL_API
SQLColumns
(
HSTMT
hstmt
,
UCHAR
FAR
*
szTableQualifier
,
UCHAR
FAR
*
szTableQualifier
,
SWORD
cbTableQualifier
,
SWORD
cbTableQualifier
,
UCHAR
FAR
*
szTableOwner
,
UCHAR
FAR
*
szTableOwner
,
SWORD
cbTableOwner
,
SWORD
cbTableOwner
,
UCHAR
FAR
*
szTableName
,
UCHAR
FAR
*
szTableName
,
SWORD
cbTableName
,
SWORD
cbTableName
,
UCHAR
FAR
*
szColumnName
,
UCHAR
FAR
*
szColumnName
,
SWORD
cbColumnName
);
SWORD
cbColumnName
);
RETCODE
SQL_API
SQLDriverConnect
(
HDBC
hdbc
,
RETCODE
SQL_API
SQLDriverConnect
(
HDBC
hdbc
,
HWND
hwnd
,
HWND
hwnd
,
UCHAR
FAR
*
szConnStrIn
,
UCHAR
FAR
*
szConnStrIn
,
SWORD
cbConnStrIn
,
SWORD
cbConnStrIn
,
UCHAR
FAR
*
szConnStrOut
,
UCHAR
FAR
*
szConnStrOut
,
SWORD
cbConnStrOutMax
,
SWORD
cbConnStrOutMax
,
SWORD
FAR
*
pcbConnStrOut
,
SWORD
FAR
*
pcbConnStrOut
,
UWORD
fDriverCompletion
);
UWORD
fDriverCompletion
);
RETCODE
SQL_API
SQLGetConnectOption
(
HDBC
hdbc
,
RETCODE
SQL_API
SQLGetConnectOption
(
HDBC
hdbc
,
...
@@ -1368,17 +1371,17 @@ extern "C"
...
@@ -1368,17 +1371,17 @@ extern "C"
SWORD
fCType
,
SWORD
fCType
,
PTR
rgbValue
,
PTR
rgbValue
,
SDWORD
cbValueMax
,
SDWORD
cbValueMax
,
SDWORD
FAR
*
pcbValue
);
SDWORD
FAR
*
pcbValue
);
RETCODE
SQL_API
SQLGetFunctions
(
HDBC
hdbc
,
RETCODE
SQL_API
SQLGetFunctions
(
HDBC
hdbc
,
UWORD
fFunction
,
UWORD
fFunction
,
UWORD
FAR
*
pfExists
);
UWORD
FAR
*
pfExists
);
RETCODE
SQL_API
SQLGetInfo
(
HDBC
hdbc
,
RETCODE
SQL_API
SQLGetInfo
(
HDBC
hdbc
,
UWORD
fInfoType
,
UWORD
fInfoType
,
PTR
rgbInfoValue
,
PTR
rgbInfoValue
,
SWORD
cbInfoValueMax
,
SWORD
cbInfoValueMax
,
SWORD
FAR
*
pcbInfoValue
);
SWORD
FAR
*
pcbInfoValue
);
RETCODE
SQL_API
SQLGetStmtOption
(
HSTMT
hstmt
,
RETCODE
SQL_API
SQLGetStmtOption
(
HSTMT
hstmt
,
UWORD
fOption
,
UWORD
fOption
,
...
@@ -1388,7 +1391,7 @@ extern "C"
...
@@ -1388,7 +1391,7 @@ extern "C"
SWORD
fSqlType
);
SWORD
fSqlType
);
RETCODE
SQL_API
SQLParamData
(
HSTMT
hstmt
,
RETCODE
SQL_API
SQLParamData
(
HSTMT
hstmt
,
PTR
FAR
*
prgbValue
);
PTR
FAR
*
prgbValue
);
RETCODE
SQL_API
SQLPutData
(
HSTMT
hstmt
,
RETCODE
SQL_API
SQLPutData
(
HSTMT
hstmt
,
PTR
rgbValue
,
PTR
rgbValue
,
...
@@ -1400,119 +1403,119 @@ extern "C"
...
@@ -1400,119 +1403,119 @@ extern "C"
RETCODE
SQL_API
SQLSpecialColumns
(
HSTMT
hstmt
,
RETCODE
SQL_API
SQLSpecialColumns
(
HSTMT
hstmt
,
UWORD
fColType
,
UWORD
fColType
,
UCHAR
FAR
*
szTableQualifier
,
UCHAR
FAR
*
szTableQualifier
,
SWORD
cbTableQualifier
,
SWORD
cbTableQualifier
,
UCHAR
FAR
*
szTableOwner
,
UCHAR
FAR
*
szTableOwner
,
SWORD
cbTableOwner
,
SWORD
cbTableOwner
,
UCHAR
FAR
*
szTableName
,
UCHAR
FAR
*
szTableName
,
SWORD
cbTableName
,
SWORD
cbTableName
,
UWORD
fScope
,
UWORD
fScope
,
UWORD
fNullable
);
UWORD
fNullable
);
RETCODE
SQL_API
SQLStatistics
(
HSTMT
hstmt
,
RETCODE
SQL_API
SQLStatistics
(
HSTMT
hstmt
,
UCHAR
FAR
*
szTableQualifier
,
UCHAR
FAR
*
szTableQualifier
,
SWORD
cbTableQualifier
,
SWORD
cbTableQualifier
,
UCHAR
FAR
*
szTableOwner
,
UCHAR
FAR
*
szTableOwner
,
SWORD
cbTableOwner
,
SWORD
cbTableOwner
,
UCHAR
FAR
*
szTableName
,
UCHAR
FAR
*
szTableName
,
SWORD
cbTableName
,
SWORD
cbTableName
,
UWORD
fUnique
,
UWORD
fUnique
,
UWORD
fAccuracy
);
UWORD
fAccuracy
);
RETCODE
SQL_API
SQLTables
(
HSTMT
hstmt
,
RETCODE
SQL_API
SQLTables
(
HSTMT
hstmt
,
UCHAR
FAR
*
szTableQualifier
,
UCHAR
FAR
*
szTableQualifier
,
SWORD
cbTableQualifier
,
SWORD
cbTableQualifier
,
UCHAR
FAR
*
szTableOwner
,
UCHAR
FAR
*
szTableOwner
,
SWORD
cbTableOwner
,
SWORD
cbTableOwner
,
UCHAR
FAR
*
szTableName
,
UCHAR
FAR
*
szTableName
,
SWORD
cbTableName
,
SWORD
cbTableName
,
UCHAR
FAR
*
szTableType
,
UCHAR
FAR
*
szTableType
,
SWORD
cbTableType
);
SWORD
cbTableType
);
RETCODE
SQL_API
SQLBrowseConnect
(
HDBC
hdbc
,
RETCODE
SQL_API
SQLBrowseConnect
(
HDBC
hdbc
,
UCHAR
FAR
*
szConnStrIn
,
UCHAR
FAR
*
szConnStrIn
,
SWORD
cbConnStrIn
,
SWORD
cbConnStrIn
,
UCHAR
FAR
*
szConnStrOut
,
UCHAR
FAR
*
szConnStrOut
,
SWORD
cbConnStrOutMax
,
SWORD
cbConnStrOutMax
,
SWORD
FAR
*
pcbConnStrOut
);
SWORD
FAR
*
pcbConnStrOut
);
RETCODE
SQL_API
SQLColumnPrivileges
(
HSTMT
hstmt
,
RETCODE
SQL_API
SQLColumnPrivileges
(
HSTMT
hstmt
,
UCHAR
FAR
*
szTableQualifier
,
UCHAR
FAR
*
szTableQualifier
,
SWORD
cbTableQualifier
,
SWORD
cbTableQualifier
,
UCHAR
FAR
*
szTableOwner
,
UCHAR
FAR
*
szTableOwner
,
SWORD
cbTableOwner
,
SWORD
cbTableOwner
,
UCHAR
FAR
*
szTableName
,
UCHAR
FAR
*
szTableName
,
SWORD
cbTableName
,
SWORD
cbTableName
,
UCHAR
FAR
*
szColumnName
,
UCHAR
FAR
*
szColumnName
,
SWORD
cbColumnName
);
SWORD
cbColumnName
);
RETCODE
SQL_API
SQLDescribeParam
(
HSTMT
hstmt
,
RETCODE
SQL_API
SQLDescribeParam
(
HSTMT
hstmt
,
UWORD
ipar
,
UWORD
ipar
,
SWORD
FAR
*
pfSqlType
,
SWORD
FAR
*
pfSqlType
,
UDWORD
FAR
*
pcbColDef
,
UDWORD
FAR
*
pcbColDef
,
SWORD
FAR
*
pibScale
,
SWORD
FAR
*
pibScale
,
SWORD
FAR
*
pfNullable
);
SWORD
FAR
*
pfNullable
);
RETCODE
SQL_API
SQLExtendedFetch
(
HSTMT
hstmt
,
RETCODE
SQL_API
SQLExtendedFetch
(
HSTMT
hstmt
,
UWORD
fFetchType
,
UWORD
fFetchType
,
SDWORD
irow
,
SDWORD
irow
,
UDWORD
FAR
*
pcrow
,
UDWORD
FAR
*
pcrow
,
UWORD
FAR
*
rgfRowStatus
);
UWORD
FAR
*
rgfRowStatus
);
RETCODE
SQL_API
SQLForeignKeys
(
HSTMT
hstmt
,
RETCODE
SQL_API
SQLForeignKeys
(
HSTMT
hstmt
,
UCHAR
FAR
*
szPkTableQualifier
,
UCHAR
FAR
*
szPkTableQualifier
,
SWORD
cbPkTableQualifier
,
SWORD
cbPkTableQualifier
,
UCHAR
FAR
*
szPkTableOwner
,
UCHAR
FAR
*
szPkTableOwner
,
SWORD
cbPkTableOwner
,
SWORD
cbPkTableOwner
,
UCHAR
FAR
*
szPkTableName
,
UCHAR
FAR
*
szPkTableName
,
SWORD
cbPkTableName
,
SWORD
cbPkTableName
,
UCHAR
FAR
*
szFkTableQualifier
,
UCHAR
FAR
*
szFkTableQualifier
,
SWORD
cbFkTableQualifier
,
SWORD
cbFkTableQualifier
,
UCHAR
FAR
*
szFkTableOwner
,
UCHAR
FAR
*
szFkTableOwner
,
SWORD
cbFkTableOwner
,
SWORD
cbFkTableOwner
,
UCHAR
FAR
*
szFkTableName
,
UCHAR
FAR
*
szFkTableName
,
SWORD
cbFkTableName
);
SWORD
cbFkTableName
);
RETCODE
SQL_API
SQLMoreResults
(
HSTMT
hstmt
);
RETCODE
SQL_API
SQLMoreResults
(
HSTMT
hstmt
);
RETCODE
SQL_API
SQLNativeSql
(
HDBC
hdbc
,
RETCODE
SQL_API
SQLNativeSql
(
HDBC
hdbc
,
UCHAR
FAR
*
szSqlStrIn
,
UCHAR
FAR
*
szSqlStrIn
,
SDWORD
cbSqlStrIn
,
SDWORD
cbSqlStrIn
,
UCHAR
FAR
*
szSqlStr
,
UCHAR
FAR
*
szSqlStr
,
SDWORD
cbSqlStrMax
,
SDWORD
cbSqlStrMax
,
SDWORD
FAR
*
pcbSqlStr
);
SDWORD
FAR
*
pcbSqlStr
);
RETCODE
SQL_API
SQLNumParams
(
HSTMT
hstmt
,
RETCODE
SQL_API
SQLNumParams
(
HSTMT
hstmt
,
SWORD
FAR
*
pcpar
);
SWORD
FAR
*
pcpar
);
RETCODE
SQL_API
SQLParamOptions
(
HSTMT
hstmt
,
RETCODE
SQL_API
SQLParamOptions
(
HSTMT
hstmt
,
UDWORD
crow
,
UDWORD
crow
,
UDWORD
FAR
*
pirow
);
UDWORD
FAR
*
pirow
);
RETCODE
SQL_API
SQLPrimaryKeys
(
HSTMT
hstmt
,
RETCODE
SQL_API
SQLPrimaryKeys
(
HSTMT
hstmt
,
UCHAR
FAR
*
szTableQualifier
,
UCHAR
FAR
*
szTableQualifier
,
SWORD
cbTableQualifier
,
SWORD
cbTableQualifier
,
UCHAR
FAR
*
szTableOwner
,
UCHAR
FAR
*
szTableOwner
,
SWORD
cbTableOwner
,
SWORD
cbTableOwner
,
UCHAR
FAR
*
szTableName
,
UCHAR
FAR
*
szTableName
,
SWORD
cbTableName
);
SWORD
cbTableName
);
RETCODE
SQL_API
SQLProcedureColumns
(
HSTMT
hstmt
,
RETCODE
SQL_API
SQLProcedureColumns
(
HSTMT
hstmt
,
UCHAR
FAR
*
szProcQualifier
,
UCHAR
FAR
*
szProcQualifier
,
SWORD
cbProcQualifier
,
SWORD
cbProcQualifier
,
UCHAR
FAR
*
szProcOwner
,
UCHAR
FAR
*
szProcOwner
,
SWORD
cbProcOwner
,
SWORD
cbProcOwner
,
UCHAR
FAR
*
szProcName
,
UCHAR
FAR
*
szProcName
,
SWORD
cbProcName
,
SWORD
cbProcName
,
UCHAR
FAR
*
szColumnName
,
UCHAR
FAR
*
szColumnName
,
SWORD
cbColumnName
);
SWORD
cbColumnName
);
RETCODE
SQL_API
SQLProcedures
(
HSTMT
hstmt
,
RETCODE
SQL_API
SQLProcedures
(
HSTMT
hstmt
,
UCHAR
FAR
*
szProcQualifier
,
UCHAR
FAR
*
szProcQualifier
,
SWORD
cbProcQualifier
,
SWORD
cbProcQualifier
,
UCHAR
FAR
*
szProcOwner
,
UCHAR
FAR
*
szProcOwner
,
SWORD
cbProcOwner
,
SWORD
cbProcOwner
,
UCHAR
FAR
*
szProcName
,
UCHAR
FAR
*
szProcName
,
SWORD
cbProcName
);
SWORD
cbProcName
);
RETCODE
SQL_API
SQLSetPos
(
HSTMT
hstmt
,
RETCODE
SQL_API
SQLSetPos
(
HSTMT
hstmt
,
...
@@ -1521,11 +1524,11 @@ extern "C"
...
@@ -1521,11 +1524,11 @@ extern "C"
UWORD
fLock
);
UWORD
fLock
);
RETCODE
SQL_API
SQLTablePrivileges
(
HSTMT
hstmt
,
RETCODE
SQL_API
SQLTablePrivileges
(
HSTMT
hstmt
,
UCHAR
FAR
*
szTableQualifier
,
UCHAR
FAR
*
szTableQualifier
,
SWORD
cbTableQualifier
,
SWORD
cbTableQualifier
,
UCHAR
FAR
*
szTableOwner
,
UCHAR
FAR
*
szTableOwner
,
SWORD
cbTableOwner
,
SWORD
cbTableOwner
,
UCHAR
FAR
*
szTableName
,
UCHAR
FAR
*
szTableName
,
SWORD
cbTableName
);
SWORD
cbTableName
);
RETCODE
SQL_API
SQLBindParameter
(
HSTMT
hstmt
,
RETCODE
SQL_API
SQLBindParameter
(
HSTMT
hstmt
,
...
@@ -1537,7 +1540,7 @@ extern "C"
...
@@ -1537,7 +1540,7 @@ extern "C"
SWORD
ibScale
,
SWORD
ibScale
,
PTR
rgbValue
,
PTR
rgbValue
,
SDWORD
cbValueMax
,
SDWORD
cbValueMax
,
SDWORD
FAR
*
pcbValue
);
SDWORD
FAR
*
pcbValue
);
RETCODE
SQL_API
SQLSetScrollOptions
(
HSTMT
hstmt
,
RETCODE
SQL_API
SQLSetScrollOptions
(
HSTMT
hstmt
,
UWORD
fConcurrency
,
UWORD
fConcurrency
,
...
...
src/interfaces/odbc/lobj.c
View file @
26dc5014
...
@@ -16,7 +16,7 @@
...
@@ -16,7 +16,7 @@
#include "connection.h"
#include "connection.h"
Oid
Oid
lo_creat
(
ConnectionClass
*
conn
,
int
mode
)
lo_creat
(
ConnectionClass
*
conn
,
int
mode
)
{
{
LO_ARG
argv
[
1
];
LO_ARG
argv
[
1
];
int
retval
,
int
retval
,
...
@@ -35,7 +35,7 @@ lo_creat(ConnectionClass * conn, int mode)
...
@@ -35,7 +35,7 @@ lo_creat(ConnectionClass * conn, int mode)
}
}
int
int
lo_open
(
ConnectionClass
*
conn
,
int
lobjId
,
int
mode
)
lo_open
(
ConnectionClass
*
conn
,
int
lobjId
,
int
mode
)
{
{
int
fd
;
int
fd
;
int
result_len
;
int
result_len
;
...
@@ -60,7 +60,7 @@ lo_open(ConnectionClass * conn, int lobjId, int mode)
...
@@ -60,7 +60,7 @@ lo_open(ConnectionClass * conn, int lobjId, int mode)
}
}
int
int
lo_close
(
ConnectionClass
*
conn
,
int
fd
)
lo_close
(
ConnectionClass
*
conn
,
int
fd
)
{
{
LO_ARG
argv
[
1
];
LO_ARG
argv
[
1
];
int
retval
,
int
retval
,
...
@@ -80,7 +80,7 @@ lo_close(ConnectionClass * conn, int fd)
...
@@ -80,7 +80,7 @@ lo_close(ConnectionClass * conn, int fd)
int
int
lo_read
(
ConnectionClass
*
conn
,
int
fd
,
char
*
buf
,
int
len
)
lo_read
(
ConnectionClass
*
conn
,
int
fd
,
char
*
buf
,
int
len
)
{
{
LO_ARG
argv
[
2
];
LO_ARG
argv
[
2
];
int
result_len
;
int
result_len
;
...
@@ -102,7 +102,7 @@ lo_read(ConnectionClass * conn, int fd, char *buf, int len)
...
@@ -102,7 +102,7 @@ lo_read(ConnectionClass * conn, int fd, char *buf, int len)
}
}
int
int
lo_write
(
ConnectionClass
*
conn
,
int
fd
,
char
*
buf
,
int
len
)
lo_write
(
ConnectionClass
*
conn
,
int
fd
,
char
*
buf
,
int
len
)
{
{
LO_ARG
argv
[
2
];
LO_ARG
argv
[
2
];
int
retval
,
int
retval
,
...
@@ -128,7 +128,7 @@ lo_write(ConnectionClass * conn, int fd, char *buf, int len)
...
@@ -128,7 +128,7 @@ lo_write(ConnectionClass * conn, int fd, char *buf, int len)
}
}
int
int
lo_lseek
(
ConnectionClass
*
conn
,
int
fd
,
int
offset
,
int
whence
)
lo_lseek
(
ConnectionClass
*
conn
,
int
fd
,
int
offset
,
int
whence
)
{
{
LO_ARG
argv
[
3
];
LO_ARG
argv
[
3
];
int
retval
,
int
retval
,
...
@@ -155,7 +155,7 @@ lo_lseek(ConnectionClass * conn, int fd, int offset, int whence)
...
@@ -155,7 +155,7 @@ lo_lseek(ConnectionClass * conn, int fd, int offset, int whence)
}
}
int
int
lo_tell
(
ConnectionClass
*
conn
,
int
fd
)
lo_tell
(
ConnectionClass
*
conn
,
int
fd
)
{
{
LO_ARG
argv
[
1
];
LO_ARG
argv
[
1
];
int
retval
,
int
retval
,
...
@@ -174,7 +174,7 @@ lo_tell(ConnectionClass * conn, int fd)
...
@@ -174,7 +174,7 @@ lo_tell(ConnectionClass * conn, int fd)
}
}
int
int
lo_unlink
(
ConnectionClass
*
conn
,
Oid
lobjId
)
lo_unlink
(
ConnectionClass
*
conn
,
Oid
lobjId
)
{
{
LO_ARG
argv
[
1
];
LO_ARG
argv
[
1
];
int
retval
,
int
retval
,
...
...
src/interfaces/odbc/lobj.h
View file @
26dc5014
...
@@ -36,13 +36,13 @@ struct lo_arg
...
@@ -36,13 +36,13 @@ struct lo_arg
#define INV_WRITE 0x00020000
#define INV_WRITE 0x00020000
#define INV_READ 0x00040000
#define INV_READ 0x00040000
Oid
lo_creat
(
ConnectionClass
*
conn
,
int
mode
);
Oid
lo_creat
(
ConnectionClass
*
conn
,
int
mode
);
int
lo_open
(
ConnectionClass
*
conn
,
int
lobjId
,
int
mode
);
int
lo_open
(
ConnectionClass
*
conn
,
int
lobjId
,
int
mode
);
int
lo_close
(
ConnectionClass
*
conn
,
int
fd
);
int
lo_close
(
ConnectionClass
*
conn
,
int
fd
);
int
lo_read
(
ConnectionClass
*
conn
,
int
fd
,
char
*
buf
,
int
len
);
int
lo_read
(
ConnectionClass
*
conn
,
int
fd
,
char
*
buf
,
int
len
);
int
lo_write
(
ConnectionClass
*
conn
,
int
fd
,
char
*
buf
,
int
len
);
int
lo_write
(
ConnectionClass
*
conn
,
int
fd
,
char
*
buf
,
int
len
);
int
lo_lseek
(
ConnectionClass
*
conn
,
int
fd
,
int
offset
,
int
len
);
int
lo_lseek
(
ConnectionClass
*
conn
,
int
fd
,
int
offset
,
int
len
);
int
lo_tell
(
ConnectionClass
*
conn
,
int
fd
);
int
lo_tell
(
ConnectionClass
*
conn
,
int
fd
);
int
lo_unlink
(
ConnectionClass
*
conn
,
Oid
lobjId
);
int
lo_unlink
(
ConnectionClass
*
conn
,
Oid
lobjId
);
#endif
#endif
src/interfaces/odbc/options.c
View file @
26dc5014
...
@@ -37,16 +37,16 @@
...
@@ -37,16 +37,16 @@
extern
GLOBAL_VALUES
globals
;
extern
GLOBAL_VALUES
globals
;
RETCODE
set_statement_option
(
ConnectionClass
*
conn
,
RETCODE
set_statement_option
(
ConnectionClass
*
conn
,
StatementClass
*
stmt
,
StatementClass
*
stmt
,
UWORD
fOption
,
UWORD
fOption
,
UDWORD
vParam
);
UDWORD
vParam
);
RETCODE
RETCODE
set_statement_option
(
ConnectionClass
*
conn
,
set_statement_option
(
ConnectionClass
*
conn
,
StatementClass
*
stmt
,
StatementClass
*
stmt
,
UWORD
fOption
,
UWORD
fOption
,
UDWORD
vParam
)
UDWORD
vParam
)
{
{
...
...
src/interfaces/odbc/parse.c
View file @
26dc5014
...
@@ -38,8 +38,8 @@
...
@@ -38,8 +38,8 @@
#define COL_INCR 16
#define COL_INCR 16
char
*
getNextToken
(
char
*
s
,
char
*
token
,
int
smax
,
char
*
delim
,
char
*
quote
,
char
*
dquote
,
char
*
numeric
);
char
*
getNextToken
(
char
*
s
,
char
*
token
,
int
smax
,
char
*
delim
,
char
*
quote
,
char
*
dquote
,
char
*
numeric
);
void
getColInfo
(
COL_INFO
*
col_info
,
FIELD_INFO
*
fi
,
int
k
);
void
getColInfo
(
COL_INFO
*
col_info
,
FIELD_INFO
*
fi
,
int
k
);
char
searchColInfo
(
COL_INFO
*
col_info
,
FIELD_INFO
*
fi
);
char
searchColInfo
(
COL_INFO
*
col_info
,
FIELD_INFO
*
fi
);
char
*
char
*
getNextToken
(
char
*
s
,
char
*
token
,
int
smax
,
char
*
delim
,
char
*
quote
,
char
*
dquote
,
char
*
numeric
)
getNextToken
(
char
*
s
,
char
*
token
,
int
smax
,
char
*
delim
,
char
*
quote
,
char
*
dquote
,
char
*
numeric
)
...
@@ -196,7 +196,7 @@ QR_set_field_info(stmt->result, 13, "FIELD_TYPE", PG_TYPE_INT4, 4);
...
@@ -196,7 +196,7 @@ QR_set_field_info(stmt->result, 13, "FIELD_TYPE", PG_TYPE_INT4, 4);
#endif
#endif
void
void
getColInfo
(
COL_INFO
*
col_info
,
FIELD_INFO
*
fi
,
int
k
)
getColInfo
(
COL_INFO
*
col_info
,
FIELD_INFO
*
fi
,
int
k
)
{
{
if
(
fi
->
name
[
0
]
==
'\0'
)
if
(
fi
->
name
[
0
]
==
'\0'
)
strcpy
(
fi
->
name
,
QR_get_value_manual
(
col_info
->
result
,
k
,
3
));
strcpy
(
fi
->
name
,
QR_get_value_manual
(
col_info
->
result
,
k
,
3
));
...
@@ -209,7 +209,7 @@ getColInfo(COL_INFO * col_info, FIELD_INFO * fi, int k)
...
@@ -209,7 +209,7 @@ getColInfo(COL_INFO * col_info, FIELD_INFO * fi, int k)
}
}
char
char
searchColInfo
(
COL_INFO
*
col_info
,
FIELD_INFO
*
fi
)
searchColInfo
(
COL_INFO
*
col_info
,
FIELD_INFO
*
fi
)
{
{
int
k
;
int
k
;
char
*
col
;
char
*
col
;
...
@@ -232,7 +232,7 @@ searchColInfo(COL_INFO * col_info, FIELD_INFO * fi)
...
@@ -232,7 +232,7 @@ searchColInfo(COL_INFO * col_info, FIELD_INFO * fi)
char
char
parse_statement
(
StatementClass
*
stmt
)
parse_statement
(
StatementClass
*
stmt
)
{
{
static
char
*
func
=
"parse_statement"
;
static
char
*
func
=
"parse_statement"
;
char
token
[
256
];
char
token
[
256
];
...
...
src/interfaces/odbc/pgtypes.c
View file @
26dc5014
...
@@ -38,7 +38,7 @@
...
@@ -38,7 +38,7 @@
extern
GLOBAL_VALUES
globals
;
extern
GLOBAL_VALUES
globals
;
Int4
getCharPrecision
(
StatementClass
*
stmt
,
Int4
type
,
int
col
,
int
handle_unknown_size_as
);
Int4
getCharPrecision
(
StatementClass
*
stmt
,
Int4
type
,
int
col
,
int
handle_unknown_size_as
);
/* these are the types we support. all of the pgtype_ functions should */
/* these are the types we support. all of the pgtype_ functions should */
...
@@ -194,7 +194,7 @@ sqltype_to_pgtype(SWORD fSqlType)
...
@@ -194,7 +194,7 @@ sqltype_to_pgtype(SWORD fSqlType)
types that are unknown. All other pg routines in here return a suitable default.
types that are unknown. All other pg routines in here return a suitable default.
*/
*/
Int2
Int2
pgtype_to_sqltype
(
StatementClass
*
stmt
,
Int4
type
)
pgtype_to_sqltype
(
StatementClass
*
stmt
,
Int4
type
)
{
{
switch
(
type
)
switch
(
type
)
{
{
...
@@ -267,7 +267,7 @@ pgtype_to_sqltype(StatementClass * stmt, Int4 type)
...
@@ -267,7 +267,7 @@ pgtype_to_sqltype(StatementClass * stmt, Int4 type)
}
}
Int2
Int2
pgtype_to_ctype
(
StatementClass
*
stmt
,
Int4
type
)
pgtype_to_ctype
(
StatementClass
*
stmt
,
Int4
type
)
{
{
switch
(
type
)
switch
(
type
)
{
{
...
@@ -314,7 +314,7 @@ pgtype_to_ctype(StatementClass * stmt, Int4 type)
...
@@ -314,7 +314,7 @@ pgtype_to_ctype(StatementClass * stmt, Int4 type)
}
}
char
*
char
*
pgtype_to_name
(
StatementClass
*
stmt
,
Int4
type
)
pgtype_to_name
(
StatementClass
*
stmt
,
Int4
type
)
{
{
switch
(
type
)
switch
(
type
)
{
{
...
@@ -381,7 +381,7 @@ pgtype_to_name(StatementClass * stmt, Int4 type)
...
@@ -381,7 +381,7 @@ pgtype_to_name(StatementClass * stmt, Int4 type)
}
}
static
Int2
static
Int2
getNumericScale
(
StatementClass
*
stmt
,
Int4
type
,
int
col
)
getNumericScale
(
StatementClass
*
stmt
,
Int4
type
,
int
col
)
{
{
Int4
atttypmod
;
Int4
atttypmod
;
QResultClass
*
result
;
QResultClass
*
result
;
...
@@ -417,7 +417,7 @@ getNumericScale(StatementClass * stmt, Int4 type, int col)
...
@@ -417,7 +417,7 @@ getNumericScale(StatementClass * stmt, Int4 type, int col)
}
}
static
Int4
static
Int4
getNumericPrecision
(
StatementClass
*
stmt
,
Int4
type
,
int
col
)
getNumericPrecision
(
StatementClass
*
stmt
,
Int4
type
,
int
col
)
{
{
Int4
atttypmod
;
Int4
atttypmod
;
QResultClass
*
result
;
QResultClass
*
result
;
...
@@ -453,7 +453,7 @@ getNumericPrecision(StatementClass * stmt, Int4 type, int col)
...
@@ -453,7 +453,7 @@ getNumericPrecision(StatementClass * stmt, Int4 type, int col)
}
}
Int4
Int4
getCharPrecision
(
StatementClass
*
stmt
,
Int4
type
,
int
col
,
int
handle_unknown_size_as
)
getCharPrecision
(
StatementClass
*
stmt
,
Int4
type
,
int
col
,
int
handle_unknown_size_as
)
{
{
int
p
=
-
1
,
int
p
=
-
1
,
maxsize
;
maxsize
;
...
@@ -530,7 +530,7 @@ getCharPrecision(StatementClass * stmt, Int4 type, int col, int handle_unknown_s
...
@@ -530,7 +530,7 @@ getCharPrecision(StatementClass * stmt, Int4 type, int col, int handle_unknown_s
This is used for functions SQLDescribeCol and SQLColAttributes.
This is used for functions SQLDescribeCol and SQLColAttributes.
*/
*/
Int4
Int4
pgtype_precision
(
StatementClass
*
stmt
,
Int4
type
,
int
col
,
int
handle_unknown_size_as
)
pgtype_precision
(
StatementClass
*
stmt
,
Int4
type
,
int
col
,
int
handle_unknown_size_as
)
{
{
switch
(
type
)
switch
(
type
)
{
{
...
@@ -595,7 +595,7 @@ pgtype_precision(StatementClass * stmt, Int4 type, int col, int handle_unknown_s
...
@@ -595,7 +595,7 @@ pgtype_precision(StatementClass * stmt, Int4 type, int col, int handle_unknown_s
}
}
Int4
Int4
pgtype_display_size
(
StatementClass
*
stmt
,
Int4
type
,
int
col
,
int
handle_unknown_size_as
)
pgtype_display_size
(
StatementClass
*
stmt
,
Int4
type
,
int
col
,
int
handle_unknown_size_as
)
{
{
switch
(
type
)
switch
(
type
)
{
{
...
@@ -634,7 +634,7 @@ pgtype_display_size(StatementClass * stmt, Int4 type, int col, int handle_unknow
...
@@ -634,7 +634,7 @@ pgtype_display_size(StatementClass * stmt, Int4 type, int col, int handle_unknow
override this length with the atttypmod length from pg_attribute
override this length with the atttypmod length from pg_attribute
*/
*/
Int4
Int4
pgtype_length
(
StatementClass
*
stmt
,
Int4
type
,
int
col
,
int
handle_unknown_size_as
)
pgtype_length
(
StatementClass
*
stmt
,
Int4
type
,
int
col
,
int
handle_unknown_size_as
)
{
{
switch
(
type
)
switch
(
type
)
{
{
...
@@ -676,7 +676,7 @@ pgtype_length(StatementClass * stmt, Int4 type, int col, int handle_unknown_size
...
@@ -676,7 +676,7 @@ pgtype_length(StatementClass * stmt, Int4 type, int col, int handle_unknown_size
}
}
Int2
Int2
pgtype_scale
(
StatementClass
*
stmt
,
Int4
type
,
int
col
)
pgtype_scale
(
StatementClass
*
stmt
,
Int4
type
,
int
col
)
{
{
switch
(
type
)
switch
(
type
)
{
{
...
@@ -709,7 +709,7 @@ pgtype_scale(StatementClass * stmt, Int4 type, int col)
...
@@ -709,7 +709,7 @@ pgtype_scale(StatementClass * stmt, Int4 type, int col)
Int2
Int2
pgtype_radix
(
StatementClass
*
stmt
,
Int4
type
)
pgtype_radix
(
StatementClass
*
stmt
,
Int4
type
)
{
{
switch
(
type
)
switch
(
type
)
{
{
...
@@ -729,13 +729,13 @@ pgtype_radix(StatementClass * stmt, Int4 type)
...
@@ -729,13 +729,13 @@ pgtype_radix(StatementClass * stmt, Int4 type)
}
}
Int2
Int2
pgtype_nullable
(
StatementClass
*
stmt
,
Int4
type
)
pgtype_nullable
(
StatementClass
*
stmt
,
Int4
type
)
{
{
return
SQL_NULLABLE
;
/* everything should be nullable */
return
SQL_NULLABLE
;
/* everything should be nullable */
}
}
Int2
Int2
pgtype_auto_increment
(
StatementClass
*
stmt
,
Int4
type
)
pgtype_auto_increment
(
StatementClass
*
stmt
,
Int4
type
)
{
{
switch
(
type
)
switch
(
type
)
{
{
...
@@ -763,7 +763,7 @@ pgtype_auto_increment(StatementClass * stmt, Int4 type)
...
@@ -763,7 +763,7 @@ pgtype_auto_increment(StatementClass * stmt, Int4 type)
}
}
Int2
Int2
pgtype_case_sensitive
(
StatementClass
*
stmt
,
Int4
type
)
pgtype_case_sensitive
(
StatementClass
*
stmt
,
Int4
type
)
{
{
switch
(
type
)
switch
(
type
)
{
{
...
@@ -785,7 +785,7 @@ pgtype_case_sensitive(StatementClass * stmt, Int4 type)
...
@@ -785,7 +785,7 @@ pgtype_case_sensitive(StatementClass * stmt, Int4 type)
}
}
Int2
Int2
pgtype_money
(
StatementClass
*
stmt
,
Int4
type
)
pgtype_money
(
StatementClass
*
stmt
,
Int4
type
)
{
{
switch
(
type
)
switch
(
type
)
{
{
...
@@ -797,7 +797,7 @@ pgtype_money(StatementClass * stmt, Int4 type)
...
@@ -797,7 +797,7 @@ pgtype_money(StatementClass * stmt, Int4 type)
}
}
Int2
Int2
pgtype_searchable
(
StatementClass
*
stmt
,
Int4
type
)
pgtype_searchable
(
StatementClass
*
stmt
,
Int4
type
)
{
{
switch
(
type
)
switch
(
type
)
{
{
...
@@ -818,7 +818,7 @@ pgtype_searchable(StatementClass * stmt, Int4 type)
...
@@ -818,7 +818,7 @@ pgtype_searchable(StatementClass * stmt, Int4 type)
}
}
Int2
Int2
pgtype_unsigned
(
StatementClass
*
stmt
,
Int4
type
)
pgtype_unsigned
(
StatementClass
*
stmt
,
Int4
type
)
{
{
switch
(
type
)
switch
(
type
)
{
{
...
@@ -841,7 +841,7 @@ pgtype_unsigned(StatementClass * stmt, Int4 type)
...
@@ -841,7 +841,7 @@ pgtype_unsigned(StatementClass * stmt, Int4 type)
}
}
char
*
char
*
pgtype_literal_prefix
(
StatementClass
*
stmt
,
Int4
type
)
pgtype_literal_prefix
(
StatementClass
*
stmt
,
Int4
type
)
{
{
switch
(
type
)
switch
(
type
)
{
{
...
@@ -861,7 +861,7 @@ pgtype_literal_prefix(StatementClass * stmt, Int4 type)
...
@@ -861,7 +861,7 @@ pgtype_literal_prefix(StatementClass * stmt, Int4 type)
}
}
char
*
char
*
pgtype_literal_suffix
(
StatementClass
*
stmt
,
Int4
type
)
pgtype_literal_suffix
(
StatementClass
*
stmt
,
Int4
type
)
{
{
switch
(
type
)
switch
(
type
)
{
{
...
@@ -881,7 +881,7 @@ pgtype_literal_suffix(StatementClass * stmt, Int4 type)
...
@@ -881,7 +881,7 @@ pgtype_literal_suffix(StatementClass * stmt, Int4 type)
}
}
char
*
char
*
pgtype_create_params
(
StatementClass
*
stmt
,
Int4
type
)
pgtype_create_params
(
StatementClass
*
stmt
,
Int4
type
)
{
{
switch
(
type
)
switch
(
type
)
{
{
...
...
src/interfaces/odbc/pgtypes.h
View file @
26dc5014
...
@@ -71,26 +71,26 @@ extern Int2 sqlTypes[];
...
@@ -71,26 +71,26 @@ extern Int2 sqlTypes[];
Int4
sqltype_to_pgtype
(
Int2
fSqlType
);
Int4
sqltype_to_pgtype
(
Int2
fSqlType
);
Int2
pgtype_to_sqltype
(
StatementClass
*
stmt
,
Int4
type
);
Int2
pgtype_to_sqltype
(
StatementClass
*
stmt
,
Int4
type
);
Int2
pgtype_to_ctype
(
StatementClass
*
stmt
,
Int4
type
);
Int2
pgtype_to_ctype
(
StatementClass
*
stmt
,
Int4
type
);
char
*
pgtype_to_name
(
StatementClass
*
stmt
,
Int4
type
);
char
*
pgtype_to_name
(
StatementClass
*
stmt
,
Int4
type
);
/* These functions can use static numbers or result sets(col parameter) */
/* These functions can use static numbers or result sets(col parameter) */
Int4
pgtype_precision
(
StatementClass
*
stmt
,
Int4
type
,
int
col
,
int
handle_unknown_size_as
);
Int4
pgtype_precision
(
StatementClass
*
stmt
,
Int4
type
,
int
col
,
int
handle_unknown_size_as
);
Int4
pgtype_display_size
(
StatementClass
*
stmt
,
Int4
type
,
int
col
,
int
handle_unknown_size_as
);
Int4
pgtype_display_size
(
StatementClass
*
stmt
,
Int4
type
,
int
col
,
int
handle_unknown_size_as
);
Int4
pgtype_length
(
StatementClass
*
stmt
,
Int4
type
,
int
col
,
int
handle_unknown_size_as
);
Int4
pgtype_length
(
StatementClass
*
stmt
,
Int4
type
,
int
col
,
int
handle_unknown_size_as
);
Int2
pgtype_scale
(
StatementClass
*
stmt
,
Int4
type
,
int
col
);
Int2
pgtype_scale
(
StatementClass
*
stmt
,
Int4
type
,
int
col
);
Int2
pgtype_radix
(
StatementClass
*
stmt
,
Int4
type
);
Int2
pgtype_radix
(
StatementClass
*
stmt
,
Int4
type
);
Int2
pgtype_nullable
(
StatementClass
*
stmt
,
Int4
type
);
Int2
pgtype_nullable
(
StatementClass
*
stmt
,
Int4
type
);
Int2
pgtype_auto_increment
(
StatementClass
*
stmt
,
Int4
type
);
Int2
pgtype_auto_increment
(
StatementClass
*
stmt
,
Int4
type
);
Int2
pgtype_case_sensitive
(
StatementClass
*
stmt
,
Int4
type
);
Int2
pgtype_case_sensitive
(
StatementClass
*
stmt
,
Int4
type
);
Int2
pgtype_money
(
StatementClass
*
stmt
,
Int4
type
);
Int2
pgtype_money
(
StatementClass
*
stmt
,
Int4
type
);
Int2
pgtype_searchable
(
StatementClass
*
stmt
,
Int4
type
);
Int2
pgtype_searchable
(
StatementClass
*
stmt
,
Int4
type
);
Int2
pgtype_unsigned
(
StatementClass
*
stmt
,
Int4
type
);
Int2
pgtype_unsigned
(
StatementClass
*
stmt
,
Int4
type
);
char
*
pgtype_literal_prefix
(
StatementClass
*
stmt
,
Int4
type
);
char
*
pgtype_literal_prefix
(
StatementClass
*
stmt
,
Int4
type
);
char
*
pgtype_literal_suffix
(
StatementClass
*
stmt
,
Int4
type
);
char
*
pgtype_literal_suffix
(
StatementClass
*
stmt
,
Int4
type
);
char
*
pgtype_create_params
(
StatementClass
*
stmt
,
Int4
type
);
char
*
pgtype_create_params
(
StatementClass
*
stmt
,
Int4
type
);
Int2
sqltype_to_default_ctype
(
Int2
sqltype
);
Int2
sqltype_to_default_ctype
(
Int2
sqltype
);
...
...
src/interfaces/odbc/psqlodbc.h
View file @
26dc5014
...
@@ -6,7 +6,7 @@
...
@@ -6,7 +6,7 @@
*
*
* Comments: See "notice.txt" for copyright and license information.
* Comments: See "notice.txt" for copyright and license information.
*
*
* $Id: psqlodbc.h,v 1.3
3 2001/02/11 02:01:22
momjian Exp $
* $Id: psqlodbc.h,v 1.3
4 2001/02/11 05:13:51
momjian Exp $
*/
*/
#ifndef __PSQLODBC_H__
#ifndef __PSQLODBC_H__
...
...
src/interfaces/odbc/qresult.c
View file @
26dc5014
...
@@ -34,7 +34,7 @@ extern GLOBAL_VALUES globals;
...
@@ -34,7 +34,7 @@ extern GLOBAL_VALUES globals;
/* Used for building a Manual Result only */
/* Used for building a Manual Result only */
/* All info functions call this function to create the manual result set. */
/* All info functions call this function to create the manual result set. */
void
void
QR_set_num_fields
(
QResultClass
*
self
,
int
new_num_fields
)
QR_set_num_fields
(
QResultClass
*
self
,
int
new_num_fields
)
{
{
mylog
(
"in QR_set_num_fields
\n
"
);
mylog
(
"in QR_set_num_fields
\n
"
);
...
@@ -48,25 +48,25 @@ QR_set_num_fields(QResultClass * self, int new_num_fields)
...
@@ -48,25 +48,25 @@ QR_set_num_fields(QResultClass * self, int new_num_fields)
}
}
void
void
QR_set_position
(
QResultClass
*
self
,
int
pos
)
QR_set_position
(
QResultClass
*
self
,
int
pos
)
{
{
self
->
tupleField
=
self
->
backend_tuples
+
((
self
->
base
+
pos
)
*
self
->
num_fields
);
self
->
tupleField
=
self
->
backend_tuples
+
((
self
->
base
+
pos
)
*
self
->
num_fields
);
}
}
void
void
QR_set_cache_size
(
QResultClass
*
self
,
int
cache_size
)
QR_set_cache_size
(
QResultClass
*
self
,
int
cache_size
)
{
{
self
->
cache_size
=
cache_size
;
self
->
cache_size
=
cache_size
;
}
}
void
void
QR_set_rowset_size
(
QResultClass
*
self
,
int
rowset_size
)
QR_set_rowset_size
(
QResultClass
*
self
,
int
rowset_size
)
{
{
self
->
rowset_size
=
rowset_size
;
self
->
rowset_size
=
rowset_size
;
}
}
void
void
QR_inc_base
(
QResultClass
*
self
,
int
base_inc
)
QR_inc_base
(
QResultClass
*
self
,
int
base_inc
)
{
{
self
->
base
+=
base_inc
;
self
->
base
+=
base_inc
;
}
}
...
@@ -117,7 +117,7 @@ QR_Constructor(void)
...
@@ -117,7 +117,7 @@ QR_Constructor(void)
}
}
void
void
QR_Destructor
(
QResultClass
*
self
)
QR_Destructor
(
QResultClass
*
self
)
{
{
mylog
(
"QResult: in DESTRUCTOR
\n
"
);
mylog
(
"QResult: in DESTRUCTOR
\n
"
);
...
@@ -154,7 +154,7 @@ QR_Destructor(QResultClass * self)
...
@@ -154,7 +154,7 @@ QR_Destructor(QResultClass * self)
}
}
void
void
QR_set_command
(
QResultClass
*
self
,
char
*
msg
)
QR_set_command
(
QResultClass
*
self
,
char
*
msg
)
{
{
if
(
self
->
command
)
if
(
self
->
command
)
free
(
self
->
command
);
free
(
self
->
command
);
...
@@ -163,7 +163,7 @@ QR_set_command(QResultClass * self, char *msg)
...
@@ -163,7 +163,7 @@ QR_set_command(QResultClass * self, char *msg)
}
}
void
void
QR_set_notice
(
QResultClass
*
self
,
char
*
msg
)
QR_set_notice
(
QResultClass
*
self
,
char
*
msg
)
{
{
if
(
self
->
notice
)
if
(
self
->
notice
)
free
(
self
->
notice
);
free
(
self
->
notice
);
...
@@ -172,7 +172,7 @@ QR_set_notice(QResultClass * self, char *msg)
...
@@ -172,7 +172,7 @@ QR_set_notice(QResultClass * self, char *msg)
}
}
void
void
QR_free_memory
(
QResultClass
*
self
)
QR_free_memory
(
QResultClass
*
self
)
{
{
register
int
lf
,
register
int
lf
,
row
;
row
;
...
@@ -209,7 +209,7 @@ QR_free_memory(QResultClass * self)
...
@@ -209,7 +209,7 @@ QR_free_memory(QResultClass * self)
/* This function is called by send_query() */
/* This function is called by send_query() */
char
char
QR_fetch_tuples
(
QResultClass
*
self
,
ConnectionClass
*
conn
,
char
*
cursor
)
QR_fetch_tuples
(
QResultClass
*
self
,
ConnectionClass
*
conn
,
char
*
cursor
)
{
{
int
tuple_size
;
int
tuple_size
;
...
@@ -297,7 +297,7 @@ QR_fetch_tuples(QResultClass * self, ConnectionClass * conn, char *cursor)
...
@@ -297,7 +297,7 @@ QR_fetch_tuples(QResultClass * self, ConnectionClass * conn, char *cursor)
/* Close the cursor and end the transaction (if no cursors left) */
/* Close the cursor and end the transaction (if no cursors left) */
/* We only close cursor/end the transaction if a cursor was used. */
/* We only close cursor/end the transaction if a cursor was used. */
int
int
QR_close
(
QResultClass
*
self
)
QR_close
(
QResultClass
*
self
)
{
{
QResultClass
*
res
;
QResultClass
*
res
;
...
@@ -346,7 +346,7 @@ QR_close(QResultClass * self)
...
@@ -346,7 +346,7 @@ QR_close(QResultClass * self)
/* This function is called by fetch_tuples() AND SQLFetch() */
/* This function is called by fetch_tuples() AND SQLFetch() */
int
int
QR_next_tuple
(
QResultClass
*
self
)
QR_next_tuple
(
QResultClass
*
self
)
{
{
int
id
;
int
id
;
QResultClass
*
res
;
QResultClass
*
res
;
...
@@ -573,7 +573,7 @@ QR_next_tuple(QResultClass * self)
...
@@ -573,7 +573,7 @@ QR_next_tuple(QResultClass * self)
}
}
char
char
QR_read_tuple
(
QResultClass
*
self
,
char
binary
)
QR_read_tuple
(
QResultClass
*
self
,
char
binary
)
{
{
Int2
field_lf
;
Int2
field_lf
;
TupleField
*
this_tuplefield
;
TupleField
*
this_tuplefield
;
...
...
src/interfaces/odbc/qresult.h
View file @
26dc5014
...
@@ -106,20 +106,20 @@ struct QResultClass_
...
@@ -106,20 +106,20 @@ struct QResultClass_
/* Core Functions */
/* Core Functions */
QResultClass
*
QR_Constructor
(
void
);
QResultClass
*
QR_Constructor
(
void
);
void
QR_Destructor
(
QResultClass
*
self
);
void
QR_Destructor
(
QResultClass
*
self
);
char
QR_read_tuple
(
QResultClass
*
self
,
char
binary
);
char
QR_read_tuple
(
QResultClass
*
self
,
char
binary
);
int
QR_next_tuple
(
QResultClass
*
self
);
int
QR_next_tuple
(
QResultClass
*
self
);
int
QR_close
(
QResultClass
*
self
);
int
QR_close
(
QResultClass
*
self
);
char
QR_fetch_tuples
(
QResultClass
*
self
,
ConnectionClass
*
conn
,
char
*
cursor
);
char
QR_fetch_tuples
(
QResultClass
*
self
,
ConnectionClass
*
conn
,
char
*
cursor
);
void
QR_free_memory
(
QResultClass
*
self
);
void
QR_free_memory
(
QResultClass
*
self
);
void
QR_set_command
(
QResultClass
*
self
,
char
*
msg
);
void
QR_set_command
(
QResultClass
*
self
,
char
*
msg
);
void
QR_set_notice
(
QResultClass
*
self
,
char
*
msg
);
void
QR_set_notice
(
QResultClass
*
self
,
char
*
msg
);
void
QR_set_num_fields
(
QResultClass
*
self
,
int
new_num_fields
);
/* manual result only */
void
QR_set_num_fields
(
QResultClass
*
self
,
int
new_num_fields
);
/* manual result only */
void
QR_inc_base
(
QResultClass
*
self
,
int
base_inc
);
void
QR_inc_base
(
QResultClass
*
self
,
int
base_inc
);
void
QR_set_cache_size
(
QResultClass
*
self
,
int
cache_size
);
void
QR_set_cache_size
(
QResultClass
*
self
,
int
cache_size
);
void
QR_set_rowset_size
(
QResultClass
*
self
,
int
rowset_size
);
void
QR_set_rowset_size
(
QResultClass
*
self
,
int
rowset_size
);
void
QR_set_position
(
QResultClass
*
self
,
int
pos
);
void
QR_set_position
(
QResultClass
*
self
,
int
pos
);
#endif
#endif
src/interfaces/odbc/results.c
View file @
26dc5014
...
@@ -46,7 +46,7 @@ extern GLOBAL_VALUES globals;
...
@@ -46,7 +46,7 @@ extern GLOBAL_VALUES globals;
RETCODE
SQL_API
RETCODE
SQL_API
SQLRowCount
(
SQLRowCount
(
HSTMT
hstmt
,
HSTMT
hstmt
,
SDWORD
FAR
*
pcrow
)
SDWORD
FAR
*
pcrow
)
{
{
static
char
*
func
=
"SQLRowCount"
;
static
char
*
func
=
"SQLRowCount"
;
StatementClass
*
stmt
=
(
StatementClass
*
)
hstmt
;
StatementClass
*
stmt
=
(
StatementClass
*
)
hstmt
;
...
@@ -116,7 +116,7 @@ SQLRowCount(
...
@@ -116,7 +116,7 @@ SQLRowCount(
RETCODE
SQL_API
RETCODE
SQL_API
SQLNumResultCols
(
SQLNumResultCols
(
HSTMT
hstmt
,
HSTMT
hstmt
,
SWORD
FAR
*
pccol
)
SWORD
FAR
*
pccol
)
{
{
static
char
*
func
=
"SQLNumResultCols"
;
static
char
*
func
=
"SQLNumResultCols"
;
StatementClass
*
stmt
=
(
StatementClass
*
)
hstmt
;
StatementClass
*
stmt
=
(
StatementClass
*
)
hstmt
;
...
@@ -180,13 +180,13 @@ RETCODE SQL_API
...
@@ -180,13 +180,13 @@ RETCODE SQL_API
SQLDescribeCol
(
SQLDescribeCol
(
HSTMT
hstmt
,
HSTMT
hstmt
,
UWORD
icol
,
UWORD
icol
,
UCHAR
FAR
*
szColName
,
UCHAR
FAR
*
szColName
,
SWORD
cbColNameMax
,
SWORD
cbColNameMax
,
SWORD
FAR
*
pcbColName
,
SWORD
FAR
*
pcbColName
,
SWORD
FAR
*
pfSqlType
,
SWORD
FAR
*
pfSqlType
,
UDWORD
FAR
*
pcbColDef
,
UDWORD
FAR
*
pcbColDef
,
SWORD
FAR
*
pibScale
,
SWORD
FAR
*
pibScale
,
SWORD
FAR
*
pfNullable
)
SWORD
FAR
*
pfNullable
)
{
{
static
char
*
func
=
"SQLDescribeCol"
;
static
char
*
func
=
"SQLDescribeCol"
;
...
@@ -382,8 +382,8 @@ SQLColAttributes(
...
@@ -382,8 +382,8 @@ SQLColAttributes(
UWORD
fDescType
,
UWORD
fDescType
,
PTR
rgbDesc
,
PTR
rgbDesc
,
SWORD
cbDescMax
,
SWORD
cbDescMax
,
SWORD
FAR
*
pcbDesc
,
SWORD
FAR
*
pcbDesc
,
SDWORD
FAR
*
pfDesc
)
SDWORD
FAR
*
pfDesc
)
{
{
static
char
*
func
=
"SQLColAttributes"
;
static
char
*
func
=
"SQLColAttributes"
;
StatementClass
*
stmt
=
(
StatementClass
*
)
hstmt
;
StatementClass
*
stmt
=
(
StatementClass
*
)
hstmt
;
...
@@ -658,7 +658,7 @@ SQLGetData(
...
@@ -658,7 +658,7 @@ SQLGetData(
SWORD
fCType
,
SWORD
fCType
,
PTR
rgbValue
,
PTR
rgbValue
,
SDWORD
cbValueMax
,
SDWORD
cbValueMax
,
SDWORD
FAR
*
pcbValue
)
SDWORD
FAR
*
pcbValue
)
{
{
static
char
*
func
=
"SQLGetData"
;
static
char
*
func
=
"SQLGetData"
;
QResultClass
*
res
;
QResultClass
*
res
;
...
@@ -911,8 +911,8 @@ SQLExtendedFetch(
...
@@ -911,8 +911,8 @@ SQLExtendedFetch(
HSTMT
hstmt
,
HSTMT
hstmt
,
UWORD
fFetchType
,
UWORD
fFetchType
,
SDWORD
irow
,
SDWORD
irow
,
UDWORD
FAR
*
pcrow
,
UDWORD
FAR
*
pcrow
,
UWORD
FAR
*
rgfRowStatus
)
UWORD
FAR
*
rgfRowStatus
)
{
{
static
char
*
func
=
"SQLExtendedFetch"
;
static
char
*
func
=
"SQLExtendedFetch"
;
StatementClass
*
stmt
=
(
StatementClass
*
)
hstmt
;
StatementClass
*
stmt
=
(
StatementClass
*
)
hstmt
;
...
@@ -1298,7 +1298,7 @@ SQLSetScrollOptions(
...
@@ -1298,7 +1298,7 @@ SQLSetScrollOptions(
RETCODE
SQL_API
RETCODE
SQL_API
SQLSetCursorName
(
SQLSetCursorName
(
HSTMT
hstmt
,
HSTMT
hstmt
,
UCHAR
FAR
*
szCursor
,
UCHAR
FAR
*
szCursor
,
SWORD
cbCursor
)
SWORD
cbCursor
)
{
{
static
char
*
func
=
"SQLSetCursorName"
;
static
char
*
func
=
"SQLSetCursorName"
;
...
@@ -1332,9 +1332,9 @@ SQLSetCursorName(
...
@@ -1332,9 +1332,9 @@ SQLSetCursorName(
RETCODE
SQL_API
RETCODE
SQL_API
SQLGetCursorName
(
SQLGetCursorName
(
HSTMT
hstmt
,
HSTMT
hstmt
,
UCHAR
FAR
*
szCursor
,
UCHAR
FAR
*
szCursor
,
SWORD
cbCursorMax
,
SWORD
cbCursorMax
,
SWORD
FAR
*
pcbCursor
)
SWORD
FAR
*
pcbCursor
)
{
{
static
char
*
func
=
"SQLGetCursorName"
;
static
char
*
func
=
"SQLGetCursorName"
;
StatementClass
*
stmt
=
(
StatementClass
*
)
hstmt
;
StatementClass
*
stmt
=
(
StatementClass
*
)
hstmt
;
...
...
src/interfaces/odbc/setup.c
View file @
26dc5014
...
@@ -50,7 +50,7 @@ typedef struct tagSETUPDLG
...
@@ -50,7 +50,7 @@ typedef struct tagSETUPDLG
char
szDSN
[
MAXDSNAME
];
/* Original data source name */
char
szDSN
[
MAXDSNAME
];
/* Original data source name */
BOOL
fNewDSN
;
/* New data source flag */
BOOL
fNewDSN
;
/* New data source flag */
BOOL
fDefault
;
/* Default data source flag */
BOOL
fDefault
;
/* Default data source flag */
}
SETUPDLG
,
FAR
*
LPSETUPDLG
;
}
SETUPDLG
,
FAR
*
LPSETUPDLG
;
...
@@ -323,7 +323,7 @@ ConfigDlgProc(HWND hdlg,
...
@@ -323,7 +323,7 @@ ConfigDlgProc(HWND hdlg,
lpsetupdlg
=
(
LPSETUPDLG
)
GetWindowLong
(
hdlg
,
DWL_USER
);
lpsetupdlg
=
(
LPSETUPDLG
)
GetWindowLong
(
hdlg
,
DWL_USER
);
DialogBoxParam
(
s_hModule
,
MAKEINTRESOURCE
(
DLG_OPTIONS_DS
),
DialogBoxParam
(
s_hModule
,
MAKEINTRESOURCE
(
DLG_OPTIONS_DS
),
hdlg
,
ds_optionsProc
,
(
LPARAM
)
&
lpsetupdlg
->
ci
);
hdlg
,
ds_optionsProc
,
(
LPARAM
)
&
lpsetupdlg
->
ci
);
return
TRUE
;
return
TRUE
;
}
}
...
...
src/interfaces/odbc/socket.c
View file @
26dc5014
...
@@ -36,7 +36,7 @@ extern GLOBAL_VALUES globals;
...
@@ -36,7 +36,7 @@ extern GLOBAL_VALUES globals;
void
void
SOCK_clear_error
(
SocketClass
*
self
)
SOCK_clear_error
(
SocketClass
*
self
)
{
{
self
->
errornumber
=
0
;
self
->
errornumber
=
0
;
self
->
errormsg
=
NULL
;
self
->
errormsg
=
NULL
;
...
@@ -73,7 +73,7 @@ SOCK_Constructor()
...
@@ -73,7 +73,7 @@ SOCK_Constructor()
}
}
void
void
SOCK_Destructor
(
SocketClass
*
self
)
SOCK_Destructor
(
SocketClass
*
self
)
{
{
if
(
self
->
socket
!=
-
1
)
if
(
self
->
socket
!=
-
1
)
{
{
...
@@ -98,7 +98,7 @@ SOCK_Destructor(SocketClass * self)
...
@@ -98,7 +98,7 @@ SOCK_Destructor(SocketClass * self)
char
char
SOCK_connect_to
(
SocketClass
*
self
,
unsigned
short
port
,
char
*
hostname
)
SOCK_connect_to
(
SocketClass
*
self
,
unsigned
short
port
,
char
*
hostname
)
{
{
struct
hostent
*
host
;
struct
hostent
*
host
;
struct
sockaddr_in
sadr
;
struct
sockaddr_in
sadr
;
...
@@ -156,7 +156,7 @@ SOCK_connect_to(SocketClass * self, unsigned short port, char *hostname)
...
@@ -156,7 +156,7 @@ SOCK_connect_to(SocketClass * self, unsigned short port, char *hostname)
void
void
SOCK_get_n_char
(
SocketClass
*
self
,
char
*
buffer
,
int
len
)
SOCK_get_n_char
(
SocketClass
*
self
,
char
*
buffer
,
int
len
)
{
{
int
lf
;
int
lf
;
...
@@ -173,7 +173,7 @@ SOCK_get_n_char(SocketClass * self, char *buffer, int len)
...
@@ -173,7 +173,7 @@ SOCK_get_n_char(SocketClass * self, char *buffer, int len)
void
void
SOCK_put_n_char
(
SocketClass
*
self
,
char
*
buffer
,
int
len
)
SOCK_put_n_char
(
SocketClass
*
self
,
char
*
buffer
,
int
len
)
{
{
int
lf
;
int
lf
;
...
@@ -193,7 +193,7 @@ SOCK_put_n_char(SocketClass * self, char *buffer, int len)
...
@@ -193,7 +193,7 @@ SOCK_put_n_char(SocketClass * self, char *buffer, int len)
will read at most bufsize-1 characters + null.
will read at most bufsize-1 characters + null.
*/
*/
void
void
SOCK_get_string
(
SocketClass
*
self
,
char
*
buffer
,
int
bufsize
)
SOCK_get_string
(
SocketClass
*
self
,
char
*
buffer
,
int
bufsize
)
{
{
register
int
lf
=
0
;
register
int
lf
=
0
;
...
@@ -206,7 +206,7 @@ SOCK_get_string(SocketClass * self, char *buffer, int bufsize)
...
@@ -206,7 +206,7 @@ SOCK_get_string(SocketClass * self, char *buffer, int bufsize)
void
void
SOCK_put_string
(
SocketClass
*
self
,
char
*
string
)
SOCK_put_string
(
SocketClass
*
self
,
char
*
string
)
{
{
register
int
lf
;
register
int
lf
;
int
len
;
int
len
;
...
@@ -219,7 +219,7 @@ SOCK_put_string(SocketClass * self, char *string)
...
@@ -219,7 +219,7 @@ SOCK_put_string(SocketClass * self, char *string)
int
int
SOCK_get_int
(
SocketClass
*
self
,
short
len
)
SOCK_get_int
(
SocketClass
*
self
,
short
len
)
{
{
char
buf
[
4
];
char
buf
[
4
];
...
@@ -248,7 +248,7 @@ SOCK_get_int(SocketClass * self, short len)
...
@@ -248,7 +248,7 @@ SOCK_get_int(SocketClass * self, short len)
void
void
SOCK_put_int
(
SocketClass
*
self
,
int
value
,
short
len
)
SOCK_put_int
(
SocketClass
*
self
,
int
value
,
short
len
)
{
{
unsigned
int
rv
;
unsigned
int
rv
;
...
@@ -273,7 +273,7 @@ SOCK_put_int(SocketClass * self, int value, short len)
...
@@ -273,7 +273,7 @@ SOCK_put_int(SocketClass * self, int value, short len)
void
void
SOCK_flush_output
(
SocketClass
*
self
)
SOCK_flush_output
(
SocketClass
*
self
)
{
{
int
written
;
int
written
;
...
@@ -287,7 +287,7 @@ SOCK_flush_output(SocketClass * self)
...
@@ -287,7 +287,7 @@ SOCK_flush_output(SocketClass * self)
}
}
unsigned
char
unsigned
char
SOCK_get_next_byte
(
SocketClass
*
self
)
SOCK_get_next_byte
(
SocketClass
*
self
)
{
{
if
(
self
->
buffer_read_in
>=
self
->
buffer_filled_in
)
if
(
self
->
buffer_read_in
>=
self
->
buffer_filled_in
)
{
{
...
@@ -316,7 +316,7 @@ SOCK_get_next_byte(SocketClass * self)
...
@@ -316,7 +316,7 @@ SOCK_get_next_byte(SocketClass * self)
}
}
void
void
SOCK_put_next_byte
(
SocketClass
*
self
,
unsigned
char
next_byte
)
SOCK_put_next_byte
(
SocketClass
*
self
,
unsigned
char
next_byte
)
{
{
int
bytes_sent
;
int
bytes_sent
;
...
...
src/interfaces/odbc/socket.h
View file @
26dc5014
...
@@ -83,17 +83,17 @@ struct SocketClass_
...
@@ -83,17 +83,17 @@ struct SocketClass_
/* Socket prototypes */
/* Socket prototypes */
SocketClass
*
SOCK_Constructor
(
void
);
SocketClass
*
SOCK_Constructor
(
void
);
void
SOCK_Destructor
(
SocketClass
*
self
);
void
SOCK_Destructor
(
SocketClass
*
self
);
char
SOCK_connect_to
(
SocketClass
*
self
,
unsigned
short
port
,
char
*
hostname
);
char
SOCK_connect_to
(
SocketClass
*
self
,
unsigned
short
port
,
char
*
hostname
);
void
SOCK_get_n_char
(
SocketClass
*
self
,
char
*
buffer
,
int
len
);
void
SOCK_get_n_char
(
SocketClass
*
self
,
char
*
buffer
,
int
len
);
void
SOCK_put_n_char
(
SocketClass
*
self
,
char
*
buffer
,
int
len
);
void
SOCK_put_n_char
(
SocketClass
*
self
,
char
*
buffer
,
int
len
);
void
SOCK_get_string
(
SocketClass
*
self
,
char
*
buffer
,
int
bufsize
);
void
SOCK_get_string
(
SocketClass
*
self
,
char
*
buffer
,
int
bufsize
);
void
SOCK_put_string
(
SocketClass
*
self
,
char
*
string
);
void
SOCK_put_string
(
SocketClass
*
self
,
char
*
string
);
int
SOCK_get_int
(
SocketClass
*
self
,
short
len
);
int
SOCK_get_int
(
SocketClass
*
self
,
short
len
);
void
SOCK_put_int
(
SocketClass
*
self
,
int
value
,
short
len
);
void
SOCK_put_int
(
SocketClass
*
self
,
int
value
,
short
len
);
void
SOCK_flush_output
(
SocketClass
*
self
);
void
SOCK_flush_output
(
SocketClass
*
self
);
unsigned
char
SOCK_get_next_byte
(
SocketClass
*
self
);
unsigned
char
SOCK_get_next_byte
(
SocketClass
*
self
);
void
SOCK_put_next_byte
(
SocketClass
*
self
,
unsigned
char
next_byte
);
void
SOCK_put_next_byte
(
SocketClass
*
self
,
unsigned
char
next_byte
);
void
SOCK_clear_error
(
SocketClass
*
self
);
void
SOCK_clear_error
(
SocketClass
*
self
);
#endif
#endif
src/interfaces/odbc/statement.c
View file @
26dc5014
...
@@ -87,7 +87,7 @@ static struct
...
@@ -87,7 +87,7 @@ static struct
RETCODE
SQL_API
RETCODE
SQL_API
SQLAllocStmt
(
HDBC
hdbc
,
SQLAllocStmt
(
HDBC
hdbc
,
HSTMT
FAR
*
phstmt
)
HSTMT
FAR
*
phstmt
)
{
{
static
char
*
func
=
"SQLAllocStmt"
;
static
char
*
func
=
"SQLAllocStmt"
;
ConnectionClass
*
conn
=
(
ConnectionClass
*
)
hdbc
;
ConnectionClass
*
conn
=
(
ConnectionClass
*
)
hdbc
;
...
@@ -213,7 +213,7 @@ SQLFreeStmt(HSTMT hstmt,
...
@@ -213,7 +213,7 @@ SQLFreeStmt(HSTMT hstmt,
* StatementClass implementation
* StatementClass implementation
*/
*/
void
void
InitializeStatementOptions
(
StatementOptions
*
opt
)
InitializeStatementOptions
(
StatementOptions
*
opt
)
{
{
opt
->
maxRows
=
0
;
/* driver returns all rows */
opt
->
maxRows
=
0
;
/* driver returns all rows */
opt
->
maxLength
=
0
;
/* driver returns all data for char/binary */
opt
->
maxLength
=
0
;
/* driver returns all data for char/binary */
...
@@ -288,7 +288,7 @@ SC_Constructor(void)
...
@@ -288,7 +288,7 @@ SC_Constructor(void)
}
}
char
char
SC_Destructor
(
StatementClass
*
self
)
SC_Destructor
(
StatementClass
*
self
)
{
{
mylog
(
"SC_Destructor: self=%u, self->result=%u, self->hdbc=%u
\n
"
,
self
,
self
->
result
,
self
->
hdbc
);
mylog
(
"SC_Destructor: self=%u, self->result=%u, self->hdbc=%u
\n
"
,
self
,
self
->
result
,
self
->
hdbc
);
if
(
STMT_EXECUTING
==
self
->
status
)
if
(
STMT_EXECUTING
==
self
->
status
)
...
@@ -358,7 +358,7 @@ SC_Destructor(StatementClass * self)
...
@@ -358,7 +358,7 @@ SC_Destructor(StatementClass * self)
data-at-execution parameters that was allocated in SQLPutData.
data-at-execution parameters that was allocated in SQLPutData.
*/
*/
void
void
SC_free_params
(
StatementClass
*
self
,
char
option
)
SC_free_params
(
StatementClass
*
self
,
char
option
)
{
{
int
i
;
int
i
;
...
@@ -422,7 +422,7 @@ statement_type(char *statement)
...
@@ -422,7 +422,7 @@ statement_type(char *statement)
from SQLFreeStmt(SQL_CLOSE)
from SQLFreeStmt(SQL_CLOSE)
*/
*/
char
char
SC_recycle_statement
(
StatementClass
*
self
)
SC_recycle_statement
(
StatementClass
*
self
)
{
{
ConnectionClass
*
conn
;
ConnectionClass
*
conn
;
...
@@ -535,7 +535,7 @@ SC_recycle_statement(StatementClass * self)
...
@@ -535,7 +535,7 @@ SC_recycle_statement(StatementClass * self)
/* Pre-execute a statement (SQLPrepare/SQLDescribeCol) */
/* Pre-execute a statement (SQLPrepare/SQLDescribeCol) */
void
void
SC_pre_execute
(
StatementClass
*
self
)
SC_pre_execute
(
StatementClass
*
self
)
{
{
mylog
(
"SC_pre_execute: status = %d
\n
"
,
self
->
status
);
mylog
(
"SC_pre_execute: status = %d
\n
"
,
self
->
status
);
...
@@ -555,7 +555,7 @@ SC_pre_execute(StatementClass * self)
...
@@ -555,7 +555,7 @@ SC_pre_execute(StatementClass * self)
/* This is only called from SQLFreeStmt(SQL_UNBIND) */
/* This is only called from SQLFreeStmt(SQL_UNBIND) */
char
char
SC_unbind_cols
(
StatementClass
*
self
)
SC_unbind_cols
(
StatementClass
*
self
)
{
{
Int2
lf
;
Int2
lf
;
...
@@ -575,7 +575,7 @@ SC_unbind_cols(StatementClass * self)
...
@@ -575,7 +575,7 @@ SC_unbind_cols(StatementClass * self)
}
}
void
void
SC_clear_error
(
StatementClass
*
self
)
SC_clear_error
(
StatementClass
*
self
)
{
{
self
->
errornumber
=
0
;
self
->
errornumber
=
0
;
self
->
errormsg
=
NULL
;
self
->
errormsg
=
NULL
;
...
@@ -586,7 +586,7 @@ SC_clear_error(StatementClass * self)
...
@@ -586,7 +586,7 @@ SC_clear_error(StatementClass * self)
/* This function creates an error msg which is the concatenation */
/* This function creates an error msg which is the concatenation */
/* of the result, statement, connection, and socket messages. */
/* of the result, statement, connection, and socket messages. */
char
*
char
*
SC_create_errormsg
(
StatementClass
*
self
)
SC_create_errormsg
(
StatementClass
*
self
)
{
{
QResultClass
*
res
=
self
->
result
;
QResultClass
*
res
=
self
->
result
;
ConnectionClass
*
conn
=
self
->
hdbc
;
ConnectionClass
*
conn
=
self
->
hdbc
;
...
@@ -622,7 +622,7 @@ SC_create_errormsg(StatementClass * self)
...
@@ -622,7 +622,7 @@ SC_create_errormsg(StatementClass * self)
}
}
char
char
SC_get_error
(
StatementClass
*
self
,
int
*
number
,
char
**
message
)
SC_get_error
(
StatementClass
*
self
,
int
*
number
,
char
**
message
)
{
{
char
rv
;
char
rv
;
...
@@ -651,13 +651,13 @@ SC_get_error(StatementClass * self, int *number, char **message)
...
@@ -651,13 +651,13 @@ SC_get_error(StatementClass * self, int *number, char **message)
someday, such as mapping a key to a 32 bit value
someday, such as mapping a key to a 32 bit value
*/
*/
unsigned
long
unsigned
long
SC_get_bookmark
(
StatementClass
*
self
)
SC_get_bookmark
(
StatementClass
*
self
)
{
{
return
(
self
->
currTuple
+
1
);
return
(
self
->
currTuple
+
1
);
}
}
RETCODE
RETCODE
SC_fetch
(
StatementClass
*
self
)
SC_fetch
(
StatementClass
*
self
)
{
{
static
char
*
func
=
"SC_fetch"
;
static
char
*
func
=
"SC_fetch"
;
QResultClass
*
res
=
self
->
result
;
QResultClass
*
res
=
self
->
result
;
...
@@ -817,7 +817,7 @@ SC_fetch(StatementClass * self)
...
@@ -817,7 +817,7 @@ SC_fetch(StatementClass * self)
RETCODE
RETCODE
SC_execute
(
StatementClass
*
self
)
SC_execute
(
StatementClass
*
self
)
{
{
static
char
*
func
=
"SC_execute"
;
static
char
*
func
=
"SC_execute"
;
ConnectionClass
*
conn
;
ConnectionClass
*
conn
;
...
@@ -1024,7 +1024,7 @@ SC_execute(StatementClass * self)
...
@@ -1024,7 +1024,7 @@ SC_execute(StatementClass * self)
}
}
void
void
SC_log_error
(
char
*
func
,
char
*
desc
,
StatementClass
*
self
)
SC_log_error
(
char
*
func
,
char
*
desc
,
StatementClass
*
self
)
{
{
#ifdef PRN_NULLCHECK
#ifdef PRN_NULLCHECK
#define nullcheck(a) (a ? a : "(NULL)")
#define nullcheck(a) (a ? a : "(NULL)")
...
...
src/interfaces/odbc/statement.h
View file @
26dc5014
...
@@ -224,22 +224,22 @@ struct StatementClass_
...
@@ -224,22 +224,22 @@ struct StatementClass_
/* Statement prototypes */
/* Statement prototypes */
StatementClass
*
SC_Constructor
(
void
);
StatementClass
*
SC_Constructor
(
void
);
void
InitializeStatementOptions
(
StatementOptions
*
opt
);
void
InitializeStatementOptions
(
StatementOptions
*
opt
);
char
SC_Destructor
(
StatementClass
*
self
);
char
SC_Destructor
(
StatementClass
*
self
);
int
statement_type
(
char
*
statement
);
int
statement_type
(
char
*
statement
);
char
parse_statement
(
StatementClass
*
stmt
);
char
parse_statement
(
StatementClass
*
stmt
);
void
SC_pre_execute
(
StatementClass
*
self
);
void
SC_pre_execute
(
StatementClass
*
self
);
char
SC_unbind_cols
(
StatementClass
*
self
);
char
SC_unbind_cols
(
StatementClass
*
self
);
char
SC_recycle_statement
(
StatementClass
*
self
);
char
SC_recycle_statement
(
StatementClass
*
self
);
void
SC_clear_error
(
StatementClass
*
self
);
void
SC_clear_error
(
StatementClass
*
self
);
char
SC_get_error
(
StatementClass
*
self
,
int
*
number
,
char
**
message
);
char
SC_get_error
(
StatementClass
*
self
,
int
*
number
,
char
**
message
);
char
*
SC_create_errormsg
(
StatementClass
*
self
);
char
*
SC_create_errormsg
(
StatementClass
*
self
);
RETCODE
SC_execute
(
StatementClass
*
self
);
RETCODE
SC_execute
(
StatementClass
*
self
);
RETCODE
SC_fetch
(
StatementClass
*
self
);
RETCODE
SC_fetch
(
StatementClass
*
self
);
void
SC_free_params
(
StatementClass
*
self
,
char
option
);
void
SC_free_params
(
StatementClass
*
self
,
char
option
);
void
SC_log_error
(
char
*
func
,
char
*
desc
,
StatementClass
*
self
);
void
SC_log_error
(
char
*
func
,
char
*
desc
,
StatementClass
*
self
);
unsigned
long
SC_get_bookmark
(
StatementClass
*
self
);
unsigned
long
SC_get_bookmark
(
StatementClass
*
self
);
#endif
#endif
src/interfaces/odbc/tuple.c
View file @
26dc5014
...
@@ -19,14 +19,14 @@
...
@@ -19,14 +19,14 @@
#include <stdlib.h>
#include <stdlib.h>
void
void
set_tuplefield_null
(
TupleField
*
tuple_field
)
set_tuplefield_null
(
TupleField
*
tuple_field
)
{
{
tuple_field
->
len
=
0
;
tuple_field
->
len
=
0
;
tuple_field
->
value
=
NULL
;
/* strdup(""); */
tuple_field
->
value
=
NULL
;
/* strdup(""); */
}
}
void
void
set_tuplefield_string
(
TupleField
*
tuple_field
,
char
*
string
)
set_tuplefield_string
(
TupleField
*
tuple_field
,
char
*
string
)
{
{
tuple_field
->
len
=
strlen
(
string
);
tuple_field
->
len
=
strlen
(
string
);
tuple_field
->
value
=
malloc
(
strlen
(
string
)
+
1
);
tuple_field
->
value
=
malloc
(
strlen
(
string
)
+
1
);
...
@@ -35,7 +35,7 @@ set_tuplefield_string(TupleField * tuple_field, char *string)
...
@@ -35,7 +35,7 @@ set_tuplefield_string(TupleField * tuple_field, char *string)
void
void
set_tuplefield_int2
(
TupleField
*
tuple_field
,
Int2
value
)
set_tuplefield_int2
(
TupleField
*
tuple_field
,
Int2
value
)
{
{
char
buffer
[
10
];
char
buffer
[
10
];
...
@@ -48,7 +48,7 @@ set_tuplefield_int2(TupleField * tuple_field, Int2 value)
...
@@ -48,7 +48,7 @@ set_tuplefield_int2(TupleField * tuple_field, Int2 value)
}
}
void
void
set_tuplefield_int4
(
TupleField
*
tuple_field
,
Int4
value
)
set_tuplefield_int4
(
TupleField
*
tuple_field
,
Int4
value
)
{
{
char
buffer
[
15
];
char
buffer
[
15
];
...
...
src/interfaces/odbc/tuple.h
View file @
26dc5014
...
@@ -39,9 +39,9 @@ struct TupleNode_
...
@@ -39,9 +39,9 @@ struct TupleNode_
#define set_nullfield_int2(FLD, VAL) ((VAL) != -1 ? set_tuplefield_int2(FLD, (VAL)) : set_tuplefield_null(FLD))
#define set_nullfield_int2(FLD, VAL) ((VAL) != -1 ? set_tuplefield_int2(FLD, (VAL)) : set_tuplefield_null(FLD))
#define set_nullfield_int4(FLD, VAL) ((VAL) != -1 ? set_tuplefield_int4(FLD, (VAL)) : set_tuplefield_null(FLD))
#define set_nullfield_int4(FLD, VAL) ((VAL) != -1 ? set_tuplefield_int4(FLD, (VAL)) : set_tuplefield_null(FLD))
void
set_tuplefield_null
(
TupleField
*
tuple_field
);
void
set_tuplefield_null
(
TupleField
*
tuple_field
);
void
set_tuplefield_string
(
TupleField
*
tuple_field
,
char
*
string
);
void
set_tuplefield_string
(
TupleField
*
tuple_field
,
char
*
string
);
void
set_tuplefield_int2
(
TupleField
*
tuple_field
,
Int2
value
);
void
set_tuplefield_int2
(
TupleField
*
tuple_field
,
Int2
value
);
void
set_tuplefield_int4
(
TupleField
*
tuple_field
,
Int4
value
);
void
set_tuplefield_int4
(
TupleField
*
tuple_field
,
Int4
value
);
#endif
#endif
src/interfaces/odbc/tuplelist.c
View file @
26dc5014
...
@@ -39,7 +39,7 @@ TL_Constructor(UInt4 fieldcnt)
...
@@ -39,7 +39,7 @@ TL_Constructor(UInt4 fieldcnt)
}
}
void
void
TL_Destructor
(
TupleListClass
*
self
)
TL_Destructor
(
TupleListClass
*
self
)
{
{
int
lf
;
int
lf
;
TupleNode
*
node
,
TupleNode
*
node
,
...
@@ -65,7 +65,7 @@ TL_Destructor(TupleListClass * self)
...
@@ -65,7 +65,7 @@ TL_Destructor(TupleListClass * self)
void
*
void
*
TL_get_fieldval
(
TupleListClass
*
self
,
Int4
tupleno
,
Int2
fieldno
)
TL_get_fieldval
(
TupleListClass
*
self
,
Int4
tupleno
,
Int2
fieldno
)
{
{
Int4
lf
;
Int4
lf
;
Int4
delta
,
Int4
delta
,
...
@@ -178,7 +178,7 @@ TL_get_fieldval(TupleListClass * self, Int4 tupleno, Int2 fieldno)
...
@@ -178,7 +178,7 @@ TL_get_fieldval(TupleListClass * self, Int4 tupleno, Int2 fieldno)
char
char
TL_add_tuple
(
TupleListClass
*
self
,
TupleNode
*
new_field
)
TL_add_tuple
(
TupleListClass
*
self
,
TupleNode
*
new_field
)
{
{
/*
/*
...
...
src/interfaces/odbc/tuplelist.h
View file @
26dc5014
...
@@ -29,8 +29,8 @@ struct TupleListClass_
...
@@ -29,8 +29,8 @@ struct TupleListClass_
/* Create a TupleList. Each tuple consits of fieldcnt columns */
/* Create a TupleList. Each tuple consits of fieldcnt columns */
TupleListClass
*
TL_Constructor
(
UInt4
fieldcnt
);
TupleListClass
*
TL_Constructor
(
UInt4
fieldcnt
);
void
TL_Destructor
(
TupleListClass
*
self
);
void
TL_Destructor
(
TupleListClass
*
self
);
void
*
TL_get_fieldval
(
TupleListClass
*
self
,
Int4
tupleno
,
Int2
fieldno
);
void
*
TL_get_fieldval
(
TupleListClass
*
self
,
Int4
tupleno
,
Int2
fieldno
);
char
TL_add_tuple
(
TupleListClass
*
self
,
TupleNode
*
new_field
);
char
TL_add_tuple
(
TupleListClass
*
self
,
TupleNode
*
new_field
);
#endif
#endif
src/tools/pgindent/pgindent
View file @
26dc5014
...
@@ -36,6 +36,7 @@ do
...
@@ -36,6 +36,7 @@ do
# We get the list of typedef's from /src/tools/find_typedef
# We get the list of typedef's from /src/tools/find_typedef
indent
-bad
-bap
-bc
-bl
-d0
-cdb
-nce
-nfc1
-di12
-i4
-l75
\
indent
-bad
-bap
-bc
-bl
-d0
-cdb
-nce
-nfc1
-di12
-i4
-l75
\
-lp
-nip
-npro
$EXTRA_OPTS
\
-lp
-nip
-npro
$EXTRA_OPTS
\
-TFAR
\
-TA_Const
\
-TA_Const
\
-TA_Expr
\
-TA_Expr
\
-TA_Indices
\
-TA_Indices
\
...
@@ -55,17 +56,21 @@ do
...
@@ -55,17 +56,21 @@ do
-TAllocBlockData
\
-TAllocBlockData
\
-TAllocChunk
\
-TAllocChunk
\
-TAllocChunkData
\
-TAllocChunkData
\
-TAllocMode
\
-TAllocPointer
\
-TAllocPointer
\
-TAllocSet
\
-TAllocSet
\
-TAllocSet
Data
\
-TAllocSet
Context
\
-TAlterGroupStmt
\
-TAlterGroupStmt
\
-TAlterTableStmt
\
-TAlterTableStmt
\
-TAlterUserStmt
\
-TAlterUserStmt
\
-TAnyInvalidation
\
-TAnyInvalidation
\
-TAppend
\
-TAppend
\
-TAppendPath
\
-TAppendState
\
-TAppendState
\
-TArray
\
-TArchive
\
-TArchiveEntryPtr
\
-TArchiveFormat
\
-TArchiveHandle
\
-TArchiveMode
\
-TArrayRef
\
-TArrayRef
\
-TArrayType
\
-TArrayType
\
-TAtom
\
-TAtom
\
...
@@ -74,6 +79,8 @@ do
...
@@ -74,6 +79,8 @@ do
-TAttrNumber
\
-TAttrNumber
\
-TAuthRequest
\
-TAuthRequest
\
-TAuthRequestPacket
\
-TAuthRequestPacket
\
-TBOOKMARK
\
-TBOOL
\
-TBOX
\
-TBOX
\
-TBTItem
\
-TBTItem
\
-TBTItemData
\
-TBTItemData
\
...
@@ -89,28 +96,32 @@ do
...
@@ -89,28 +96,32 @@ do
-TBTStack
\
-TBTStack
\
-TBTStackData
\
-TBTStackData
\
-TBUCKET_INDEX
\
-TBUCKET_INDEX
\
-TBYTE
\
-TBackend
\
-TBackend
\
-TBackendId
\
-TBackendId
\
-TB
ackendTag
\
-TB
indInfoClass
\
-TBitArray
\
-TBitArray
\
-TBitIndex
\
-TBitIndex
\
-TBkpBlock
\
-TBlock
\
-TBlock
\
-TBlockId
\
-TBlockId
\
-TBlockIdData
\
-TBlockIdData
\
-TBlockNumber
\
-TBlockNumber
\
-TBoolPtr
\
-TBoolPtr
\
-TBpChar
\
-TBucket
\
-TBucket
\
-TBufFile
\
-TBufFile
\
-TBufFlags
\
-TBufFlags
\
-TBuffer
\
-TBuffer
\
-TBufferBl
ock
\
-TBufferBl
indId
\
-TBufferDesc
\
-TBufferDesc
\
-TBufferLock
\
-TBufferTag
\
-TBufferTag
\
-TByte
\
-TBytef
\
-TCATEGORY
\
-TCATEGORY
\
-TCCHashFunc
\
-TCHUNK_INFO
\
-TCIRCLE
\
-TCIRCLE
\
-TCOL_INFO
\
-TCONN_Status
\
-TCPFunction
\
-TCPFunction
\
-TCPPFunction
\
-TCPPFunction
\
-TCancelRequestPacket
\
-TCancelRequestPacket
\
...
@@ -124,20 +135,25 @@ do
...
@@ -124,20 +135,25 @@ do
-TChangeACLStmt
\
-TChangeACLStmt
\
-TChangeVarNodes_context
\
-TChangeVarNodes_context
\
-TCheckPoint
\
-TCheckPoint
\
-TCheckPointStmt
\
-TChromosome
\
-TChromosome
\
-TCity
\
-TCity
\
-TClientData
\
-TClientData
\
-TClosePortalStmt
\
-TClosePortalStmt
\
-TClosePtr
\
-TClusterStmt
\
-TClusterStmt
\
-TCmdType
\
-TCmdType
\
-TColormap
\
-TColormap
\
-TColumnDef
\
-TColumnDef
\
-TColumnInfoClass
\
-TCommandDest
\
-TCommandDest
\
-TCommandId
\
-TCommandId
\
-TCommentStmt
\
-TCommentStmt
\
-TCommonScanState
\
-TCommonScanState
\
-TCommonState
\
-TCommonState
\
-TConnInfo
\
-TConnStatusType
\
-TConnStatusType
\
-TConnectionClass
\
-TConst
\
-TConst
\
-TConstrCheck
\
-TConstrCheck
\
-TConstrType
\
-TConstrType
\
...
@@ -155,11 +171,16 @@ do
...
@@ -155,11 +171,16 @@ do
-TCreateUserStmt
\
-TCreateUserStmt
\
-TCreatedbStmt
\
-TCreatedbStmt
\
-TCursor
\
-TCursor
\
-TCustomOutPtr
\
-TDATE_STRUCT
\
-TDBState
\
-TDBState
\
-TDCHCacheEntry
\
-TDCHCacheEntry
\
-TDCH_poz
\
-TDCH_poz
\
-TDIR
\
-TDIR
\
-TDR_printtup
\
-TDR_printtup
\
-TDWORD
\
-TDataDumperPtr
\
-TDataSourceToDriverProc
\
-TDateADT
\
-TDateADT
\
-TDatum
\
-TDatum
\
-TDatumPtr
\
-TDatumPtr
\
...
@@ -179,16 +200,23 @@ do
...
@@ -179,16 +200,23 @@ do
-TDlelem
\
-TDlelem
\
-TDllist
\
-TDllist
\
-TDrawable
\
-TDrawable
\
-TDriverToDataSourceProc
\
-TDropGroupStmt
\
-TDropGroupStmt
\
-TDropPLangStmt
\
-TDropPLangStmt
\
-TDropStmt
\
-TDropStmt
\
-TDropTrigStmt
\
-TDropTrigStmt
\
-TDropUserStmt
\
-TDropUserStmt
\
-TDropdbStmt
\
-TDropdbStmt
\
-TDumpContext
\
-TDynamicFileList
\
-TDynamicFileList
\
-TEDGE
\
-TELEMENT
\
-TELEMENT
\
-TEState
\
-TEState
\
-TEdge
\
-TEdge
\
-TEndBlobPtr
\
-TEndBlobsPtr
\
-TEndDataPtr
\
-TEnvironmentClass
\
-TErrorMessagePacket
\
-TErrorMessagePacket
\
-TExcContext
\
-TExcContext
\
-TExcData
\
-TExcData
\
...
@@ -198,28 +226,28 @@ do
...
@@ -198,28 +226,28 @@ do
-TExcMessage
\
-TExcMessage
\
-TExcProc
\
-TExcProc
\
-TException
\
-TException
\
-TExecScanAccessMtd
\
-TExecStatus
\
-TExecStatus
\
-TExecStatusType
\
-TExecStatusType
\
-TExitStatus
\
-TExplainState
\
-TExplainState
\
-TExplainStmt
\
-TExplainStmt
\
-TExpr
\
-TExpr
\
-TExprContext
\
-TExprContext
\
-TExprDoneCond
\
-TExtendStmt
\
-TExtendStmt
\
-TFIELD_INFO
\
-TFILE
\
-TFILE
\
-TFILE
\
-TFUNMAP
\
-TFUNMAP
\
-TFetchStmt
\
-TFetchStmt
\
-TFieldSelect
\
-TFile
\
-TFile
\
-TFileName
\
-TFileName
\
-TFixedItem
\
-TFindSplitData
\
-TFixedItemData
\
-TFixedStack
\
-TFixedStackData
\
-TFjoin
\
-TFjoin
\
-TFkConstraint
\
-TFkConstraint
\
-TFmgr
Call
\
-TFmgr
Builtin
\
-TFmgrInfo
\
-TFmgrInfo
\
-TFmgrValues
\
-TFont
\
-TFont
\
-TFormData_pg_aggregate
\
-TFormData_pg_aggregate
\
-TFormData_pg_am
\
-TFormData_pg_am
\
...
@@ -235,6 +263,7 @@ do
...
@@ -235,6 +263,7 @@ do
-TFormData_pg_inherits
\
-TFormData_pg_inherits
\
-TFormData_pg_ipl
\
-TFormData_pg_ipl
\
-TFormData_pg_language
\
-TFormData_pg_language
\
-TFormData_pg_largeobject
\
-TFormData_pg_listener
\
-TFormData_pg_listener
\
-TFormData_pg_log
\
-TFormData_pg_log
\
-TFormData_pg_opclass
\
-TFormData_pg_opclass
\
...
@@ -262,6 +291,7 @@ do
...
@@ -262,6 +291,7 @@ do
-TForm_pg_inherits
\
-TForm_pg_inherits
\
-TForm_pg_ipl
\
-TForm_pg_ipl
\
-TForm_pg_language
\
-TForm_pg_language
\
-TForm_pg_largeobject
\
-TForm_pg_log
\
-TForm_pg_log
\
-TForm_pg_opclass
\
-TForm_pg_opclass
\
-TForm_pg_operator
\
-TForm_pg_operator
\
...
@@ -275,14 +305,15 @@ do
...
@@ -275,14 +305,15 @@ do
-TForm_pg_type
\
-TForm_pg_type
\
-TForm_pg_variable
\
-TForm_pg_variable
\
-TFormatNode
\
-TFormatNode
\
-TFromExpr
\
-TFunc
\
-TFunc
\
-TFuncCall
\
-TFuncCall
\
-TFuncIndexInfo
\
-TFuncIndexInfoPtr
\
-TFuncInfo
\
-TFuncInfo
\
-TFunction
\
-TFunction
\
-TFunctionCache
\
-TFunctionCache
\
-TFunctionCachePtr
\
-TFunctionCachePtr
\
-TFunctionCallInfo
\
-TFunctionCallInfoData
\
-TGC
\
-TGC
\
-TGContext
\
-TGContext
\
-TGISTENTRY
\
-TGISTENTRY
\
...
@@ -295,20 +326,27 @@ do
...
@@ -295,20 +326,27 @@ do
-TGISTScanOpaque
\
-TGISTScanOpaque
\
-TGISTScanOpaqueData
\
-TGISTScanOpaqueData
\
-TGIST_SPLITVEC
\
-TGIST_SPLITVEC
\
-TGLOBAL_VALUES
\
-TGUC_yy_size_t
\
-TGUC_yy_state_type
\
-TGene
\
-TGene
\
-TGlobalMemory
\
-TGlobalMemoryData
\
-TGroup
\
-TGroup
\
-TGroupBuffer
\
-TGroupClause
\
-TGroupClause
\
-TGroupState
\
-TGroupState
\
-TGucContext
\
-THASHACTION
\
-THASHACTION
\
-THASHCTL
\
-THASHCTL
\
-THASH_SEQ_STATUS
\
-THDBC
\
-THENV
\
-THHDR
\
-THHDR
\
-THISTORY_STATE
\
-THISTORY_STATE
\
-THIST_ENTRY
\
-THIST_ENTRY
\
-THOLDER
\
-THOLDERTAG
\
-THSTMT
\
-THTAB
\
-THTAB
\
-TH
andleRIRAttributeRule_context
\
-TH
WND
\
-THash
\
-THash
\
-THashItem
\
-THashItem
\
-THashItemData
\
-THashItemData
\
...
@@ -331,8 +369,6 @@ do
...
@@ -331,8 +369,6 @@ do
-THashtFunc
\
-THashtFunc
\
-THeapAccessStatistics
\
-THeapAccessStatistics
\
-THeapAccessStatisticsData
\
-THeapAccessStatisticsData
\
-THeapMemoryBlock
\
-THeapMemoryBlockData
\
-THeapScanDesc
\
-THeapScanDesc
\
-THeapScanDescData
\
-THeapScanDescData
\
-THeapTuple
\
-THeapTuple
\
...
@@ -340,11 +376,9 @@ do
...
@@ -340,11 +376,9 @@ do
-THeapTupleHeader
\
-THeapTupleHeader
\
-THeapTupleHeaderData
\
-THeapTupleHeaderData
\
-TINTRANGE
\
-TINTRANGE
\
-TIPCKey
\
-TIdList
\
-TIdList
\
-TIdent
\
-TIdent
\
-TIncrementVarSublevelsUp_context
\
-TIncrementVarSublevelsUp_context
\
-TIndDesc
\
-TIndInfo
\
-TIndInfo
\
-TIndex
\
-TIndex
\
-TIndexAttributeBitMap
\
-TIndexAttributeBitMap
\
...
@@ -366,6 +400,7 @@ do
...
@@ -366,6 +400,7 @@ do
-TIndexTupleData
\
-TIndexTupleData
\
-TIndirectBlock
\
-TIndirectBlock
\
-TInhInfo
\
-TInhInfo
\
-TInhOption
\
-TInhPaths
\
-TInhPaths
\
-TInsertIndexResult
\
-TInsertIndexResult
\
-TInsertIndexResultData
\
-TInsertIndexResultData
\
...
@@ -397,6 +432,7 @@ do
...
@@ -397,6 +432,7 @@ do
-TJoinInfo
\
-TJoinInfo
\
-TJoinPath
\
-TJoinPath
\
-TJoinState
\
-TJoinState
\
-TJoinType
\
-TJunkFilter
\
-TJunkFilter
\
-TKEYMAP_ENTRY
\
-TKEYMAP_ENTRY
\
-TKEYMAP_ENTRY_ARRAY
\
-TKEYMAP_ENTRY_ARRAY
\
...
@@ -413,8 +449,12 @@ do
...
@@ -413,8 +449,12 @@ do
-TLOCKMETHODTABLE
\
-TLOCKMETHODTABLE
\
-TLOCKMODE
\
-TLOCKMODE
\
-TLOCKTAG
\
-TLOCKTAG
\
-TLO_ARG
\
-TLPARAM
\
-TLSEG
\
-TLSEG
\
-TLargeObjectDesc
\
-TLargeObjectDesc
\
-TLimit
\
-TLimitState
\
-TList
\
-TList
\
-TListenStmt
\
-TListenStmt
\
-TLoadStmt
\
-TLoadStmt
\
...
@@ -452,7 +492,6 @@ do
...
@@ -452,7 +492,6 @@ do
-TNestPath
\
-TNestPath
\
-TNode
\
-TNode
\
-TNodeTag
\
-TNodeTag
\
-TNoname
\
-TNotifyStmt
\
-TNotifyStmt
\
-TNumeric
\
-TNumeric
\
-TNumericData
\
-TNumericData
\
...
@@ -462,22 +501,25 @@ do
...
@@ -462,22 +501,25 @@ do
-TOffsetNumber
\
-TOffsetNumber
\
-TOffsetVarNodes_context
\
-TOffsetVarNodes_context
\
-TOid
\
-TOid
\
-TOid
\
-TOidOptions
\
-TOldstyle_fnextra
\
-TOpType
\
-TOpType
\
-TOpaque
\
-TOpaque
\
-TOpaqueData
\
-TOpaqueData
\
-TOper
\
-TOper
\
-TOperator
\
-TOperator
\
-TOprInfo
\
-TOprInfo
\
-TOrderedElem
\
-TOutputContext
\
-TOrderedElemData
\
-TOrderedSet
\
-TOrderedSetData
\
-TOverflowPageAddress
\
-TOverflowPageAddress
\
-TPATH
\
-TPATH
\
-TPGFInfoFunction
\
-TPGFunction
\
-TPGLZ_DecompState
\
-TPGLZ_DecompState
\
-TPGLZ_Header
\
-TPGLZ_Header
\
-TPGLZ_HistEntry
\
-TPGLZ_HistEntry
\
-TPGLZ_Strategy
\
-TPGLZ_Strategy
\
-TPGShmemHeader
\
-TPGconn
\
-TPGconn
\
-TPGnotify
\
-TPGnotify
\
-TPGresult
\
-TPGresult
\
...
@@ -491,6 +533,7 @@ do
...
@@ -491,6 +533,7 @@ do
-TPROC
\
-TPROC
\
-TPROC_HDR
\
-TPROC_HDR
\
-TPROC_QUEUE
\
-TPROC_QUEUE
\
-TPTR
\
-TPacket
\
-TPacket
\
-TPacketDoneProc
\
-TPacketDoneProc
\
-TPacketLen
\
-TPacketLen
\
...
@@ -505,12 +548,17 @@ do
...
@@ -505,12 +548,17 @@ do
-TParamListInfo
\
-TParamListInfo
\
-TParamListInfoData
\
-TParamListInfoData
\
-TParamNo
\
-TParamNo
\
-TParameterInfoClass
\
-TParseState
\
-TParseState
\
-TPasswordPacket
\
-TPasswordPacket
\
-TPasswordPacketV0
\
-TPasswordPacketV0
\
-TPath
\
-TPath
\
-TPathKeyItem
\
-TPathKeyItem
\
-TPathKeysComparison
\
-TPathKeysComparison
\
-TPattern_Prefix_Status
\
-TPattern_Type
\
-TPendingRelDelete
\
-TPg_finfo_record
\
-TPixmap
\
-TPixmap
\
-TPlan
\
-TPlan
\
-TPoint
\
-TPoint
\
...
@@ -518,28 +566,25 @@ do
...
@@ -518,28 +566,25 @@ do
-TPool
\
-TPool
\
-TPort
\
-TPort
\
-TPortal
\
-TPortal
\
-TPortalBlock
\
-TPortalBlockData
\
-TPortalBuffer
\
-TPortalD
\
-TPortalD
\
-TPortalEntry
\
-TPortalHashEnt
\
-TPortalHashEnt
\
-TPortalHeapMemory
\
-TPortalMemoryContext
\
-TPortalVariableMemory
\
-TPostgresPollingStatusType
\
-TPostgresPollingStatusType
\
-TPr
edInfo
\
-TPr
intExtraTocPtr
\
-TPr
efix_Status
\
-TPr
intTocDataPtr
\
-TPrinttupAttrInfo
\
-TPrinttupAttrInfo
\
-TPrivateMem
\
-TProcState
\
-TProcState
\
-TProcedureStmt
\
-TProcedureStmt
\
-TProcessingMode
\
-TProcessingMode
\
-TProjectionInfo
\
-TProjectionInfo
\
-TProtocolVersion
\
-TProtocolVersion
\
-TProtocolVersion
\
-TPsqlSettings
\
-TPsqlSettings
\
-TQResultClass
\
-TQuery
\
-TQuery
\
-TQueryDesc
\
-TQueryDesc
\
-TQueryInfo
\
-TQueryResultCode
\
-TRETCODE
\
-TRI_OpreqHashEntry
\
-TRI_OpreqHashEntry
\
-TRI_QueryHashEntry
\
-TRI_QueryHashEntry
\
-TRI_QueryKey
\
-TRI_QueryKey
\
...
@@ -552,59 +597,92 @@ do
...
@@ -552,59 +597,92 @@ do
-TRTreeScanOpaque
\
-TRTreeScanOpaque
\
-TRTreeScanOpaqueData
\
-TRTreeScanOpaqueData
\
-TRangeQueryClause
\
-TRangeQueryClause
\
-TRangeSubselect
\
-TRangeTblEntry
\
-TRangeTblEntry
\
-TRangeTblRef
\
-TRangeVar
\
-TRangeVar
\
-TRawColumnDefault
\
-TRawColumnDefault
\
-TReadBufPtr
\
-TReadBytePtr
\
-TReadExtraTocPtr
\
-TRecipeStmt
\
-TRecipeStmt
\
-TRegProcedure
\
-TRegProcedure
\
-TReindexStmt
\
-TReindexStmt
\
-TRel
Expr
\
-TRel
FileNode
\
-TRelIdCacheEnt
\
-TRelIdCacheEnt
\
-TRelNameCacheEnt
\
-TRelNameCacheEnt
\
-TRelNodeCacheEnt
\
-TRelOptInfo
\
-TRelOptInfo
\
-TRelabelType
\
-TRelabelType
\
-TRelation
\
-TRelation
\
-TRelationBuildDescInfo
\
-TRelationBuildDescInfo
\
-TRelationData
\
-TRelationData
\
-TRelationInfo
\
-TRelationInvalidationData
\
-TRelationInvalidationData
\
-TRelationList
\
-TRelationPtr
\
-TRelationPtr
\
-TRelativeTime
\
-TRelativeTime
\
-TRelids
\
-TRelids
\
-TRemoveAggrStmt
\
-TRemoveAggrStmt
\
-TRemoveFuncStmt
\
-TRemoveFuncStmt
\
-TRemoveOperStmt
\
-TRemoveOperStmt
\
-TRemoveStmt
\
-TRenameStmt
\
-TRenameStmt
\
-TResTarget
\
-TResTarget
\
-TResdom
\
-TResdom
\
-TResolveNew_context
\
-TResolveNew_context
\
-TRestoreOptions
\
-TRestrictInfo
\
-TRestrictInfo
\
-TResult
\
-TResult
\
-TResultRelInfo
\
-TResultState
\
-TResultState
\
-TRetrieveIndexResult
\
-TRetrieveIndexResult
\
-TRetrieveIndexResultData
\
-TRetrieveIndexResultData
\
-TReturnSetInfo
\
-TRewriteInfo
\
-TRewriteInfo
\
-TRewriteRule
\
-TRewriteRule
\
-TRmgrData
\
-TRmgrData
\
-TRmgrId
\
-TRmgrId
\
-TRowMark
\
-TRuleLock
\
-TRuleLock
\
-TRuleStmt
\
-TRuleStmt
\
-TSDOUBLE
\
-TSDWORD
\
-TSEGMENT
\
-TSEGMENT
\
-TSEG_OFFSET
\
-TSEG_OFFSET
\
-TSEMA
\
-TSEMA
\
-TSFLOAT
\
-TSHMEM_OFFSET
\
-TSHMEM_OFFSET
\
-TSHM_QUEUE
\
-TSHM_QUEUE
\
-TSIMPLE_TIME
\
-TSISeg
\
-TSISeg
\
-TSLock
\
-TSLock
\
-TSPINLOCK
\
-TSPINLOCK
\
-TSPITupleTable
\
-TSPITupleTable
\
-TSPLITVEC
\
-TSPLITVEC
\
-TSQLBIGINT
\
-TSQLCHAR
\
-TSQLDOUBLE
\
-TSQLFLOAT
\
-TSQLFunctionCache
\
-TSQLFunctionCachePtr
\
-TSQLGUID
\
-TSQLINTEGER
\
-TSQLINTERVAL
\
-TSQLREAL
\
-TSQLSCHAR
\
-TSQLSMALLINT
\
-TSQLUBIGINT
\
-TSQLUINTEGER
\
-TSQLUSMALLINT
\
-TSQL_DATE_STRUCT
\
-TSQL_DAY_SECOND_STRUCT
\
-TSQL_INTERVAL_STRUCT
\
-TSQL_TIMESTAMP_STRUCT
\
-TSQL_TIME_STRUCT
\
-TSQL_YEAR_MONTH_STRUCT
\
-TSSHOR
\
-TSTMT_Status
\
-TSWORD
\
-TSaveArchivePtr
\
-TScan
\
-TScan
\
-TScanDirection
\
-TScanDirection
\
-TScanFunc
\
-TScanKey
\
-TScanKey
\
-TScanKeyData
\
-TScanKeyData
\
-TScanKeyword
\
-TScanKeyword
\
...
@@ -615,6 +693,11 @@ do
...
@@ -615,6 +693,11 @@ do
-TSeqScan
\
-TSeqScan
\
-TSeqTable
\
-TSeqTable
\
-TSeqTableData
\
-TSeqTableData
\
-TSetOp
\
-TSetOpCmd
\
-TSetOpState
\
-TSetOperation
\
-TSetOperationStmt
\
-TSharedInvalid
\
-TSharedInvalid
\
-TSharedInvalidData
\
-TSharedInvalidData
\
-TShmemIndexEnt
\
-TShmemIndexEnt
\
...
@@ -623,12 +706,21 @@ do
...
@@ -623,12 +706,21 @@ do
-TSnapshot
\
-TSnapshot
\
-TSnapshotData
\
-TSnapshotData
\
-TSockAddr
\
-TSockAddr
\
-TSocketClass
\
-TSort
\
-TSort
\
-TSortClause
\
-TSortClause
\
-TSortGroupBy
\
-TSortGroupBy
\
-TSortState
\
-TSortState
\
-TSplitNumber
\
-TSplitNumber
\
-TStandardChunkHeader
\
-TStartBlobPtr
\
-TStartBlobsPtr
\
-TStartDataPtr
\
-TStartUpID
\
-TStartupPacket
\
-TStartupPacket
\
-TStartupPacket
\
-TStatementClass
\
-TStatementOptions
\
-TStrategyEvaluation
\
-TStrategyEvaluation
\
-TStrategyEvaluationData
\
-TStrategyEvaluationData
\
-TStrategyExpression
\
-TStrategyExpression
\
...
@@ -649,7 +741,12 @@ do
...
@@ -649,7 +741,12 @@ do
-TSubLink
\
-TSubLink
\
-TSubLinkType
\
-TSubLinkType
\
-TSubPlan
\
-TSubPlan
\
-TSystemPortAddress
\
-TSubqueryScan
\
-TSubqueryScanState
\
-TTABLE_INFO
\
-TTAR_MEMBER
\
-TTIMESTAMP_STRUCT
\
-TTIME_STRUCT
\
-TTXTRANGE
\
-TTXTRANGE
\
-TTableID
\
-TTableID
\
-TTableInfo
\
-TTableInfo
\
...
@@ -717,8 +814,8 @@ do
...
@@ -717,8 +814,8 @@ do
-TTcl_ValueType
\
-TTcl_ValueType
\
-TTcl_Var
\
-TTcl_Var
\
-TTcl_VarTraceProc
\
-TTcl_VarTraceProc
\
-TTempRelList
\
-TTempTable
\
-TTempTable
\
-TThingFile
\
-TTidPath
\
-TTidPath
\
-TTidScan
\
-TTidScan
\
-TTidScanState
\
-TTidScanState
\
...
@@ -793,29 +890,39 @@ do
...
@@ -793,29 +890,39 @@ do
-TTk_TextLayout
\
-TTk_TextLayout
\
-TTk_Uid
\
-TTk_Uid
\
-TTk_Window
\
-TTk_Window
\
-TTmFromChar
\
-TTocEntry
\
-TTocSortCompareFn
\
-TTransactionId
\
-TTransactionId
\
-TTransactionState
\
-TTransactionState
\
-TTransactionStateData
\
-TTransactionStateData
\
-TTransactionStmt
\
-TTransactionStmt
\
-TTrigInfo
\
-TTrigger
\
-TTrigger
\
-TTriggerData
\
-TTriggerData
\
-TTriggerDesc
\
-TTriggerDesc
\
-TTriggerEvent
\
-TTriggerEvent
\
-TTruncateStmt
\
-TTruncateStmt
\
-TTupSortStatus
\
-TTupSortStatus
\
-TTup
leBlock
\
-TTup
StoreStatus
\
-TTupleConstr
\
-TTupleConstr
\
-TTupleDesc
\
-TTupleDesc
\
-TTupleField
\
-TTupleListClass
\
-TTupleNode
\
-TTupleTable
\
-TTupleTable
\
-TTupleTableData
\
-TTupleTableData
\
-TTupleTableSlot
\
-TTupleTableSlot
\
-TTuplesortstate
\
-TTuplesortstate
\
-TTuplestorestate
\
-TType
\
-TType
\
-TTypeBlock
\
-TTypeCast
\
-TTypeCast
\
-TTypeInfo
\
-TTypeInfo
\
-TTypeName
\
-TTypeName
\
-TUCHAR
\
-TUDWORD
\
-TUNDO_LIST
\
-TUNDO_LIST
\
-TUWORD
\
-TUnique
\
-TUnique
\
-TUniqueState
\
-TUniqueState
\
-TUnlistenStmt
\
-TUnlistenStmt
\
...
@@ -824,10 +931,6 @@ do
...
@@ -824,10 +931,6 @@ do
-TVAttList
\
-TVAttList
\
-TVAttListData
\
-TVAttListData
\
-TVFunction
\
-TVFunction
\
-TVPageDescr
\
-TVPageDescrData
\
-TVPageList
\
-TVPageListData
\
-TVRelList
\
-TVRelList
\
-TVRelListData
\
-TVRelListData
\
-TVRelStats
\
-TVRelStats
\
...
@@ -836,9 +939,15 @@ do
...
@@ -836,9 +939,15 @@ do
-TVTupleMove
\
-TVTupleMove
\
-TVTupleMoveData
\
-TVTupleMoveData
\
-TVacAttrStats
\
-TVacAttrStats
\
-TVacPage
\
-TVacPageData
\
-TVacPageList
\
-TVacPageListData
\
-TVacuumStmt
\
-TVacuumStmt
\
-TValue
\
-TValue
\
-TVar
\
-TVar
\
-TVarBit
\
-TVarChar
\
-TVariableCache
\
-TVariableCache
\
-TVariableCacheData
\
-TVariableCacheData
\
-TVariableRelationContents
\
-TVariableRelationContents
\
...
@@ -852,7 +961,14 @@ do
...
@@ -852,7 +961,14 @@ do
-TViewStmt
\
-TViewStmt
\
-TVisual
\
-TVisual
\
-TVisualID
\
-TVisualID
\
-TWAIT_ORDER
\
-TWORD
\
-TWPARAM
\
-TWindow
\
-TWindow
\
-TWriteBufPtr
\
-TWriteBytePtr
\
-TWriteDataPtr
\
-TWriteExtraTocPtr
\
-TXActivateDeactivateEvent
\
-TXActivateDeactivateEvent
\
-TXActivateEvent
\
-TXActivateEvent
\
-TXAnyEvent
\
-TXAnyEvent
\
...
@@ -897,9 +1013,7 @@ do
...
@@ -897,9 +1013,7 @@ do
-TXICCallback
\
-TXICCallback
\
-TXICProc
\
-TXICProc
\
-TXID
\
-TXID
\
-TXIDLookupEnt
\
-TXIDProc
\
-TXIDProc
\
-TXIDTAG
\
-TXIM
\
-TXIM
\
-TXIMCallback
\
-TXIMCallback
\
-TXIMCaretDirection
\
-TXIMCaretDirection
\
...
@@ -942,8 +1056,11 @@ do
...
@@ -942,8 +1056,11 @@ do
-TXLogCtlWrite
\
-TXLogCtlWrite
\
-TXLogPageHeader
\
-TXLogPageHeader
\
-TXLogPageHeaderData
\
-TXLogPageHeaderData
\
-TXLogRecData
\
-TXLogRecPtr
\
-TXLogRecPtr
\
-TXLogRecord
\
-TXLogRecord
\
-TXLogRelCacheEntry
\
-TXLogRelDesc
\
-TXLogSubRecord
\
-TXLogSubRecord
\
-TXMapEvent
\
-TXMapEvent
\
-TXMapRequestEvent
\
-TXMapRequestEvent
\
...
@@ -986,15 +1103,20 @@ do
...
@@ -986,15 +1103,20 @@ do
-TYY_BUFFER_STATE
\
-TYY_BUFFER_STATE
\
-TYY_CHAR
\
-TYY_CHAR
\
-T_LIB_VERSION_TYPE
\
-T_LIB_VERSION_TYPE
\
-T_LIB_VERSION_TYPE
\
-T_LockId_
\
-T_LockId_
\
-T_RuneEntry
\
-T_RuneEntry
\
-T_RuneEntry
\
-T_RuneLocale
\
-T_RuneLocale
\
-T_RuneLocale
\
-T_RuneRange
\
-T_RuneRange
\
-T_RuneRange
\
-T_SPI_connection
\
-T_SPI_connection
\
-T_SPI_plan
\
-T_SPI_plan
\
-T_XPrivDisplay
\
-T_XPrivDisplay
\
-Taclitem
\
-Taclitem
\
-Tapply_RIR_view_context
\
-Tadjust_inherited_attrs_context
\
-Talloc_func
\
-Tassoc_list
\
-Tassoc_list
\
-Tattribute_used_context
\
-Tattribute_used_context
\
-TbackslashResult
\
-TbackslashResult
\
...
@@ -1007,78 +1129,115 @@ do
...
@@ -1007,78 +1129,115 @@ do
-Tbool8
\
-Tbool8
\
-Tbytea
\
-Tbytea
\
-Tcaddr_t
\
-Tcaddr_t
\
-Tcaddr_t
\
-Tcat_t
\
-Tcat_t
\
-Tcc_t
\
-Tcc_t
\
-Tchar
\
-Tchar
\
-Tcheck_if_rte_used_context
\
-Tchar
\
-Tcharf
\
-Tcheck_ungrouped_columns_context
\
-Tcheck_ungrouped_columns_context
\
-Tclock_t
\
-Tclock_t
\
-Tclock_t
\
-Tclockid_t
\
-Tclockid_t
\
-Tclockid_t
\
-Tcrc64
\
-Tcset
\
-Tcset
\
-Tdaddr_t
\
-Tdaddr_t
\
-Tdaddr_t
\
-Tdatetkn
\
-Tdatetkn
\
-Tdeparse_context
\
-Tdeparse_context
\
-Tdev_t
\
-Tdev_t
\
-Tdhalloc_ptr
\
-Tdev_t
\
-Tdiv_t
\
-Tdiv_t
\
-Tdiv_t
\
-Tdouble
\
-Tdouble
\
-Tdouble
\
-TevalPlanQual
\
-TevalPlanQual
\
-TexecRowMark
\
-TexecRowMark
\
-Texecution_state
\
-Texecution_state
\
-Tf_smgr
\
-Tf_smgr
\
-Tfd_mask
\
-Tfd_mask
\
-Tfd_mask
\
-Tfd_set
\
-Tfd_set
\
-Tfd_set
\
-Tfinalize_primnode_results
\
-Tfinalize_primnode_results
\
-Tfix
_parsetree_attnums_contex
t
\
-Tfix
pt_
t
\
-Tfixpt_t
\
-Tfixpt_t
\
-Tfloat
\
-Tfloat
\
-Tfloat
\
-Tfloat32
\
-Tfloat32
\
-Tfloat32data
\
-Tfloat32data
\
-Tfloat4
\
-Tfloat4
\
-Tfloat64
\
-Tfloat64
\
-Tfloat64data
\
-Tfloat64data
\
-Tfloat8
\
-Tfloat8
\
-Tfp_except
\
-Tfp_rnd
\
-Tfpclass_t
\
-Tfpos_t
\
-Tfpos_t
\
-Tfpos_t
\
-Tfree_func
\
-Tfunc_ptr
\
-Tfunc_ptr
\
-Tgid_t
\
-Tgid_t
\
-Tgid_t
\
-TgzFile
\
-Thashnode
\
-Thashnode
\
-ThbaPort
\
-ThbaPort
\
-Tin_addr_t
\
-Tin_addr_t
\
-Tin_addr_t
\
-Tin_port_t
\
-Tin_port_t
\
-Tin_port_t
\
-Tinet
\
-Tinet
\
-Tinet_struct
\
-Tinet_struct
\
-Tino_t
\
-Tino_t
\
-Tino_t
\
-Tint
\
-Tint
\
-Tint
\
-Tint16
\
-Tint16
\
-Tint16_t
\
-Tint16_t
\
-Tint16_t
\
-Tint16m_t
\
-Tint16m_t
\
-Tint16m_t
\
-Tint2
\
-Tint2
\
-Tint2vector
\
-Tint2vector
\
-Tint32
\
-Tint32
\
-Tint32_t
\
-Tint32_t
\
-Tint32_t
\
-Tint32m_t
\
-Tint32m_t
\
-Tint32m_t
\
-Tint4
\
-Tint4
\
-Tint64
\
-Tint64
\
-Tint64_t
\
-Tint64_t
\
-Tint64_t
\
-Tint64m_t
\
-Tint64m_t
\
-Tint64m_t
\
-Tint8
\
-Tint8
\
-Tint8_t
\
-Tint8_t
\
-Tint8_t
\
-Tint8m_t
\
-Tint8m_t
\
-Tint8m_t
\
-Tintf
\
-Tjmp_buf
\
-Tjmp_buf
\
-Tjoin_references_context
\
-Tjoin_references_context
\
-Tkey_t
\
-Tkey_t
\
-Tkey_t
\
-TlclContext
\
-TlclTocEntry
\
-Tldiv_t
\
-Tldiv_t
\
-Tldiv_t
\
-Tlztext
\
-Tmacaddr
\
-Tmacaddr
\
-Tmanufacturer
\
-Tmode_t
\
-Tmode_t
\
-Tmod
ifyAggrefChangeVarnodes_contex
t
\
-Tmod
e_
t
\
-Tnlink_t
\
-Tnlink_t
\
-Tnlink_t
\
-Toff_t
\
-Toff_t
\
-Toff_t
\
-Toidvector
\
-Toidvector
\
-ToptType
\
-Tpg_pwd
\
-Tpg_pwd
\
-Tpgsql_thing_t
\
-Tpgsql_thing_t
\
-Tpid_t
\
-Tpid_t
\
-Tpid_t
\
-Tpqbool
\
-Tpqbool
\
-Tpqsigfunc
\
-Tpqsigfunc
\
-TprintQueryOpt
\
-TprintQueryOpt
\
...
@@ -1086,69 +1245,128 @@ do
...
@@ -1086,69 +1245,128 @@ do
-TpromptStatus_t
\
-TpromptStatus_t
\
-Tptrdiff_t
\
-Tptrdiff_t
\
-Tpull_var_clause_context
\
-Tpull_var_clause_context
\
-Tpull_varnos_context
\
-Tqaddr_t
\
-Tqaddr_t
\
-Tqaddr_t
\
-Tquad_t
\
-Tquad_t
\
-Tquad_t
\
-TrangeTableEntry_used_context
\
-TrangeTableEntry_used_context
\
-Tregex_t
\
-Tregex_t
\
-Tregister_t
\
-Tregister_t
\
-Tregister_t
\
-Tregmatch_t
\
-Tregmatch_t
\
-Tregoff_t
\
-Tregoff_t
\
-Tregproc
\
-Tregproc
\
-Treplace_vars_with_subplan_refs_context
\
-Treplace_vars_with_subplan_refs_context
\
-Trune_t
\
-Trune_t
\
-Trune_t
\
-Tsa_family_t
\
-Tsa_family_t
\
-Tsa_family_t
\
-Tsegsz_t
\
-Tsegsz_t
\
-Tsegsz_t
\
-Tsequence_magic
\
-Tsequence_magic
\
-Tsig_atomic_t
\
-Tsig_atomic_t
\
-Tsig_func
\
-Tsig_t
\
-Tsig_t
\
-Tsighandler_cxt
\
-Tsighandler_cxt
\
-Tsigjmp_buf
\
-Tsigjmp_buf
\
-Tsigset_t
\
-Tsigset_t
\
-Tsigset_t
\
-Tsize_t
\
-Tsize_t
\
-Tsize_t
\
-Tslock_t
\
-Tslock_t
\
-Tslock_t
\
-Tsmgrid
\
-Tsmgrid
\
-Tsocklen_t
\
-Tsocklen_t
\
-Tsocklen_t
\
-Tsop
\
-Tsop
\
-Tsopno
\
-Tsopno
\
-Tspeed_t
\
-Tspeed_t
\
-TsqlparseInfo
\
-TsqlparseState
\
-Tssize_t
\
-Tssize_t
\
-Tssize_t
\
-Tswblk_t
\
-Tswblk_t
\
-Tswblk_t
\
-Ttcflag_t
\
-Ttcflag_t
\
-Ttcp_seq
\
-Ttcp_seq
\
-Ttext
\
-Ttext
\
-TthisLockWasTriggered_context
\
-Ttime_t
\
-Ttime_t
\
-Ttime_t
\
-TuInt
\
-TuIntf
\
-TuLong
\
-TuLongf
\
-Tu_char
\
-Tu_char
\
-Tu_char
\
-Tu_int
\
-Tu_int
\
-Tu_int
\
-Tu_int16_t
\
-Tu_int16_t
\
-Tu_int16_t
\
-Tu_int16m_t
\
-Tu_int16m_t
\
-Tu_int16m_t
\
-Tu_int32_t
\
-Tu_int32_t
\
-Tu_int32_t
\
-Tu_int32m_t
\
-Tu_int32m_t
\
-Tu_int32m_t
\
-Tu_int64_t
\
-Tu_int64_t
\
-Tu_int64_t
\
-Tu_int64m_t
\
-Tu_int64m_t
\
-Tu_int64m_t
\
-Tu_int8_t
\
-Tu_int8_t
\
-Tu_int8_t
\
-Tu_int8m_t
\
-Tu_int8m_t
\
-Tu_int8m_t
\
-Tu_long
\
-Tu_long
\
-Tu_long
\
-Tu_quad_t
\
-Tu_quad_t
\
-Tu_quad_t
\
-Tu_short
\
-Tu_short
\
-Tu_short
\
-Tuch
\
-Tuch
\
-Tuid_t
\
-Tuid_t
\
-Tuid_t
\
-Tuint
\
-Tuint
\
-Tuint
\
-Tuint16
\
-Tuint16
\
-Tuint32
\
-Tuint32
\
-Tuint64
\
-Tuint8
\
-Tuint8
\
-Tushort
\
-Tushort
\
-Tushort
\
-Tva_list
\
-Tva_list
\
-Tva_list
\
-Tvarattrib
\
-Tvm_offset_t
\
-Tvm_offset_t
\
-Tvm_offset_t
\
-Tvm_size_t
\
-Tvm_size_t
\
-Tvm_size_t
\
-Tvoid
\
-Tvoid
\
-Tvoid
\
-Tvoidp
\
-Tvoidpf
\
-Twchar_t
\
-Twchar_t
\
-Twchar_t
\
-Tword16
\
-Tword16
\
-Tword32
\
-Tword32
\
-Tword8
\
-Tword8
\
-Txl_btree_delete
\
-Txl_btree_insert
\
-Txl_btree_newroot
\
-Txl_btree_split
\
-Txl_btreetid
\
-Txl_heap_clean
\
-Txl_heap_delete
\
-Txl_heap_header
\
-Txl_heap_insert
\
-Txl_heap_update
\
-Txl_heaptid
\
-Txl_seq_rec
\
-Txl_xact_abort
\
-Txl_xact_commit
\
-Tyy_size_t
\
-Tyy_size_t
\
-Tyy_state_type
\
-Tyy_state_type
\
-Tz_stream
\
-Tz_streamp
\
/tmp/
$$
a
>
/tmp/
$$
2>&1
/tmp/
$$
a
>
/tmp/
$$
2>&1
if
[
"
$?
"
-ne
0
-o
-s
/tmp/
$$
]
if
[
"
$?
"
-ne
0
-o
-s
/tmp/
$$
]
then
echo
"
$FILE
"
then
echo
"
$FILE
"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment