mirror of
https://github.com/mdbtools/mdbtools.git
synced 2026-03-10 00:20:54 +08:00
commiting gmdb
doc updates odbc fixes
This commit is contained in:
@@ -62,6 +62,7 @@ host_triplet = i686-pc-linux-gnu
|
||||
AS = @AS@
|
||||
CC = gcc
|
||||
DLLTOOL = @DLLTOOL@
|
||||
HAVE_GNOME =
|
||||
LD = /usr/bin/ld
|
||||
LEX = flex
|
||||
LIBTOOL = $(SHELL) $(top_builddir)/libtool
|
||||
@@ -96,7 +97,7 @@ libmdbsql_la_LIBADD =
|
||||
libmdbsql_la_OBJECTS = mdbsql.lo parser.lo lexer.lo
|
||||
LEX_OUTPUT_ROOT = lex.yy
|
||||
LEXLIB = -lfl
|
||||
CFLAGS = -g -O2 -DUNIXODBC -DSQL
|
||||
CFLAGS = -g -O2 -DUNIXODBC -DSQL -DHAVE_GNOME
|
||||
COMPILE = $(CC) $(DEFS) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
|
||||
LTCOMPILE = $(LIBTOOL) --mode=compile $(CC) $(DEFS) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
|
||||
CCLD = $(CC)
|
||||
|
||||
@@ -62,6 +62,7 @@ host_triplet = @host@
|
||||
AS = @AS@
|
||||
CC = @CC@
|
||||
DLLTOOL = @DLLTOOL@
|
||||
HAVE_GNOME = @HAVE_GNOME@
|
||||
LD = @LD@
|
||||
LEX = @LEX@
|
||||
LIBTOOL = @LIBTOOL@
|
||||
|
||||
@@ -476,6 +476,24 @@ int i, j;
|
||||
}
|
||||
}
|
||||
}
|
||||
void mdbsql_bind_len(MdbSQL *sql, int colnum, int *len_ptr)
|
||||
{
|
||||
MdbTableDef *table = sql->cur_table;
|
||||
MdbSQLColumn *sqlcol;
|
||||
MdbColumn *col;
|
||||
int i, j;
|
||||
|
||||
/* sql columns are traditionally 1 based, so decrement colnum */
|
||||
sqlcol = g_ptr_array_index(sql->columns,colnum - 1);
|
||||
for (j=0;j<table->num_cols;j++) {
|
||||
col=g_ptr_array_index(table->columns,j);
|
||||
if (!strcasecmp(sqlcol->name, col->name)) {
|
||||
/* bind the column length to its listed (SQL) position */
|
||||
mdb_bind_len(table, j+1, len_ptr);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
void mdbsql_bind_all(MdbSQL *sql)
|
||||
{
|
||||
int i;
|
||||
|
||||
Reference in New Issue
Block a user