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 : EstimateLineGroupQuantity failingSearch Forum

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

 New Topic 
 
 Post Reply 
[1]  
 EstimateLineGroupQuantity failing 
 Author   Message 
  jeff 
  
 Group: Members 
 Posts: 76 
 Joined: 2006-06-03 
 Profile
 Posted : 2006-07-28 11:26:03

When attempting to run the following query to insert a new group item with a group quantity the qodbc returns "Error parsing xml return string"

Insert into EstimateLine (TxnId,EstimateLineGroupItemGroupRefListID,EstimateLineGroupQuantity,FQSaveToCache) Values ('24E2-1197762395','1C0000-934380927',2,false)

Is this not possible?

 

  Top 
  Tom 
  6c3c1_sdk-qodbc.gif
 Group: Administrator 
 Posts: 5510 
 Joined: 2006-02-17 
 Profile
 Posted : 2006-07-28 12:04:01

Let's start by creating a new itemgroup example with three lines using QODBC. Note the FQSaveToCache field, set to True except on the last one.

INSERT INTO "ItemGroupLine" ("Name", "IsActive", "ItemDesc", "IsPrintItemsInGroup", "ItemGroupLineItemRefListID", "ItemGroupLineQuantity", "FQSaveToCache") VALUES ('Test1 W3 Lines 1', 1, 'Test Item Desc', 1, '390000-1071512145', 1.0, 1)

INSERT INTO "ItemGroupLine" ("Name", "IsActive", "ItemDesc", "IsPrintItemsInGroup", "ItemGroupLineItemRefListID", "ItemGroupLineQuantity", "FQSaveToCache") VALUES ('Test1 W3 Lines 2', 1, 'Test Item Desc', 1, '320000-1071525597', 2.0, 1)

INSERT INTO "ItemGroupLine" ("Name", "IsActive", "ItemDesc", "IsPrintItemsInGroup", "ItemGroupLineItemRefListID", "ItemGroupLineQuantity", "FQSaveToCache") VALUES ('Test1 W3 Lines 3', 1, 'Test Item Desc', 1, '10000-933272655', 3.0, 0)

and the result looks like this in QuickBooks 2006:



To locate the ListID of the new Item Group (or any group), simply do:

SELECT ListID, Name, ItemDesc, IsActive FROM ItemGroup

We can now create a Estimate using the item group with a group qauntity of 2 by using the ListID: '580000-1197762645' and doing one simple QODBC insert statement:

INSERT INTO "EstimateLine" ("CustomerRefListID", "RefNumber",
"EstimateLineGroupItemGroupRefListID","EstimateLineGroupQuantity", "FQSaveToCache")
VALUES ('470001-1071525403', 'Group5', '580000-1197762645', 2, 0)

When we look at the new invoice in QuickBooks 2006 we will see:

Note: The Qty, Rate and the Amount are shown as 0 for Floor Plans and Concrete Slab, not because QODBC made a mistake. You simply need to correct the rate for the service or stock item:  

 

  Top 
  jeff 
  
 Group: Members 
 Posts: 76 
 Joined: 2006-06-03 
 Profile
 Posted : 2006-07-29 03:32:36

Thanks for your help, that worked perfectly. I've got another question though.

How can I add a new GroupLineItem to an existing estimate? I tried adding the TxnID but it gives me the xml parse error and I also tried TxnNumber and I get an error saying that this field is not allowed in the insert. I also tried RefNumber but this just created a new estimate.

 

  Top 
  Tom 
  6c3c1_sdk-qodbc.gif
 Group: Administrator 
 Posts: 5510 
 Joined: 2006-02-17 
 Profile
 Posted : 2006-07-29 09:12:04

The correct method is to use the TxnID of the existing Estimate as the first column like this: 

INSERT INTO "EstimateLine" ("TxnID",  "EstimateLineGroupItemGroupRefListID","EstimateLineGroupQuantity")
VALUES ('5D12-1197769937'  '580000-1197762645'3 )

but you must be using QODBC v6.00.00.176 (or later).

 

  Top 
  jeff 
  
 Group: Members 
 Posts: 76 
 Joined: 2006-06-03 
 Profile
 Posted : 2006-08-01 04:08:39

I have downloaded and installed version 6.00.00.176. I am using the VB Tester running the following query with no success.

INSERT INTO "EstimateLine" ("TxnID", "EstimateLineGroupItemGroupRefListID","EstimateLineGroupQuantity") values ('2505-1197738013','1C0000-934380927',2)

Still gettting "Error parsing complete xml return string"

 

  Top 
  Tom 
  6c3c1_sdk-qodbc.gif
 Group: Administrator 
 Posts: 5510 
 Joined: 2006-02-17 
 Profile
 Posted : 2006-08-01 10:36:44

Sorry, you are correct, this is due to a bug in QODBC v6.00.00.182:

2006-07-31 17:26:21 QODBC Ver:  6.00.00.182 *********************************************************************************************************************
IsAService: False
SQL Statement: INSERT INTO "EstimateLine" ("TxnID",  "EstimateLineGroupItemGroupRefListID", "EstimateLineGroupQuantity") VALUES ('5D12-1197769937',  '580000-1197762645', 3 )
Error parsing complete XML return string (8)
Input XML:
<?xml version="1.0" encoding="ISO-8859-1"?>
<?qbxml version="5.0"?>
<QBXML>
    <QBXMLMsgsRq onError = "continueOnError" responseData = "includeNone">
        <EstimateModRq requestID = "1">
            <EstimateMod>
                <TxnID>5D12-1197769937</TxnID>
                <EditSequence>1197769937</EditSequence>
                <EstimateLineGroupMod>
                    <TxnLineID>5D14-1197769937</TxnLineID>
                    <EstimateLineMod>
                        <TxnLineID>5D15-1197769937</TxnLineID>
                    </EstimateLineMod>
                    <EstimateLineMod>
                        <TxnLineID>5D16-1197769937</TxnLineID>
                    </EstimateLineMod>
                    <EstimateLineMod>
                        <TxnLineID>5D17-1197769937</TxnLineID>
                    </EstimateLineMod>
                </EstimateLineGroupMod>
                <EstimateLineGroupMod>
                    <ItemGroupRef>
                        <ListID>580000-1197762645</ListID>
                    </ItemGroupRef>
                    <TxnLineID>-1</TxnLineID>
                    <Quantity>3.00000</Quantity>
                </EstimateLineGroupMod>
            </EstimateMod>
        </EstimateModRq>
    </QBXMLMsgsRq>
</QBXML>

20060731.172621 I 2784 QBSDKProcessRequest Application named 'FLEXquarters QODBC' starting requests (process 2220).
20060731.172621 E 2784 XercesSAXErrorHandler Element 'ItemGroupRef' is not valid for content model: '(TxnLineID,ItemGroupRef?,Quantity?,EstimateLineMod*)' -- error at line 7, column 536 in XML data.
20060731.172621 I 2784 MsgSetHandler Parser error, finishing.
20060731.172621 I 2784 QBSDKProcessRequest Application named 'FLEXquarters QODBC' finishing requests (process 2220), ret = 1.
20060731.172621 E 2220 RequestProcessor Process Request error = 80042500, There was an error when parsing the provided XML file.

This bug has been reported. You will need to use the QuickBooks user interface in the meantime.

 

  Top 
  Tom 
  6c3c1_sdk-qodbc.gif
 Group: Administrator 
 Posts: 5510 
 Joined: 2006-02-17 
 Profile
 Posted : 2006-08-14 10:52:26

This has now been fixed in QODBC v6.00.00.186 (or later):

INSERT INTO "EstimateLine" ("TxnID", "EstimateLineGroupItemGroupRefListID",
"EstimateLineGroupQuantity")
VALUES ('5D12-1197769937', '580000-1197762645', 3 )

 

  Top 
 New Topic 
 
 Post Reply 
[1]  

Jump to