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 : Using FQSaveToCache on large InvoicesSearch Forum

Forum Home > QODBC - ODBC Driver for QuickBooks > QODBC v7 Forum

 New Topic 
 
 Post Reply 
[1]  
 Using FQSaveToCache on large Invoices 
 Author   Message 
  KofK 
  
 Group: Members 
 Posts: 43 
 Joined: 2006-04-04 
 Profile
 Posted : 2007-05-03 03:20:44

I am trying to write an invoice that has a few hundred lines using FQSaveToCache.

The problem that I'm having is that as the invoice grows, each query takes longer and longer to execute even though FQSaveToCache = 1.

I tried to process the invoice in batches of a hundred but the problem still exists.

I thought that when using FQSaveToCache, QODBC doesnt query QuickBooks until FQSaveToCache = 0 so why does it make a difference as to how many lines there are?

I currently do not have the Optimizer on will it help to turn it on for INSERT statements?

(I am using QuickBooks Pro 2007 and QODBC 7.00.00.214)

 

  Top 
  Tom 
  6c3c1_sdk-qodbc.gif
 Group: Administrator 
 Posts: 5510 
 Joined: 2006-02-17 
 Profile
 Posted : 2007-05-03 10:58:56

This is not quite what we had in mind when using QODBC. Yes, the QODBC optimizer should be on, but it makes no difference when doing INSERTs. What you need to do is to first create the first line of the Invoice and then add each invoice line to the newly created invoice as shown using the Plan B technique in:  Using ClassRefListID when inserting invoice lines

 

  Top 
  KofK 
  
 Group: Members 
 Posts: 43 
 Joined: 2006-04-04 
 Profile
 Posted : 2007-05-03 11:23:09

Here is what I tried.

I inserted the first record setting FQSaveToCache = 0, the next two hundred records I set FQSaveToCache = 1 and used the TxnID (SP_LASTINSERTID) of the first line. The problem still exists that as it loops through the 200 records it gets slower and slower. (after about 150 it takes almost 20 seconds to execute)

 

  Top 
  Tom 
  6c3c1_sdk-qodbc.gif
 Group: Administrator 
 Posts: 5510 
 Joined: 2006-02-17 
 Profile
 Posted : 2007-05-03 11:30:58
I believe you, I don't think I've every seen anyone that expected the Intuit qbXML SDK to write so many invoice lines, so the more lines the slower it becomes to add lines. Most likely the underlying SDK code by Intuit needs optimizing, not something we can do, sorry. 

  Top 
  KofK 
  
 Group: Members 
 Posts: 43 
 Joined: 2006-04-04 
 Profile
 Posted : 2007-05-03 11:42:17

Thanks for the reply.

When I use FQSaveToCache = 1 does it query QuickBooks at all or is it stored until FQSaveToCache =0?

If it's stored why would it make a difference as to the number of invoice lines?

 

  Top 
  Tom 
  6c3c1_sdk-qodbc.gif
 Group: Administrator 
 Posts: 5510 
 Joined: 2006-02-17 
 Profile
 Posted : 2007-05-03 12:29:33
That's because everything is still processed apart for the actual commit operation. 

  Top 
 New Topic 
 
 Post Reply 
[1]  

Jump to