DataSource keywords in Asset Listing inconsistent outputing


(Emily) #1

Matrix Version: 5.5

Hi all,
I am hoping I have somehow just made a small silly error, but I can’t figure this out…

Setup
I have an asset listing which is reading the shadow assets from a CSV DataSource (i.e. reading the Record Sets).
I have customised the Page Contents and set a DataSource Record Set Format Bodycopy to customise, in order to transform the data into an XML output (which can then be imported into Matrix to recreate the assets. Yes, this sounds roundabout but it’s what I’ve been asked to setup, in absence of Server Scripting!)

Problem
The Asset Listing correctly finds the Shadow Assets, and sometimes outputs my %ds__% keywords and sometimes doesn’t.
I copied and pasted the Keywords from the DSRS’s list of keywords, and they are being used in the DSRS’s Format Bodycopy.
I get 3 variations of outputs:

  1. Does not replace at all, and outputs the keyword itself.
  2. Returns as blank.
  3. Substitutes correctly for the DS value for other keywords.

I can’t figure out why it does which in different circumstances…
Notes: ds__student_id is the first keyword in the list, ds__first_name is the second in the list. (See screenshot)

1. Returns the keyword itself: %ds__student_id%. Note that %ds__first_name% returns the proper value!

As a User “set username” command:

<value><![CDATA[%ds__first_name%%ds__student_id%]]></value>

As a Metadata Field “set” command:

<value><![CDATA[%ds__student_id%]]></value>

2. Returns Blank: %ds__student_id% Note that %ds__first_name% returns the proper value!
As a User “set username” command:

<value><![CDATA[%ds__first_name%]]><![CDATA[%ds__student_id%]]>
</value>

As a User “set web path” command:

<path><![CDATA[%ds__student_id%]]></path>

There is no attempt which has the %ds__student_id% replacing correctly. Yet the First Name and Surnames do…?

I tried removing the CDATA just in case, and it didn’t help.


(Emily) #2

Note: Using %data_source_record_set_student_id% does not help; returns as blank when tested on the User Web Path.


(Emily) #3

SOLVED

When uploaded, the default option of “Use First Column as Identifier” was ticked. This seems to have caused Matrix not to be able to then output this column in the keywords (even though the Student ID field is a unique identifier also…). Turning this setting off and re-uploading the CSV file has fixed it.