Amazon Mapping. Retrieving Codes from RMS alias feed

Pulling EAN or UPC codes from the RMS Alias field

Some stores save their EAN/UPC codes to the alias table in RMS. The following NscSync Mapping retrieves EANs from the alias table.

<MAPPING TARGET="product_weblinxcustomtext8">(select top 1 alias.alias from alias where itemid = item.id and XXXX)</MAPPING> 

For UPC codes replace XXX with len(alias) = 12
For EAN codes replace XXX with len(alias) = 13

A Mapping to Determine If an Entry is a UPC or EAN

When you need to populate the Standard Product Type with UPC, EAN, etc you can check the top item in the alias field and depending in its length push up the relevant standard product type.

This is the field mapping to insert into the field you want the standard product type to be entered.

(SELECT top 1 (
  CASE WHEN len(alias) = 12 THEN 'UPC' 
       WHEN len(alias) = 13 THEN 'EAN'
  END)
FROM alias 
WHERE itemid = item.id AND(len(alias) = 12 OR len(alias) = 13))

Is it possible to field map “alias” to an editable field in PAM to add Aliases to RMH?

What I have in the “field source” in field mapping. I know it’s not right… where are you pulling this code from?

The bottom one validated but didn’t pull any data. Top one validates if you just put (select top 1 alias.alias from alias where itemid = item.id and len(alias) = 12)

[nitroasl_pamtable].[upctest]

(select top 1 alias.alias from alias where itemid = item.id and len(alias) = 12)

I’m on RMH if that makes a difference.

Hi John,

I’m afraid PAM does not currently support aliases.

We can add it as a feature suggestion if you like, or you can open a ticket to have us review it as a custom development.

Regards,
Donogh