thswlsqls opened a new issue, #10375:
URL: https://github.com/apache/paimon/issues/10375

   **Search before asking**
   - [x] I searched in the [issues](https://github.com/apache/paimon/issues) 
and found nothing similar.
   
   **Paimon version**
   master @ b0af45681
   
   **Compute Engine**
   Spark (format table)
   
   **Minimal reproduce step**
   `CREATE TABLE t (id INT, name STRING) USING json TBLPROPERTIES 
('lineSep'='|')`, then read or write it with the default 
`format-table.implementation=paimon`.
   
   `JsonOptions.LINE_DELIMITER` (`json.line-delimiter`) has no fallback key, so 
`JsonFileReader` and `JsonFormatWriter` use `\n`. `CsvOptions.LINE_DELIMITER` 
and `TextOptions.LINE_DELIMITER` already accept `lineSep` via 
`withFallbackKeys("lineSep")`.
   
   **What doesn't meet your expectations?**
   `lineSep` is Spark's JSON option name. The `engine` implementation honours 
it, but the default `paimon` implementation ignores it, so the same table reads 
and writes differently depending on the implementation.
   
   **Anything else?**
   Proposed fix: add `.withFallbackKeys("lineSep")` to 
`JsonOptions.LINE_DELIMITER`, same as #9170/#9565 did for CSV.
   
   **Are you willing to submit a PR?**
   - [x] I'm willing to submit a PR!
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to