Member Login

Username
Password
Forget Password
New Sign Up
Search Forum

Buy Support
Incidents

If you can't find your answer in the FREE PUBLIC QDeveloper Forum, require URGENT Priority Support, or you need to send us private or confidential information:

Click Here
If you can't login and post questions or you are having trouble viewing forum posts:
Click Here
Callback
Support

If you live in USA, UK, Canada, Australia or New Zealand, you can leave us details on your question and request us to call you back and discuss them with you personally  (charges apply).

Click Here
 
Buy Support
Incidents
If you can't find your answer in the FREE PUBLIC QDeveloper Forum, require URGENT Priority Support, or you need to send us private or confidential information:
Click Here

Forum : Cant update VendorCreditItemLine table using MS Access??Search Forum

Forum Home > QODBC - ODBC Driver for QuickBooks > QODBC SQL Support Forum

 New Topic 
 
 Post Reply 
[1]  
 Cant update VendorCreditItemLine table using MS Access?? 
 Author   Message 
  Don 
  
 Group: Members 
 Posts: 17 
 Joined: 2006-05-03 
 Profile
 Posted : 2007-04-18 06:22:38

Hello, I'm using MS Access 2000 with QODBC to link to Quickbooks.

I'm having trouble using an update statement that works fine with the BillItemLine table.

Here is the statement that works fine:

'******************************************************** 

'Now open a recordset to update the changed information
     sSQL = "SELECT * FROM BillItemLine " & _
            "WHERE (((TxnNumber)=" & intTxnNumber & "))"
    OpenRS (sSQL)
    g_adoRS.MoveFirst
    g_adoRS.Fields("VendorRefListID") = strVendorRefListID
    g_adoRS.Fields("ItemLineDesc") = strItemLineDesc
    g_adoRS.Fields("RefNumber") = strInvoiceNum
    g_adoRS.Fields("TxnDate") = strTxnDate
    g_adoRS.Fields("ItemLineCost") = dblItemLineCost
    g_adoRS.Fields("Memo") = strMemo
    g_adoRS.Fields("ItemLineTaxCodeRefListID") = strItemLineTaxCodeRefListID
   
    g_adoRS.Update

'**********************************************************************

Yet when I fundamentally try to update the VendorCreditList table using the same method it errors out to error code -2147467259. Here is the code for that:

'**********************************************************************

'Now open a recordset to update the changed information
     sSQL = "SELECT * FROM VendorCreditItemLine " & _
            "WHERE (((TxnNumber)=" & intTxnNumber & "))"
    OpenRS (sSQL)
    g_adoRS.MoveFirst
    g_adoRS.Fields("VendorRefListID") = strVendorRefListID
    g_adoRS.Fields("TxnDate") = strTxnDate
    g_adoRS.Fields("RefNumber") = strInvoiceNum
    g_adoRS.Fields("ItemLineDesc") = strItemLineDesc
    g_adoRS.Fields("Memo") = strMemo
    g_adoRS.Fields("ItemLineCost") = dblItemLineCost
    g_adoRS.Fields("ItemLineTaxCodeRefListID") = strItemLineTaxCodeRefListID
   
    g_adoRS.Update

'********************************************************************************************

I'd really appreciate any assistance you can provide, I've checked and double checked all the variables that are being passed and they look just fine. The recordset itself has the previous values.

 

  Top 
  Tom 
  6c3c1_sdk-qodbc.gif
 Group: Administrator 
 Posts: 5510 
 Joined: 2006-02-17 
 Profile
 Posted : 2007-04-18 08:46:31

The VendorCreditItemLine table is not updateable. You can only INSERT new lines.

 

  Top 
 New Topic 
 
 Post Reply 
[1]  

Jump to