Plug-ins > FM Books Connector

Query Item Custom Fields

<< < (2/2)

Geoffrey Gerhard:
Hard to guess why FMP crashes, but the Set Field By Name is the likely candidate--it's not pointing at a valid field name. Change "DateExtName" to "DataExtName" and see if that stops the crash. (It might not; Are there additional Custom Fields that are returned in the Query Response?)

HTH!

Geoffrey Gerhard
Creative Solutions Incorporated
14000 Creekside Drive
Matthews, NC  28105
704) 814-6852

smcgovern:
Geoffrey,

Thanks for catching my typo there.  Unfortunately that still did not catch the issue.  I'm copying below the XML response for one record being retrieved:

<ItemInventoryRet>
            <ListID>80001074-1393001953</ListID>
            <TimeCreated>2014-02-21T11:59:13-05:00</TimeCreated>
            <TimeModified>2017-05-17T11:54:41-05:00</TimeModified>
            <EditSequence>1484928145</EditSequence>
            <Name>AE-0001</Name>
            <FullName>AE-0001</FullName>
            <BarCodeValue>AE-0001</BarCodeValue>
            <IsActive>true</IsActive>
            <ClassRef>
               <ListID>80000012-1482244336</ListID>
               <FullName>ACES</FullName>
            </ClassRef>
            <Sublevel>0</Sublevel>
            <ManufacturerPartNumber>1110-007</ManufacturerPartNumber>
            <SalesTaxCodeRef>
               <ListID>80000001-1302541402</ListID>
               <FullName>tax</FullName>
            </SalesTaxCodeRef>
            <SalesDesc>Balcrank - PUMP, 3:1, TRANSFER, LYNX</SalesDesc>
            <SalesPrice>355.57</SalesPrice>
            <IncomeAccountRef>
               <ListID>8000012A-1392986853</ListID>
               <FullName>SALES:Sales - Automotive Equipment</FullName>
            </IncomeAccountRef>
            <PurchaseDesc>Balcrank - PUMP, 3:1, TRANSFER, LYNX</PurchaseDesc>
            <PurchaseCost>197.54</PurchaseCost>
            <COGSAccountRef>
               <ListID>8000012C-1392987211</ListID>
               <FullName>COST OF SALES:COS - Automotive Equipment</FullName>
            </COGSAccountRef>
            <PrefVendorRef>
               <ListID>800005D0-1391461881</ListID>
               <FullName>Balcrank</FullName>
            </PrefVendorRef>
            <AssetAccountRef>
               <ListID>80000128-1392986630</ListID>
               <FullName>Inventory Auto Equipment - ACES</FullName>
            </AssetAccountRef>
            <ReorderPoint>1</ReorderPoint>
            <Max>4</Max>
            <QuantityOnHand>0</QuantityOnHand>
            <AverageCost>174.71</AverageCost>
            <QuantityOnOrder>0</QuantityOnOrder>
            <QuantityOnSalesOrder>1</QuantityOnSalesOrder>
            <DataExtRet>
               <OwnerID>0</OwnerID>
               <DataExtName>Bin</DataExtName>
               <DataExtType>STR255TYPE</DataExtType>
               <DataExtValue>07-10-01-03</DataExtValue>
            </DataExtRet>
            <DataExtRet>
               <OwnerID>0</OwnerID>
               <DataExtName>Category</DataExtName>
               <DataExtType>STR255TYPE</DataExtType>
               <DataExtValue>General Auto Equipment</DataExtValue>
            </DataExtRet>
            <DataExtRet>
               <OwnerID>0</OwnerID>
               <DataExtName>Manufacturer</DataExtName>
               <DataExtType>STR255TYPE</DataExtType>
               <DataExtValue>Balcrank</DataExtValue>
            </DataExtRet>
            <DataExtRet>
               <OwnerID>0</OwnerID>
               <DataExtName>CMC_Code</DataExtName>
               <DataExtType>STR255TYPE</DataExtType>
               <DataExtValue>Repair - 54110</DataExtValue>
            </DataExtRet>
            <DataExtRet>
               <OwnerID>0</OwnerID>
               <DataExtName>ACES_Stock</DataExtName>
               <DataExtType>STR255TYPE</DataExtType>
               <DataExtValue>Yes</DataExtValue>
            </DataExtRet>
         </ItemInventoryRet>

I'm also attaching a shot of the full extraction Loops for the request. 

From what I can tell, the interior Loop for the DataExtRet is never entered into.  Hopefully someone can see my error.  I did go ahead and add all the Custom Fields to the Extract to make sure that wasn't the issue.

Geoffrey Gerhard:
So it's still crashing?

Are there Custom Fields defined that might contain a value?

Have you contacted Productive Computing to see if this is a bug?

Using an Xpath filter in PCQB_ZParseXML on the result of PCQB_SGetXML( "Response" ) also lets you grab custom field data. It avoids the inner Loop and the need to open RelatedRecords, but Xpath has a bit of a learning curve.

HTH!

Geoffrey Gerhard
Creative Solutions Incorporated
14000 Creekside Drive
Matthews, NC  28105
704) 814-6852

smcgovern:
So I did reach out to Productive Computing and received this response:

From what I see in Intuitís OSR, there arenít any custom fields available when making requests for ItemInventoryQuery. Please check the OSR and verify which fields are available for ItemInventoryQuery under SDK version 13 under the qbXML format:
https://developer-static.intuit.com/qbSDK-current/Common/newOSR/index.html

I must be confused as the XML does show the return value for the Custom Fields.

Geoffrey Gerhard:
The reply seems to suggest a misunderstanding--none of the ItemQueryRequests allow you to pass a Custom Field value, but that's not what you're trying to do. Try again, and explain that the problem is extracting the Custom Field values from the Query Response.

HTH!

Geoffrey Gerhard
Creative Solutions Incorporated
14000 Creekside Drive
Matthews, NC  28105
704) 814-6852

Navigation

[0] Message Index

[*] Previous page

Go to full version