Does the FIX spec specify anything about the position of the fields of a component block in message?
For instance with repeating groups, the first field is required each instance of the repeating group must start with that first required field and all the repeating groups must be one after the other with no other fields in between. Is there any type of similar requirement for the fields in a component block? I was looking for a requirement that all the fields in the component block must appear together without other fields mixed in, but I didn’t find anything like that.
That depends on the encoding you have chosen. I assume you are asking about tag=value encoding where it is not explicitly specified but I would consider it to be bad practice as it makes it harder to grasp the semantics of a message (in the documentation). Is there any reason why it would make sense? Your tag=value parser does not have to be aware of components as opposed to repeating groups. In general, the recipient of a FIX message should be as flexible as possible and the sender should be as compliant as possible.
It is an error for other encodings, especially FIXML, i.e. whenever components are visible on the wire level or in the meta data.
Thanks for the response. My component block question was referring to the tag=value format. We’re coding a sub-system which is used to create reject messages from inbound business messages. If there was a requirement for component blocks similar to repeating groups, then the coding would have been a bit easier, but it’s not clear that that is not the case. Since we’re the recipients of the business messages, we’ll follow the guidance to be a flexible as possible with the inbound messages and make the outbound messages we send as compliant as possible.
1 Like