Developer forum

Forum » Integration » Import specific product with test tool from NAV

Import specific product with test tool from NAV

Eva Sommer
Reply

Hi,

Is it possible to pick one specific product with the testtool from NAV? 
<GetEcomData Qty="10" ><tables><Products type="all" setLanguage="DAN" importProductProperties="true" /></tables></GetEcomData>

And is it possible to not set web counter. Sometimes we run into not getting any products, and the NAV guy has to reset the counter.

- Thanks


Replies

 
Dmitriy Benyuk Dynamicweb Employee
Dmitriy Benyuk
Reply

Hi Eva,

for querying specific product/products you can run the query like that:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<GetEcomData ExternalUserId="E000010" AccessUserCustomerNumber="20000">
<tables>
<Products type="filter" unitPrices="true">
<Product>
<ProductId>1896-S</ProductId>
<ProductVariantId>LONGVARIAN</ProductVariantId>
<ProductNumber>1896-S</ProductNumber>
<ProductUnitId>Unit_STK</ProductUnitId>
<ProductIdentifier>1896-S.LONGVARIAN.ENU</ProductIdentifier>
<CurrencyCode>EUR</CurrencyCode>
<Quantity>1</Quantity>
</Product>
<Product>
<ProductId>1896-S</ProductId>
<ProductVariantId></ProductVariantId>
<ProductNumber>1896-S</ProductNumber>
<ProductUnitId>Unit_STK</ProductUnitId>
<ProductIdentifier>1896-S..ENU</ProductIdentifier>
<CurrencyCode>EUR</CurrencyCode>
<Quantity>1</Quantity>
</Product>
</Products>
</tables>
</GetEcomData>

For resetting the Dynamicweb counter you need to add the attribute ReimportTable="true" into the query:
<GetEcomData Qty="10" ReimportTable="true"><tables><Products type="all" setLanguage="DAN" importProductProperties="true" /></tables></GetEcomData>
ReimportTable - This resets the checkpoint for delta tracking to 0 so all records will be imported again. 
CustomModifier - Allows you to have multiple site connected to the same ERP where each site gets its own set of deltas. Useful if you have a B2B and B2C site for example and want the changes from the ERP on both.


BR, Dmitrij
 
Eva Sommer
Reply

Thank you for your reply, and great that one product can be queried. Is it possible to query for one only using the id ?

Eksample of a product when query with: <GetEcomData Qty="1" ><tables><Products type="all" setLanguage="DAN" /></tables></GetEcomData>

<?xml version="1.0" encoding="utf-16"?>
<tables version="1.2.0.0.1_NAV1.0.23019">
  <table tableName="EcomProducts">
    <item table="EcomProducts">
      <column columnName="ProductID"><![CDATA[397855]]></column>
      <column columnName="ProductLanguageID"><![CDATA[DAN]]></column>
      <column columnName="ProductVariantID"><![CDATA[]]></column>
      <column columnName="ProductNumber"><![CDATA[100  11,91   6]]></column>
      <column columnName="ProductName"><![CDATA[FP01XR     11,91 X 2,62 FDA]]></column>
      <column columnName="ProductShortDescription"><![CDATA[]]></column>
      <column columnName="ProductPrice"><![CDATA[0,00]]></column>
      <column columnName="ProductStock"><![CDATA[224]]></column>
      <column columnName="ProductWeight"><![CDATA[0]]></column>
      <column columnName="ProductVolume"><![CDATA[0]]></column>
      <column columnName="ProductManufacturerID"><![CDATA[1700]]></column>
      <column columnName="ProductActive"><![CDATA[true]]></column>
      <column columnName="ProductVariantCounter"><![CDATA[0]]></column>
      <column columnName="ProductDefaultUnitID"><![CDATA[Unit_STK]]></column>
      <column columnName="ProductEAN"><![CDATA[]]></column>
    </item>
  </table>
</tables>

 
Dmitriy Benyuk Dynamicweb Employee
Dmitriy Benyuk
Reply
This post has been marked as an answer

Yes, it is possible, but you are using wrong query. Look one more time on mine first query. Also you can copy the query for just one product from here:
https://doc.dynamicweb.com/documentation-9/integration/integration-framework/erp-plug-in-units/live-intetegration-requests-and-responses.
Full list of requests and responses is here.
 

Votes for this answer: 1
 
Eva Sommer
Reply

Ah perfekt, thank you :)

 

You must be logged in to post in the forum