Skip to Content
avatar image
Former Member

Insert/Update Business Partner contacts or addresses using B1i Event

Hi All,

I am trying to Insert/Update Contacts or Addresses for a Business Partner in integration framework (B1iF). I am using the standard B1i event of "Insert with fallback to update" of BusinessPartners. It is inserting the record once but updating the same with every new record I try to insert!!!

Here is my xsl I am sending as input.

<xsl:template name="B1if.object.schema.BusinessPartners">
	<BPAddresses xmlns="">
		<row>
			<AddressName>
				<xsl:value-of select="$msg/InsertBPAddress/AddressName"></xsl:value-of>
			</AddressName>
			<Street>
				<xsl:value-of select="$msg/InsertBPAddress/Street"></xsl:value-of>
			</Street>
			<Block>
				<xsl:value-of select="$msg/InsertBPAddress/Block"></xsl:value-of>
			</Block>
			<ZipCode>
				<xsl:value-of select="$msg/InsertBPAddress/ZipCode"></xsl:value-of>
			</ZipCode>
			<City>
				<xsl:value-of select="$msg/InsertBPAddress/City"></xsl:value-of>
			</City>
			<County>
				<xsl:value-of select="$msg/InsertBPAddress/County"></xsl:value-of>
			</County>
			<Country>
				<xsl:value-of select="$msg/InsertBPAddress/Country"></xsl:value-of>
			</Country>
			<State>
				<xsl:value-of select="$msg/InsertBPAddress/State"></xsl:value-of>
			</State>
			<FederalTaxID>
				<xsl:value-of select="$msg/InsertBPAddress/FederalTaxID"></xsl:value-of>
			</FederalTaxID>
			<TaxCode>
				<xsl:value-of select="$msg/InsertBPAddress/TaxCode"></xsl:value-of>
			</TaxCode>
			<BuildingFloorRoom>
				<xsl:value-of select="$msg/InsertBPAddress/BuildingFloorRoom"></xsl:value-of>
			</BuildingFloorRoom>
			<AddressType>
				<xsl:value-of select="$msg/InsertBPAddress/AddressType"></xsl:value-of>
			</AddressType>
			<AddressName2>
				<xsl:value-of select="$msg/InsertBPAddress/AddressName2"></xsl:value-of>
			</AddressName2>
			<AddressName3>
				<xsl:value-of select="$msg/InsertBPAddress/AddressName3"></xsl:value-of>
			</AddressName3>
			<TypeOfAddress>
				<xsl:value-of select="$msg/InsertBPAddress/TypeOfAddress"></xsl:value-of>
			</TypeOfAddress>
			<StreetNo>
				<xsl:value-of select="$msg/InsertBPAddress/StreetNo"></xsl:value-of>
			</StreetNo>
			<GlobalLocationNumber>
				<xsl:value-of select="$msg/InsertBPAddress/GlobalLocationNumber"></xsl:value-of>
			</GlobalLocationNumber>
			<Nationality>
				<xsl:value-of select="$msg/InsertBPAddress/Nationality"></xsl:value-of>
			</Nationality>
			<TaxOffice>
				<xsl:value-of select="$msg/InsertBPAddress/TaxOffice"></xsl:value-of>
			</TaxOffice>
		</row>
	</BPAddresses>
</xsl:template>

Can anybody help me in this regard, what I am doing wrong. I am using the same to update the Nth address for example. How can we set the pointer to the Nth address in the XSL so that the specific address gets updated.

Regards

KA

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Best Answer
    avatar image
    Former Member
    Dec 22, 2016 at 12:49 PM

    I have managed to find the solution for the issue above.

    In order to insert/update contacts or addresses in a BP object, we need to send complete object to B1if with the newly add or update contact/address.

    Note we need to send the RowNum (for Address) and InternalCode (for Contact) id in the payload we send to B1iF. System does not include these columns in the BOM auto-generated by B1iF.

    Cheers

    KA

    Add comment
    10|10000 characters needed characters exceeded