Orchestra default value

@donaldmendelson

How to specify a default (or constant) value of a fieldRef in orchestra?

e.g.
To set a default of a field 123 as “YC: default-value” one wrote it as:

<fixr:field id="123" name="Private" type="string" value="YC: default-value">

And the fieldRef is:
<fixr:fieldRef id="123" instanceName="Private" >

Now, how can one specify that the if the default value of the fieldRef should be “DM: default-value” ?

For more general case please provide examples for:

  1. default value of field
  2. default value of fieldRef
  3. constant value of field
  4. constant value of fieldRef

Thanks in advance

The XSD schema shows the following (see also sub-section “Presence” in https://www.fixtrading.org/standards/fix-orchestra-online/#message-structures-1):

  • fieldType defines the field and contains <fieldAttribGrp>
  • fieldRefType defines the field references and contains <fieldAttribGrp>
  • <fieldAttribGrp> contains attributes presence (default is optional) and value

value is defined as follows:

If presence is optional, then it represents a default when the sender does not provide the field. If presence is constant, then it is the constant value.

<fixr:field id="123"value="DM: default-value">
<fixr:fieldRef id="123" instanceName="Private" value="DM: default-value">

<fixr:field id="123" presence="constant" value="HK: constant-value">
<fixr:fieldRef id="123" instanceName="Private" presence="constant" value="HK: constant-value">

@donaldmendelson to verify and confirm…

1 Like

The default value of a field is addressed in the Orchestra spec in the section Default value of an optional field.

The example given for the default value of TimeInForce:

<fixr:fieldRef id="59" presence="optional" value="0"/>

As Hanno said, the same attributes apply to both <field> for every instance of a field or <fieldRef> for a specific instance.

1 Like