00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020 #ifndef ODBC_UTIL_h
00021 #define ODBC_UTIL_h
00022
00023 #if HAVE_CONFIG_H
00024 #include <config.h>
00025 #endif
00026
00027 #ifdef UNIXODBC
00028 #include <sql.h>
00029 #include <sqlext.h>
00030 #else
00031 #include "isql.h"
00032 #include "isqlext.h"
00033 #endif
00034
00035 static char rcsid_odbc_util_h[] = "$Id: odbc_util.h,v 1.9 2003/03/25 14:04:42 freddy77 Exp $";
00036 static void *no_unused_odbc_util_h_warn[] = { rcsid_odbc_util_h, no_unused_odbc_util_h_warn };
00037
00038 int odbc_set_stmt_query(struct _hstmt *stmt, const char *sql, int sql_len);
00039 int odbc_set_stmt_prepared_query(struct _hstmt *stmt, const char *sql, int sql_len);
00040 void odbc_set_return_status(struct _hstmt *stmt);
00041
00042 SQLSMALLINT odbc_tds_to_sql_type(int col_type, int col_size, int odbc_ver);
00043 int odbc_get_string_size(int size, SQLCHAR * str);
00044 int odbc_sql_to_c_type_default(int sql_type);
00045
00046 struct _sql_param_info *odbc_find_param(struct _hstmt *stmt, int param_num);
00047 SQLRETURN odbc_set_string(SQLPOINTER buffer, SQLSMALLINT cbBuffer, SQLSMALLINT FAR * pcbBuffer, const char *s, int len);
00048
00049
00050 #endif