Hello,
In FeatureWriter, User Attributes,
I want to use a User Parameter as the name of my primary key.
User Parameter (in french: Primary key name)

Feature Writer (not working)

Hello,
In FeatureWriter, User Attributes,
I want to use a User Parameter as the name of my primary key.
User Parameter (in french: Primary key name)
Feature Writer (not working)
Hi
Thank you for the post!
You could try using the AttributeRenamer before the FeatureWrtier.
Let’s say:
Your incoming features have a dynamic attribute that should be the primary key.
You know the name of that attribute from a user parameter.
You can rename that attribute to a consistent name.
Use an AttributeRenamer before the FeatureWriter.
Set:
Source Attribute: @Value(PrimaryKeyName)
Destination Attribute: pk_field
In the FeatureWriter, set Primary Key Name to pk_field
Let me know if this works!
Hello
Thank you for your response.
I think I was not clear on what I want to achieve.
I want the primary key name that my user choses be the one to use to define the primary key in my PostGIS table.
For example, if my user choses test_pk as the name of the primary key, it is test_pk to be used as the primary key and not pk_field.
The user expects to see test_pk as a primary key in his postgres tables.