[
https://issues.apache.org/jira/browse/NIFI-10440?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17601986#comment-17601986
]
DEOM Damien commented on NIFI-10440:
------------------------------------
Hi, I managed to find a workaround solution.
You'll find a complete dataflow that
- download a csv file from HDFS
- infer its schema, simplify it
- create a Postgres table that matches that schema
- store the data to the table
You may create a dedicated processor that does all this in fewer steps...
> JsonTreeReader - all strings Schema Access Strategy
> ---------------------------------------------------
>
> Key: NIFI-10440
> URL: https://issues.apache.org/jira/browse/NIFI-10440
> Project: Apache NiFi
> Issue Type: Improvement
> Reporter: DEOM Damien
> Priority: Critical
> Attachments: CSV_importer_-_ADLS_-_Postgres_(Gen).json
>
>
> Similary to CSVReader, JsonTreeReader should have an option to treat all
> values as strings in Schema Access Strategy
>
> It is mandatory in order to avoid cryptic errors like:
>
> PutDatabaseRecord[id=99723f81-545a-13a7-9136-742bda23d870] Failed to put
> Records to database for
> StandardFlowFileRecord[uuid=6e4eae83-83d7-4c42-a3a2-1bf6d72ac121,claim=StandardContentClaim
> [resourceClaim=StandardResourceClaim[id=1662386479395-157,
> container=default, section=157], offset=730137,
> length=231164],offset=0,name=ca3ede75-9b72-4dec-930a-420ae5267b8a,size=231164].
> Routing to failure.: Cannot convert CHOICE, type must be explicit
--
This message was sent by Atlassian Jira
(v8.20.10#820010)