Wednesday 11 February 2015

Default Dimensions seem to be just single field of type long instead of dictionary entity in Connector and in VS

There is probably incorrect Extended Data Type on DefaultDimension field in table. There should be DimensionDefault. If there is another one (e.g. RefRecId) then correct code is not generated by AIF wizard to Ax<Table> class and to Data object class.

If you can change EDT then do it and regenerate AxBC classes and data objects.

If you can’t change EDT or regeneration did not help then update classes manually:

Ax<Table> class: 
change EDT in parmDefaultDimension method to "DimensionDefault"

<Service>_<Table> class:

add method createDefaultDimension

public AifDimensionAttributeValueSet createDefaultDimension()
{
    return this.get_NewContainer(#DefaultDimension);
}

change method parmDefaultDimension

public AifDimensionAttributeValueSet parmDefaultDimension(AifDimensionAttributeValueSet _value = null)
{
    if (!prmisDefault(_value))
    {
        this.set_Container(#DefaultDimension, _value);
    }
    return this.get_Container(#DefaultDimension);
}