Usage of dataDefinition - Export/Import - Questions

Hi there,
how can I export relation-data with dataDefinitions
I tried many combinations but only getting errors or nothing.
I have different relational-data - here I want to export many-to-many relation. (CoreShopProduct - CoreShopCategory)

I’d like to try with Interpreter twig - but how to define it correctly?
As result I’m just getting all I’m entering in template field. No rendering of template.

I tried to define the path of twig template. or the content of template. It’s just printing as result what I’m typing into field Template.

Another question - for interpreter conditional.
Are there some examples how conditions should look like?
I’m trying as condition: id !== null but doesnt seem to work. Or how can I check if there is an relation defined or not? And output if data exists?

How can I export metadata-information of the relation?

How to reference to field/oject-data in condition correctly? Is it possible or not?

So many questions

pimcore 6.6.7, coreshop 2.2, dataDefintions 3.1.0

The twig interpreter passes the data given (value) into the rendering engine and renders the content (=twig template).

if you are working with relational data, the conditional interpreter does not make a lot of sense for you. You’ll get passed a array, that is never false, also you don’t get ‘id’ passed, you get value passed.

Best option:

 - nested
     - iterator
     - nested
        - expression: value.id
 - expression: implode(', ', value) //for csv or excel export, if xml, ignore this step

Meta Information meaning fields from a relation?

 - nested
     - iterator
     - nested
        - expression: value.name
 - expression: implode(', ', value) //for csv or excel export, if xml, ignore this step

Condition:
That is a symfony expression being evaluated, if you wanna check for field name if null:

value.name == null

if true, the true interpreter gets executed next, if not, the false interpreter is executed.