Results 1 to 3 of 3
  1. #1
    victorqedu is offline Novice
    Windows 7 64bit Access 2010 64bit
    Join Date
    Oct 2014
    Posts
    2

    DELETE records are not deleted

    I have a simple problem:
    I use java to delete records in a .mdb file database.
    When I delete something the access log says success but the records don't disappear from the table.
    This is the log:



    classes" StartC 1454-1afc ENTER SQLExecDirect
    HSTMT 0x4B698A18
    UCHAR * 0x4B0B2818 [ -3] "DELETE FROM Pacient_Fisa___SZ;\ 0"
    SDWORD -3


    classes" StartC 1454-1afc EXIT SQLExecDirect with return code 0 (SQL_SUCCESS)
    HSTMT 0x4B698A18
    UCHAR * 0x4B0B2818 [ -3] "DELETE FROM Pacient_Fisa___SZ;\ 0"
    SDWORD -3


    classes" StartC 1454-1afc ENTER SQLNumResultCols
    HSTMT 0x4B698A18
    SWORD * 0x4B66E9F0


    classes" StartC 1454-1afc EXIT SQLNumResultCols with return code 0 (SQL_SUCCESS)
    HSTMT 0x4B698A18
    SWORD * 0x4B66E9F0 (0)

    If I run the exact same command from microsoft access interface the DELETE works fine.
    Thank you.

  2. #2
    June7's Avatar
    June7 is online now VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,929
    So this is a Java, not Access, issue?

    What is an Access log? Where does this info come from? Never seen this before.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  3. #3
    victorqedu is offline Novice
    Windows 7 64bit Access 2010 64bit
    Join Date
    Oct 2014
    Posts
    2
    In Control panel/administrative tools/data sources, tracing tab you can set a log and you can see every query running on the selected database.

    I made it, the records are deleted now but is not clear why.
    Solution was to close the database connection from java.
    But other .mdb databases don't have this problem. On other databases I can INSERT and DELETE without closing the connection.
    I also tried to commit before closing but commit has no effect.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Table shows deleted record but it won't delete
    By khughes46 in forum Access
    Replies: 3
    Last Post: 09-19-2014, 09:35 AM
  2. deleted record error after delete query
    By ck4794 in forum Queries
    Replies: 3
    Last Post: 10-12-2013, 02:04 PM
  3. delete query produce #deleted in all deleted values
    By learning_graccess in forum Queries
    Replies: 2
    Last Post: 03-31-2012, 07:20 AM
  4. #Deleted issue with Delete/Append Query
    By WendyCha in forum Access
    Replies: 4
    Last Post: 08-05-2011, 08:34 AM
  5. Replies: 3
    Last Post: 07-27-2011, 02:07 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums