Dan Villiom Podlaski Christiansen
e22791606f
odbc: support reading OLE entries
...
This adds support for reading OLE objects to the ODBC driver. The APIs
for reading OLE appear somewhat idiosyncratic, so we read the string
fully and stash it in a static variable.
Tested by reading an old Access database, with checking for memory leaks.
2015-09-28 13:56:10 +02:00
Dan Villiom Podlaski Christiansen
1b8c2ca483
odbc: don't assume sizeof(int) == sizeof(long)
...
Most 64-bit environments use 64 bit longs and 32 bit ints; as such,
comparing an int to LONG_MIN/MAX makes no sense. Since SQL LONGs
appear limited to 32 bits, I assume INT_MIN/MAX was intended.
2015-09-28 13:56:09 +02:00
Nirgal Vourgère
584119e415
Split bash-completion snippet in small ones
...
/usr/share/bash-completion/completions/ now uses dynamic loading based on file name.
2015-05-30 15:40:58 +02:00
Nirgal Vourgère
428834bbc4
Merge pull request 78
2015-05-26 17:34:51 +02:00
Nirgal Vourgère
eb7d03187f
Space normalisation
2015-05-26 17:34:34 +02:00
William Rogers
4148518906
Freed memory on SQL engine termination
...
Modified mdb_sql_exit to free the memory allocated for the SQL engine in mdb_sql_init
2015-05-24 18:04:14 -05:00
William Rogers
d0472d96ba
Added proper SQL engine termination
...
Since the SQL engine is initialized in _SQLAllocEnv, the engine should be also terminated in SQLFreeEnv.
2015-05-24 17:38:50 -05:00
William Rogers
82e3436494
Corrected memory being improperly freed
...
The memory for sql->bound_values is now freed by mdb_sql_reset, so these values no longer should be freed in dump_results_pp. Also, this fixes a memory leak that was occurring when results were not being pretty printed.
2015-05-24 17:15:52 -05:00
William Rogers
0123d7e1c2
Fixed memory leak - sql->bound_values
...
Memory allocated by mdb_sql_bind_all for sql->bound_values was being leaked at each query execution. Memory is now freed in mdb_sql_reset
2015-05-24 17:12:29 -05:00
William Rogers
9276aca347
Consolidated calls to mdb_sql_reset
...
SQL engine was being reset in both dump_results functions. Rather than having several different functions responsible for resetting the engine depending on the circumstances, the reset now only occurs in run_query, the same function where the query is executed.
2015-05-24 17:05:41 -05:00
William Rogers
bcc7ad5a7a
Fixed memory leak in _SQLFreeEnv
...
Memory allocated for the _henv structure was not being freed which caused a small memory leak.
2015-05-24 16:49:44 -05:00
William Rogers
5888c4a52c
Correction to SQLGetData string length handling
...
According to http://download.oracle.com/otn_hosted_doc/timesten/703/TimesTen-Documentation/ms.odbc.pdf and https://msdn.microsoft.com/en-us/library/ms710980(v=vs.85).aspx , the string length should not include the NULL character at the end.
Previous behavior would likely work without problems for any language that uses C-style null terminated strings, but adds a null character in the string when using the driver with a language that does not use C-style strings.
2015-05-22 20:10:10 -05:00
William Rogers
dca7552d8b
Implemented SQL_DESC_UNSIGNED attribute in SQLColAttributes
2015-05-22 16:30:13 -05:00
Vladimir Rutsky
772b5675dd
fix typo: "popluated"
2015-03-05 16:20:12 +03:00
Vladimir Rutsky
9fb36c0f07
fix typo: "enought"
2015-03-04 13:23:23 +03:00
Nirgal Vourgère
13e339c1a4
Clarify usage of --no-comments in mdb-schema
2015-01-12 18:17:50 +01:00
Jimmytaker
a5e1ab8a2e
Fix not being able to handle blobs > 16 MB. Limit now at 256 MB
2014-12-29 14:54:25 +01:00
Nirgal Vourgère
9b4d5e624b
Avoid dynamic array allocation on stack.
...
This might help some non C99 compliant compilers, while being a trivial change.
2014-12-29 13:14:45 +01:00
Nirgal Vourgère
072f7c6518
Decrease POSIX required level to 1
...
One can now compile with CFLAGS="-std=c99 -D_POSIX_C_SOURCE=1 -pedantic"
Trade getopt.h function for glib equivalents:
This mean all utilities now have long option names.
Adjust manuals and bash_completion accordingly.
Added missing manual and bash_completion for mdb-import.
2014-12-29 13:12:23 +01:00
Nirgal Vourgère
2a70e16a8b
Allow CFLGAS="-std=c99 -D_POSIX_C_SOURCE=2"
...
Use glib function:
strcasecmp -> g_ascii_strcasecmp
bzero -> memset
strdup -> g_strdump
Don't use arithmetic void*+int
2014-12-28 12:36:55 +01:00
Jimmytaker
850d9e169d
Fix not being able to handle blobs > 16 MB. Limit now at 256 MB
2014-12-22 20:14:40 +01:00
Jimmytaker
49bc1e3c40
New useful function (generate_table_schemas) for Windows but not only
2014-12-22 20:13:31 +01:00
Jimmytaker
cb65d4f3dd
Compiles with VC++ as a .dll. Set up to use static glib, libiconv, libintl for ease of use.
2014-12-22 20:09:43 +01:00
Jimmytaker
aab7a561f1
VS2012 Build project and gitignore update
2014-12-22 19:55:11 +01:00
Shane Mc Cormack
a3ab6c7969
Fix for dates in mdb-props
2014-10-18 06:25:54 +02:00
Maurus Cuelenaere
e2c46bad8b
Add MySQL support to mdb_print_indexes()
2014-10-17 22:18:34 +02:00
Maurus Cuelenaere
97ddfcf8b2
Introduce MDB_BACKEND_* enum
2014-10-17 22:16:49 +02:00
nirgal
85f8efc85f
Merge pull request #59 from paulfitz/prune-headers
...
remove unneeded headers
2014-10-17 04:09:38 +00:00
Paul Fitzpatrick
3f52803c19
remove unneeded headers
2014-10-16 18:40:13 -04:00
tyzhaoqi
9ab40e83e6
Fix binary outout
...
Closes issue #44
2014-07-24 08:10:49 +02:00
lovelytwo
a89baeacf5
Segfault fix on memo zero length multiple page
...
While converting memo field to string, stop processing on zero length multiple
page.
2014-05-02 15:12:16 +02:00
Maurus Cuelenaere
65b573637e
Add MySQL support to mdb_print_indexes()
2014-03-17 13:30:40 +01:00
Maurus Cuelenaere
cce6cfead2
Introduce MDB_BACKEND_* enum
2014-03-17 13:30:28 +01:00
Nirgal Vourgère
dfd752ec02
Spelling fix
...
Suppress has 2 p in English, thanks lintian.
2014-01-04 15:16:46 +01:00
Nirgal Vourgère
b5fb8243a1
Moved gmdb help arch from rarian to gnome-doc
...
And fixed gmdb.xml: <listitem> cannot contains <guiitem> dirrectly. Added a <para> wrapper.
2013-10-24 21:48:51 +02:00
Nirgal Vourgère
d9d58d3cae
Added bash-completion snipets
2013-10-22 11:01:15 +02:00
Nirgal Vourgère
b449ed159d
Added .desktop file for gmdb
2013-10-22 11:01:07 +02:00
Chris Kerr
2f4b2d12fe
Fixes build error introduced by previous commit
2013-10-13 19:11:10 +01:00
Chris Kerr
2892d519f3
Fix parallel builds (make -jN) in SQL lexer/parser
...
Initial bug repport:
https://bugs.gentoo.org/show_bug.cgi?id=486434
Thanks to Patrick Lauer.
Problem is that generated parser.h is not ready when lexer.l is compiled.
See
https://www.gnu.org/software/automake/manual/html_node/Yacc-and-Lex.html
https://www.gnu.org/software/automake/manual/automake.html#Yacc-and-Lex
2013-10-13 18:57:29 +02:00
Nirgal Vourgère
1213f84859
Fix buffer overflow in sql error message buffer
...
Also use existing buffer when printing to stderr
2013-10-13 09:05:18 +02:00
bokic
bb08d92bfb
FIX: mdb-sql crashed with SIGSEGV in _IO_vfprintf_internal() on amd64
...
https://bugs.launchpad.net/ubuntu/+source/mdbtools/+bug/1227033
2013-10-06 06:23:35 +02:00
Nirgal Vourgère
a7a39a34ee
Refresh help makefiles from gnome-doc-utils
2013-08-11 14:02:02 +02:00
Nirgal Vourgère
4a3f3492cd
Prints "file not found" when that happens
...
... rather than the obscure "Can't alloc filename"
2013-07-18 15:21:14 +02:00
Nirgal Vourgère
7841d30d43
Revert use of config.h
...
Revert
7162e8db74
088493d499
And drop AC_CONFIG_HEADERS so that config goes though the command line.
No longer generating config.h, update .gitignore
2013-07-15 02:42:12 +02:00
Nirgal Vourgère
5312060544
Changed gmdb2 output filenames to textentries
...
GtkFileChooserButton was cripled by gtk developers so that it now only support
selecting an existing file for overwrite.
https://bugzilla.gnome.org/show_bug.cgi?id=157384
TextEntries is really not user friendly, but it's better than forced overwrite.
2013-07-14 19:06:59 +02:00
Nirgal Vourgère
088493d499
Update autoconf/automake standards
...
Generated files config.guess config.sub depcomp install-sh ltmain.sh missing
and ylwrap have been moved to build-aux/
Ran autoupdate
Replaced AC_TRY_LINK/AC_TRY_COMPILE by AC_LINK_IFELSE/AC_COMPILE_IFELSE
Droped -I$(top_srcdir)/include from CFLAGS since AC_CONFIG_HEADERS already
adds the -I
Fixed bison detection
Added AM_PROG_AR as required by autoreconf -i -Wall
Updated NEWS and .gitignore
2013-07-09 18:39:03 +02:00
Nirgal Vourgère
a021708dae
Move the ODBC wide support in its own file
...
Enabling wide functions can break ascii one, like DriveConnect()
2013-07-09 00:54:03 +02:00
Nirgal Vourgère
c908a4f4de
ODBC GetData include \0 if fCType==SQL_C_CHAR
2013-07-08 17:12:47 +02:00
Nirgal Vourgère
3bdff87b9a
ODBC GetData: Add support for a few fCType codes
2013-07-08 17:06:06 +02:00
Nirgal Vourgère
06ea2517e9
ODBC bug fix: reset length location on rebind
2013-07-07 19:42:49 +02:00