NCBI C++ ToolKit
Classes | Macros | Functions | Variables
data.c File Reference
#include "common.h"
#include <ctype.h>
#include "parser.h"
#include <common/test_assert.h>
+ Include dependency graph for data.c:

Go to the source code of this file.

Go to the SVN repository for this file.

Classes

struct  lookup_int
 

Macros

#define TYPE(s)   { #s, s }
 
#define TEST_FILE   "data.in"
 

Functions

static void Test (const char *type, const char *value_to_convert, SQLSMALLINT out_c_type, const char *expected)
 
static int get_int (const char *s)
 
static int lookup (const char *name, const struct lookup_int *table)
 
int main (int argc, char *argv[])
 

Variables

static int result = 0
 
static int ignore_select_error = 0
 
static int ignore_result = 0
 
static struct lookup_int sql_c_types []
 

Macro Definition Documentation

◆ TEST_FILE

#define TEST_FILE   "data.in"

◆ TYPE

#define TYPE (   s)    { #s, s }

Function Documentation

◆ get_int()

static int get_int ( const char *  s)
static

Definition at line 70 of file data.c.

References odbc_fatal().

◆ lookup()

static int lookup ( const char *  name,
const struct lookup_int table 
)
static

Definition at line 90 of file data.c.

Referenced by main().

◆ main()

int main ( int  argc,
char *  argv[] 
)

◆ Test()

static void Test ( const char *  type,
const char *  value_to_convert,
SQLSMALLINT  out_c_type,
const char *  expected 
)
static

Variable Documentation

◆ ignore_result

int ignore_result = 0
static

Definition at line 23 of file data.c.

Referenced by main(), and Test().

◆ ignore_select_error

int ignore_select_error = 0
static

Definition at line 22 of file data.c.

Referenced by main(), and Test().

◆ result

int result = 0
static

Definition at line 20 of file data.c.

Referenced by main(), and Test().

◆ sql_c_types

struct lookup_int sql_c_types[]
static
Initial value:
= {
#define TYPE(s)
{ "SQL_C_NUMERIC", SQL_C_NUMERIC },
{ "SQL_C_BINARY", SQL_C_BINARY },
{ "SQL_C_CHAR", SQL_C_CHAR },
{ "SQL_C_WCHAR", SQL_C_WCHAR },
{ "SQL_C_LONG", SQL_C_LONG },
{ "SQL_C_SBIGINT", SQL_C_SBIGINT },
{ "SQL_C_SHORT", SQL_C_SHORT },
{ "SQL_C_TIMESTAMP", SQL_C_TIMESTAMP },
{ NULL, 0 }
}
#define NULL
Definition: ncbistd.hpp:225
#define SQL_C_BINARY
Definition: sqlext.h:546
#define SQL_C_SHORT
Definition: sqlext.h:513
#define SQL_C_LONG
Definition: sqlext.h:512
#define SQL_C_SBIGINT
Definition: sqlext.h:549
#define SQL_C_TIMESTAMP
Definition: sqlext.h:527
#define SQL_C_NUMERIC
Definition: sqlext.h:517
#define SQL_C_CHAR
Definition: sqlext.h:511
#define SQL_C_WCHAR
Definition: sqlucode.h:17

Definition at line 90 of file data.c.

Referenced by main().

Modified on Thu Feb 29 12:18:03 2024 by modify_doxy.py rev. 669887