I am trying to maintain the ID same as that provided in the EMT.xml
I have followed the steps stated in forge guide and have integrated the EMT but the N values for each ID is getting changed (getting Endeca Defined). I want the N values to remain same as that provided in EMT.
Endeca Developer Studio changes the Dim ID values incase if your values provided in EMT.xml are conflicting with the already existing IDs in Dev Studio.
Just make sure that always you are generating unique & they are not already exists in Dev studio, it will maintain the same provided by you.
Endeca will automatically assign a unique ID for the dimension value, you can't force it to be overwritten with the unique id provided by your taxonomy management system (or database, or whatever). The mapping between your source unique id and the Endeca-generated N id is stored in an XML file in the <your-application>/data/state/ directory on your ITL server. To ensure the ids don't get re-generated you need to ensure this state file is persisted (especially between your staging environment and your production environment, if you use Workbench/Experience Manager to set up rules/pages in Staging and push them to Production).
If you need to translate between the unique id held in your source system and the unique ID assigned by Endeca (the "N" id) as part of the web application logic (for example when transitioning from a Commerce Server-maintained landing page to dynamic Endeca-driven results), you need to either read in the relevant XML file into your web application and cache it for lookups, or do a dimension search on your hiearchical dimension for the name or unique id (if a synonym) and get the Endeca N id from the dimension search result (note do not use a record search for this, only a dimension search).
Hope this helps.
As per the requirement I have to get the category_id fired on selecting any of the Parent category. I was wondering if we can make the category_id itself to behave like N values for the categories instead writing and EMT and caching it work will become easier. If not and EMT based approach what will be the best way to go about it?
Say for example I have an id defined for my wine type say 1234 for red wine and 4567 for white wine.
and I have my external taxonomy created in below mentioned pattern
*<node id="1234" name="REDWINE" parent="380501" search="true">*
*<node id="4567" name="WHITEWINE" parent="1234" search="true">*
I want my Dimensions to look in the following way
*<SYN CLASSIFY="FALSE" DISPLAY="TRUE" SEARCH="TRUE">Red Wine</SYN>*
*<SYN CLASSIFY="FALSE" DISPLAY="TRUE" SEARCH="TRUE">White Wine</SYN>*
That is My dimension id's should be same as that given in external file.
Ah okay - in that case, my answer above still stands. You can't "force" Endeca to use specific N ids, they get assigned automatically to avoid any conflicts. See my previous post about translating between your unique id (1234 or 4567 in your example) and the N id generated by Endeca either at run-time with a dimension search, or by reading in the ./data/state/autogen_dimensions.xml .