none
x12 850 Process using biztalk RRS feed

  • Question

  • Hi ,

    How to save  PO  , PID , N1, DTM  details to sql server database using without loop ( Order and Order Detail table ) . When I map i am getting xml  with repeating PO values . Please  let me know how can i fix this issue

    Thanks

    Jaison

    Tuesday, August 6, 2013 3:10 PM

Answers

All replies

  • Can you provide some more detail on "repeating PO values"?

    Typically, this is because you don't have the appropriate Looping functiods in the map.

    Tuesday, August 6, 2013 3:47 PM
  • Hi Jaison,

    Please excuse me but couldn't get your problem.

    But below are the links which you can check , I hope it helps :

    http://tech-findings.blogspot.co.uk/2013/07/insert-records-in-sql-server-using-wcf.html

    http://tech-findings.blogspot.co.uk/2013/07/insert-records-in-sql-server-using-wcf_5.html


    I hope this helps!!!!!! Please mark as Helpful. If this answers your question, please mark it as "Answered". It will help to reduce visits to same post as it's already answered and will help guys with same question as yours without even posting it . Maheshkumar S. Tiwari|Team lead/Consultant(EDI/EAI)|iVision Software Pvt Ltd, Pune.

    Tuesday, August 6, 2013 6:41 PM
  • Hi ,

    Can you please check the below xml  , when i map its repeating for each PID values . Can we get all PId and PO values in same record (please check line number 72 , 73)

    <ns3:OrderDtltype><ns3:OrdersDtl_LineNo>72</ns3:OrdersDtl_LineNo><ns3:OrdersDtl_ProductId>M3PE515</ns3:OrdersDtl_ProductId><ns3:OrdersDtl_ProductDesc>ZIP IT STUDS</ns3:OrdersDtl_ProductDesc><ns3:OrdersDtl_ReqQty>25</ns3:OrdersDtl_ReqQty><ns3:OrdersDtl_UnitPrice>3.12</ns3:OrdersDtl_UnitPrice><ns3:ordersdtl_ordersno>251519</ns3:ordersdtl_ordersno></ns3:OrderDtltype>-<ns3:OrderDtltype><ns3:OrdersDtl_LineNo>72</ns3:OrdersDtl_LineNo><ns3:OrdersDtl_ProductId>M3PE515</ns3:OrdersDtl_ProductId><ns3:OrdersDtl_ProductColor>ARGENTO</ns3:OrdersDtl_ProductColor><ns3:OrdersDtl_ReqQty>25</ns3:OrdersDtl_ReqQty><ns3:OrdersDtl_UnitPrice>3.12</ns3:OrdersDtl_UnitPrice><ns3:ordersdtl_ordersno>251519</ns3:ordersdtl_ordersno></ns3:OrderDtltype>-<ns3:OrderDtltype><ns3:OrdersDtl_LineNo>72</ns3:OrdersDtl_LineNo><ns3:OrdersDtl_ProductId>M3PE515</ns3:OrdersDtl_ProductId><ns3:OrdersDtl_ProductSize>1SZ</ns3:OrdersDtl_ProductSize><ns3:OrdersDtl_ReqQty>25</ns3:OrdersDtl_ReqQty><ns3:OrdersDtl_UnitPrice>3.12</ns3:OrdersDtl_UnitPrice><ns3:ordersdtl_ordersno>251519</ns3:ordersdtl_ordersno></ns3:OrderDtltype>-<ns3:OrderDtltype><ns3:OrdersDtl_LineNo>73</ns3:OrdersDtl_LineNo><ns3:OrdersDtl_ProductId>M3PE515</ns3:OrdersDtl_ProductId><ns3:OrdersDtl_ProductDesc>ZIP IT STUDS</ns3:OrdersDtl_ProductDesc><ns3:OrdersDtl_ReqQty>65</ns3:OrdersDtl_ReqQty><ns3:OrdersDtl_UnitPrice>4.31</ns3:OrdersDtl_UnitPrice><ns3:ordersdtl_ordersno>251519</ns3:ordersdtl_ordersno></ns3:OrderDtltype>-<ns3:OrderDtltype><ns3:OrdersDtl_LineNo>73</ns3:OrdersDtl_LineNo><ns3:OrdersDtl_ProductId>M3PE515</ns3:OrdersDtl_ProductId><ns3:OrdersDtl_ProductColor>ORO</ns3:OrdersDtl_ProductColor><ns3:OrdersDtl_ReqQty>65</ns3:OrdersDtl_ReqQty><ns3:OrdersDtl_UnitPrice>4.31</ns3:OrdersDtl_UnitPrice><ns3:ordersdtl_ordersno>251519</ns3:ordersdtl_ordersno></ns3:OrderDtltype>-<ns3:OrderDtltype><ns3:OrdersDtl_LineNo>73</ns3:OrdersDtl_LineNo><ns3:OrdersDtl_ProductId>M3PE515</ns3:OrdersDtl_ProductId><ns3:OrdersDtl_ProductSize>1SZ</ns3:OrdersDtl_ProductSize><ns3:OrdersDtl_ReqQty>65</ns3:OrdersDtl_ReqQty><ns3:OrdersDtl_UnitPrice>4.31</ns3:OrdersDtl_UnitPrice><ns3:ordersdtl_ordersno>251519</ns3:ordersdtl_ordersno></ns3:OrderDtltype>

    Wednesday, August 7, 2013 4:29 AM
  • Hi Jaison,

    You need to group based on OrdersDtl_LineNo.

    1. It can be done using XSLT

    Following two articles explain the grouping :

    http://social.technet.microsoft.com/wiki/contents/articles/17985.xslt-muenchian-grouping-biztalk-complex-transformation.aspx

    http://social.technet.microsoft.com/wiki/contents/articles/18845.biztalk-server-2010-grouping-and-debatchingsplitting-inbound-messages-typedpolled-from-wcf-sql-adapter.aspx

    2. It can also be done using Equal and Value mapping functoids.


    I hope this helps!!!!!! Please mark as Helpful. If this answers your question, please mark it as &amp;quot;Answered&amp;quot;. It will help to reduce visits to same post as it&#39;s already answered and will help guys with same question as yours without even posting it . Maheshkumar S. Tiwari|Team lead/Consultant(EDI/EAI)|iVision Software Pvt Ltd, Pune.

    Wednesday, August 7, 2013 7:53 AM