Repository (Git)

Browse

Name Size Revision Age Author Comment
  Database f9f0ee92 162 days John Goerzen Documented the nature of seErrorMsg fixes #76
  debian c03361f7 147 days John Goerzen Rebuilding with newer HDBC
  testsrc edbe0591 385 days John Goerzen Fix fetchAllRows' test
COPYING 25.9 KB 36550714 1063 days John Goerzen UNDO: Removed most files irrelevant for testsuite
COPYRIGHT 844 Bytes a43f5a5b 313 days John Goerzen Updates for newer GHC
HDBC-odbc.cabal 1.2 KB 2dce4864 170 days John Goerzen Updated verison to 1.1.4.4 in cabal Not making...
Makefile 1.8 KB d48040ca 855 days John Goerzen Detect OS and link to odbc32 if on Windows See...
README.txt 2.5 KB a43f5a5b 313 days John Goerzen Updates for newer GHC
Setup.hs 74 Bytes f97834c4 319 days bjorn hdbc-odbc: Use Cabal configurations. The odbc/o...
TODO 46 Bytes b11cb430 1058 days John Goerzen Fixing up doc, cabal, and copyright info in pre...
hdbc-odbc-helper.c 3.9 KB e84cd13e 232 days John Goerzen Fixed mingw32 ifdefs in hdbc-odbc-helper.[ch]
hdbc-odbc-helper.h 1.1 KB e84cd13e 232 days John Goerzen Fixed mingw32 ifdefs in hdbc-odbc-helper.[ch]

Latest revisions

# Date Author Comment
c03361f7 06/26/2008 09:18 AM John Goerzen

Rebuilding with newer HDBC

78ff23ca 06/26/2008 09:14 AM John Goerzen

Merge branch 'master' of :git/hdbc-odbc

f9f0ee92 06/11/2008 03:04 PM John Goerzen

Documented the nature of seErrorMsg

fixes #76

a76a8739 06/11/2008 02:49 PM John Goerzen

Revert "No longer use "show" on seErrorMsg component."

This reverts commit 50ed6f1bb0dd8e8d5a0f4f55fddd2a82a7ab7fd0.

Oops, this was a bit hasty. We have a list here.

refs #76

50ed6f1b 06/11/2008 02:48 PM John Goerzen

No longer use "show" on seErrorMsg component.
fixes #76

17f99f3a 06/03/2008 02:55 PM John Goerzen

Note 1.1.4.4 in debian/changelog

2dce4864 06/03/2008 02:54 PM John Goerzen

Updated verison to 1.1.4.4 in cabal

Not making a Debian release for this

cca312d9 06/03/2008 08:24 AM Andrew Appleyard

Conditional calling convention for sql.h functions (Windows/Unix)

Hi John,

Please find attached a patch (against the hdbc-odbc git repository)
for your consideration. It adjusts the calling convention of all the
'sql.h' foreign imports to 'stdcall' on Windows and 'ccall' otherwise
(as discussed in [1]). Note that it has only been tested on Windows.

I was unable to link programs with hdbc-odbc on Windows without these
changes. Thanks for your work on HDBC, I've found it very useful.

[1] -
http://www.nabble.com/HDBC-with-SQL-Server---OBDC-td17459637.html

Regards,
Andrew

----------------------------------------------------------------------
Hi John,

On Tue, Jun 3, 2008 at 12:55 AM, you wrote:
> > Many thanks for sending this in. I have ensured that HDBC-odbc
does
> > build on Windows, but I have never used it in an application or an
> > executable. Can I assume that HDBC-odbc built without this patch,
but
> > did not link or run properly or something? I just want to make
sure
> > there is not an environmental difference that is causing this to
appear
> > some places and not others.

Your assumption is correct. HDBC-odbc builds fine, but when using GHC
to build a program that uses the package, it fails to link (see the
linker errors below). If I use GHCi, the program crashes silently
instead.

The patch I sent fixes both issues for me (it links in GHC and runs in
GHCi), but I guess there's still the possibility of an environmental
difference. Surely I'm not the first person to use HDBC-odbc on
Windows... (I'm running Windows Vista SP1 with msys only [no cygwin
is installed].)

Let me know if there's anything I can do to help confirm/deny if
there's something odd in my environment that's causing this.
Typically Windows DLLs use stdcall entry points though, so the changes
do make sense to me.

508cd596 04/14/2008 08:15 PM Satoshi Nakamura

HDBC-odbc: Retrieve broken data from MySQL

Hi John,

I'm using HDBC-odbc to connect to my MySQL server and found some problems
when I dealt with large data. When I fetch data from a text column it
sometimes returns a string which contains NUL characters.

I digged into the source code and found that the return value of
sqlGetData was not handled correctly. What I saw in "ffetchrow" function
was:

1. sqlDescribeCol returns a column size which is less than actual data.
Maybe this is because the column's charset is utf-8.
2. sqlGetData returns SQL_SUCCESS_WITH_INFO but the caller ignores
it. In this case plen contains the actual length which is greater than
the buffer size.
3. peekCStringLen peeks data after the end of the buffer.

I attached a patch to fix this.

First, it uses peekCString instead of peekCStringLen because the buffer
must be terminated by NUL. Second, it calls sqlGetData twice when plen is
greater than the buffer size. As a result, it eliminates the call of
sqlDescribeCol because sqlGetData returns a needed buffer size.

Best Regards,

--
Satoshi Nakamura <>
Infoteria Corporation

952a718b 04/14/2008 01:43 PM John Goerzen

Preparing 1.1.4.3

View revisions