Results 1 to 4 of 4
  1. #1
    Join Date
    Jan 2004
    Posts
    5

    Unanswered: Updateing DECIMALs with DB-Library

    Hello,

    I have encountered a problem doing an update on a Field defined as DECIMAL with dbcursor().

    I have opened a cursor with dbcursoropen() with option LOCK_CC set. Then I have bound some char variables to CHAR Fields with STRINGBIND and some double Variables to the DECIMAL fields with FLT8BIND.

    When I read the cursor, the data is correct in the bound variables. But when I do an update, all data for the numeric fields are gone and the database contains only NULL Values. The Strings are updated correctly.

    I have tried to set the length, I am using the poutlen-variables with a value other than 0, but nothing helps.

    Does anyone have an idea about what can I do?

    Thank You in advance.

    Frank

  2. #2
    Join Date
    Feb 2004
    Location
    In front of the computer
    Posts
    15,579
    Provided Answers: 54
    As DB-Library was last supported in MS-SQL 6.5, I have to wonder what other tools you are using. There are several known bugs in the RTM for Visual C 4.0 that could affect this behavior.

    Can you give us a smidgeon more detail about OS, compiler, etc? It would help to focus on which part(s) are the most interesting in terms of the likelyhood of producing your problems.

    -PatP

  3. #3
    Join Date
    Jan 2004
    Posts
    5
    Hi,

    My OS is Win/XP Prof, Develop-Environment: VS.NET C++,
    Server is W2K, SQL-Server is also the 2000 Version.
    The DB-Library was installed with my SQL Server Client, I think.

    The Application is some kind of older, so there is all DB-Access made with DB-Library.

    What I don't understand is, that reading from Database works fine, writing to char also, only the numbers are getting NULL :-(((

    With regards

    Frank

  4. #4
    Join Date
    Feb 2004
    Location
    In front of the computer
    Posts
    15,579
    Provided Answers: 54
    I've never heard of that problem, but then again I've never heard of that configuration either.

    Just double checking, but you're generating native excutables, not CLR executables, right?

    I'll think on this one some more, but I hope that someone else can help you.

    -PatP

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •