Imported from previous forum
[ original email was from Mohamed Riadh Trad - riadh.trad@gltrade.com ]
Hi,
I have a question concerning the mandatory fields decoding:
The default, copy, and increment operators have the following presence map and NULL utilization:
• Mandatory integer, decimal, string and byte vector fields – one bit. If set, the value appears in the stream.
• Optional integer, decimal, string and byte vector fields – one bit. If set, the value appears in the stream in a nullable representation. A NULL indicates that the value is absent and the state of the previous value is set to empty, except when the default operator is used in which case the state of the previous value is left unchanged.
----• Mandatory integer, decimal, string and byte vector fields – one bit. If set, the value appears in the stream.
Does’t mean that if we have a mandatory field with pmap set to 0, should we rely on the previous value?
Best Regards,
The action to take when the presence bit is zero depends on the operator. For the copy operator the value is the previous value. For the increment operator the value is the previous value incremented by one (this value also becomes the new previous value). For the default operator the value is the initial value (the default operator doesn’t use previous values).
Please see section 6.3 in the FAST Specification 1.1 for the detailed semantics for each field operator.
/David
Hi,
I have a question concerning the mandatory fields decoding:
The default, copy, and increment operators have the following presence
map and NULL utilization: • Mandatory integer, decimal, string and byte
vector fields – one bit. If set, the value appears in the stream. •
Optional integer, decimal, string and byte vector fields – one bit. If
set, the value appears in the stream in a nullable representation. A
NULL indicates that the value is absent and the state of the previous
value is set to empty, except when the default operator is used in which
case the state of the previous value is left unchanged.----• Mandatory integer, decimal, string and byte vector fields – one
bit. If set, the value appears in the stream.Does’t mean that if we have a mandatory field with pmap set to 0, should
we rely on the previous value?Best Regards,
[ original email was from Mohamed Riadh Trad - riadh.trad@gltrade.com ]
Hi,
Thank you for your help;
In the case of optional value, if the pmap is set to zero, should we ommit the field and not rely on the previos or default value? in that case we consider that the optional field is not present in our message?
Regards,
Riadh
The action to take when the presence bit is zero depends on the
operator. For the copy operator the value is the previous value. For the
increment operator the value is the previous value incremented by one
(this value also becomes the new previous value). For the default
operator the value is the initial value (the default operator doesn’t
use previous values).Please see section 6.3 in the FAST Specification 1.1 for the detailed
semantics for each field operator./David
Hi,
I have a question concerning the mandatory fields decoding:
The default, copy, and increment operators have the following presence
map and NULL utilization: • Mandatory integer, decimal, string and
byte vector fields – one bit. If set, the value appears in the stream.
• Optional integer, decimal, string and byte vector fields – one bit.
If set, the value appears in the stream in a nullable representation.
A NULL indicates that the value is absent and the state of the
previous value is set to empty, except when the default operator is
used in which case the state of the previous value is left unchanged.----• Mandatory integer, decimal, string and byte vector fields – one
bit. If set, the value appears in the stream.Does’t mean that if we have a mandatory field with pmap set to 0,
should we rely on the previous value?Best Regards,
The presence property (optional or mandatory) is generally independent from the use of a bit in the pmap (only the constant operator and groups use a bit in the pmap to express the logical presence or absence of a value/group).
If a field is optional, it typically indicates that the field should be encoded in a nullable representation, and that the special value NULL is used to indicate absence of a value.
If you for example decode an optional field with a copy operator, then if the corresponding bit in the pmap is zero and if the state of the previous value is Empty, then also this instance of the field is Empty (absent). If the state of the previous value is Assigned, the also this instance of the field is Assigned (i.e, has a value that is not NULL).
/David
Hi,
Thank you for your help;
In the case of optional value, if the pmap is set to zero, should we
ommit the field and not rely on the previos or default value? in that
case we consider that the optional field is not present in our message?Regards, Riadh
The action to take when the presence bit is zero depends on the
operator. For the copy operator the value is the previous value. For
the increment operator the value is the previous value incremented by
one (this value also becomes the new previous value). For the default
operator the value is the initial value (the default operator doesn’t
use previous values).Please see section 6.3 in the FAST Specification 1.1 for the detailed
semantics for each field operator./David
Hi,
I have a question concerning the mandatory fields decoding:
The default, copy, and increment operators have the following
presence map and NULL utilization: • Mandatory integer, decimal,
string and byte vector fields – one bit. If set, the value appears
in the stream. • Optional integer, decimal, string and byte vector
fields – one bit. If set, the value appears in the stream in a
nullable representation. A NULL indicates that the value is absent
and the state of the previous value is set to empty, except when the
default operator is used in which case the state of the previous
value is left unchanged.----• Mandatory integer, decimal, string and byte vector fields –
one bit. If set, the value appears in the stream.Does’t mean that if we have a mandatory field with pmap set to 0,
should we rely on the previous value?Best Regards,