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 : Error 3120 - Inserting a receivePaymentLine RecordSearch Forum

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

 New Topic 
 
 Post Reply 
[1]  
 Error 3120 - Inserting a receivePaymentLine Record 
 Author   Message 
  robc 
  
 Group: Members 
 Posts: 13 
 Joined: 2006-04-27 
 Profile
 Posted : 2006-06-08 05:50:18

I am inserting a record using the query below.  I get an error 3120 - object "24D63-1056992623" specified in the request cannot be found.  The object in question is the TxnId for an invoice.  When I query the invoice table for that invoice, it does exist and there are already rows existing in the receivePaymentLine table that have this ID in the appliedToTxnTxnID column. 

Can you help me determine why I am getting this error?

Thanks.

Insert into receivePaymentLine
 (customerRefListId, customerRefFullName,  appliedToTxnTxnID, TxnDate, TotalAmount,   RefNumber,   paymentMethodRefListId,   depositToAccountRefListId,   Memo)
values
 ('45F0000-1025192820','ART Co,'24D63-1056992623', {d'2006-06-06'},  10, '123', '20000-916432954', 'F70000-920993005', 'Memodata')

 

  Top 
  Tom 
  6c3c1_sdk-qodbc.gif
 Group: Administrator 
 Posts: 5510 
 Joined: 2006-02-17 
 Profile
 Posted : 2006-06-08 09:03:49
You need to use either customerRefListId or customerRefFullName, not both. Check the actual invoice in QuickBooks and see How do I create a new Customer, invoice them and mark the invoice as paid? for a ReceivePayment complete example.

See also: How to I handle Customer credits on account? for more information on the procedure for receiving the payment before the Invoice.

 

  Top 
  robc 
  
 Group: Members 
 Posts: 13 
 Joined: 2006-04-27 
 Profile
 Posted : 2006-06-09 04:01:27

I see.  The invoice I am referencing has isPaid = true.  That is why the error message says that it is not found.  Can't post a payment to a paid invoice.

Thank you for you help.

 

  Top 
  Joanna 
  
 Group: Members 
 Posts: 25 
 Joined: 2006-12-07 
 Profile
 Posted : 2007-03-27 04:58:17
I was seeing this same problem, and after reading this post I realized that I was creating an invoice with an amount of 0, which means that the invoice is paid.  I was then trying to insert a payment on this invoice, the payment being 0.  This didn't work.  Thanks for the help! 

  Top 
  Dmitry S 
  
 Group: Members 
 Posts: 13 
 Joined: 2008-09-18 
 Profile
 Posted : 2008-12-04 09:26:07
Hi,

I am running a query:
INSERT INTO ReceivePaymentLine (AppliedToTxnTxnID,AppliedToTxnPaymentAmount,FQSaveToCache) Values ('8A6A1-1222137381',100,True)
INSERT INTO ReceivePayment (CustomerRefListID,ARAccountRefListID,TxnDate,RefNumber,TotalAmount,PaymentMethodRefListID,DepositToAccountRefListID,Memo) Values ('80001171-1228276005','2C0000-1182395184',{d'2008-11-03'},'1015371',100,'B0001-1184537282','2D0000-1182395224','1015371')
and it gives me the same error ([QODBC] Error: 3120 - Object "8A6A1-1222137381" specified in the request cannot be found.).

I've seen this error before and in previous cases it was caused by either paid invoices or multiple AR's. This time The invoice is definitely not paid (checking the invoice in QBs as well as querying for it, output below)

TxnID    TimeCreated    TimeModified    EditSequence    TxnNumber    CustomerRefListID    CustomerRefFullName    ClassRefListID    ClassRefFullName    ARAccountRefListID    ARAccountRefFullName    TemplateRefListID    TemplateRefFullName    TxnDate    TxnDateMacro    RefNumber    BillAddressAddr1    BillAddressAddr2    BillAddressAddr3    BillAddressAddr4    BillAddressAddr5    BillAddressCity    BillAddressState    BillAddressProvince    BillAddressCounty    BillAddressPostalCode    BillAddressCountry    BillAddressNote    BillAddressBlockAddr1    BillAddressBlockAddr2    BillAddressBlockAddr3    BillAddressBlockAddr4    BillAddressBlockAddr5    ShipAddressAddr1    ShipAddressAddr2    ShipAddressAddr3    ShipAddressAddr4    ShipAddressAddr5    ShipAddressCity    ShipAddressState    ShipAddressProvince    ShipAddressCounty    ShipAddressPostalCode    ShipAddressCountry    ShipAddressNote    ShipAddressBlockAddr1    ShipAddressBlockAddr2    ShipAddressBlockAddr3    ShipAddressBlockAddr4    ShipAddressBlockAddr5    IsPending    IsFinanceCharge    PONumber    TermsRefListID    TermsRefFullName    DueDate    SalesRepRefListID    SalesRepRefFullName    FOB    ShipDate    ShipMethodRefListID    ShipMethodRefFullName    Subtotal    ItemSalesTaxRefListID    ItemSalesTaxRefFullName    SalesTaxPercentage    SalesTaxTotal    Memo    CustomerMsgRefListID    CustomerMsgRefFullName    IsToBePrinted    IsToBeEmailed    IsTaxIncluded    CustomerSalesTaxCodeRefListID    CustomerSalesTaxCodeRefFullName    CustomerTaxCodeRefListID    CustomerTaxCodeRefFullName    SuggestedDiscountAmount    SuggestedDiscountDate    CustomFieldOther    LinkToTxnID1    Tax1Total    Tax2Total    ExchangeRate    AmountIncludesVAT    CustomFieldEDINetwork    CustomFieldEDIRefNo    CustomFieldEDIStatus

8A6A1-1222137381    23/09/2008 2:36:21 a.m.    23/09/2008 2:36:21 a.m.    1222137381    68136    80001156-1222137253    Sh*** Limited    20000-1201577790    Pon    2C0000-1182395184    Accounts Receivable    60000-1173393480    FM Invoice    26/08/2008    All    1015371    Sh*** Limited                                                Sh*** Limited                                                                                        False    False                26/08/2008                26/08/2008            88.89            12.5    11.11                False    False       

There are no associated payment for this invoice.

This environment is running QBs Pro 2008/09 QBi and QODBC v9.00.00.253

On a side note I am still wondering why IsPaid field has been removed... 

  Top 
  Tom 
  6c3c1_sdk-qodbc.gif
 Group: Administrator 
 Posts: 5510 
 Joined: 2006-02-17 
 Profile
 Posted : 2008-12-06 09:58:52

It's kind of hard to work out what's wrong with this complex method. Try stripping it back to the basics:

INSERT INTO ReceivePaymentLine (CustomerRefListID, DepositToAccountRefListID, TotalAmount, AppliedToTxnTxnID, AppliedToTxnPaymentAmount, TxnDate, FQSaveToCache) Values ('80001171-1228276005', '2D0000-1182395224', 100.00,
'8A6A1-1222137381', 100.00, {d'2008-11-03'} ,0)

and go from there. The "IsPaid" really applies to Invoice headers only.

 

  Top 
  Dmitry S 
  
 Group: Members 
 Posts: 13 
 Joined: 2008-09-18 
 Profile
 Posted : 2008-12-08 10:45:01
Thanks Tom.

I did try using just the Insert Into ..Lines - same result...

And I cannot use the ISPaid column on Invoice table either - running Select TxnID,IsPaid From Invoice Where refnumber='ORD0013478' gives me
ODBC SqlState:        42S00
Native Error Code:    11021
[QODBC] Column not found: IsPaid 

  Top 
  Tom 
  6c3c1_sdk-qodbc.gif
 Group: Administrator 
 Posts: 5510 
 Joined: 2006-02-17 
 Profile
 Posted : 2008-12-08 20:51:02

What does:

Select * from Invoice where TxnID='8A6A1-1222137381'

return?

 

  Top 
  Dmitry S 
  
 Group: Members 
 Posts: 13 
 Joined: 2008-09-18 
 Profile
 Posted : 2008-12-09 06:47:25
The result of Select * from Invoice where TxnID='8A6A1-1222137381' is in my first post in blue after the queries for inserting payment. Cheers.
 

  Top 
  Dmitry S 
  
 Group: Members 
 Posts: 13 
 Joined: 2008-09-18 
 Profile
 Posted : 2008-12-12 10:05:08
Tom, any comments on the absence of the IsPaid field?.. 

  Top 
  Tom 
  6c3c1_sdk-qodbc.gif
 Group: Administrator 
 Posts: 5510 
 Joined: 2006-02-17 
 Profile
 Posted : 2008-12-14 16:52:58

I need a screen dump of:

sp_columns invoice

and

sp_columns invoiceline

using VB Demo showing the columns of the table. (See: How do I upload images to my forum post? )

 

  Top 
  Dmitry S 
  
 Group: Members 
 Posts: 13 
 Joined: 2008-09-18 
 Profile
 Posted : 2008-12-15 08:22:44
Here they are:
sp_columns invoice

sp_columns invoiceline

Thanks.
 

  Top 
  Dmitry S 
  
 Group: Members 
 Posts: 13 
 Joined: 2008-09-18 
 Profile
 Posted : 2009-01-12 08:14:34
Merry Christmas and Happy New Year Tom! Any news on this issue? 

  Top 
  Tom 
  6c3c1_sdk-qodbc.gif
 Group: Administrator 
 Posts: 5510 
 Joined: 2006-02-17 
 Profile
 Posted : 2009-01-12 12:24:38
The IsPaid missing bug was reported to the QODBC Software Engineer on QSupport Ticket ID: BR00000095 dated 15 Dec 2008 08:53:25. It has to do with Intuit adding SDK 6.1 as opposed to calling it 6.0. We have some fields that got redefined in 7.0 so we had last version 6.0 on the old field and those should have been changed to 6.1 when that was added. We have fixed them and will let you know when a hot fix is available. Fix should be in version QODBC v9.00.00.256 or above.
 

  Top 
  Dmitry S 
  
 Group: Members 
 Posts: 13 
 Joined: 2008-09-18 
 Profile
 Posted : 2009-01-12 12:50:57
Thanks Tom. Looking forward to the fix. 

  Top 
  Nick B 
  
 Group: Members 
 Posts: 1 
 Joined: 2009-02-04 
 Profile
 Posted : 2009-02-04 15:50:15
Hi Tom, I was wondering if there was any news on if the hot fix has been released for this issue thanks? 

  Top 
  Tom 
  6c3c1_sdk-qodbc.gif
 Group: Administrator 
 Posts: 5510 
 Joined: 2006-02-17 
 Profile
 Posted : 2009-02-04 17:14:10
Fix should be in version QODBC v9.00.00.256 or above..... whenever that happens. Sorry but I have no control over the programming team. 

  Top 
 New Topic 
 
 Post Reply 
[1]  

Jump to