tw102609 opened a new issue, #7677:
URL: https://github.com/apache/hop/issues/7677

   ### Apache Hop version?
   
   2.18.1
   
   ### Java version?
   
   21
   
   ### Operating system
   
   Linux
   
   ### What happened?
   
   Environment
   Apache Hop 2.18.1
   Official Docker image (apache/hop:2.18.1)
   Linux (Docker)
   Windows 11
   Java 21
   SQL Server (Microsoft JDBC 13.4.0)
   Summary
   
   When running the same project and workflow:
   
   Windows GUI preserves empty strings.
   Windows hop-run preserves empty strings.
   Linux hop-run (official Docker image) converts empty strings to NULL.
   
   This occurs even though HOP_EMPTY_STRING_DIFFERS_FROM_NULL=Y is supplied 
through every supported mechanism we could identify.
   
   Expected behavior
   
   When
   
   HOP_EMPTY_STRING_DIFFERS_FROM_NULL=Y
   
   is configured,
   
   empty strings ("") should remain empty strings during pipeline execution and 
be written to SQL Server as '', not NULL.
   
   This is the behavior observed on Windows.
   
   Actual behavior
   
   On Linux using the official Docker image:
   
   Empty strings become NULL.
   Inside the pipeline:
   Get Variables
   
   reports
   
   HOP_EMPTY_STRING_DIFFERS_FROM_NULL = N
   
   despite every configuration source specifying Y.
   
   Reproduction
   
   Environment JSON contains
   
   {
     "variables": [
       {
         "name": "HOP_EMPTY_STRING_DIFFERS_FROM_NULL",
         "value": "Y"
       }
     ]
   }
   
   Docker also receives
   
   -e HOP_EMPTY_STRING_DIFFERS_FROM_NULL=Y
   
   and
   
   -e 
HOP_CONFIG_OPTIONS="--config-file-set-variables=HOP_EMPTY_STRING_DIFFERS_FROM_NULL=Y"
   
   The startup script confirms before Hop starts:
   
   Shell variable:
   HOP_EMPTY_STRING_DIFFERS_FROM_NULL=Y
   
   Environment JSON:
   "name": "HOP_EMPTY_STRING_DIFFERS_FROM_NULL"
   "value": "Y"
   
   Process environment:
   HOP_EMPTY_STRING_DIFFERS_FROM_NULL=Y
   
   However, inside the pipeline:
   
   Get Variables
   
   returns
   
   HOP_EMPTY_STRING_DIFFERS_FROM_NULL = N
   Behaviour comparison
   Environment  Get Variables   Result
   Windows GUI  Y       Empty strings preserved
   Windows HopRun       Y       Empty strings preserved
   Linux Docker HopRun  N       Empty strings become NULL
   Minimal pipeline
   
   A minimal pipeline consisting of
   
   Generate Rows
       (String field,
        Set Empty String = Yes)
           |
   Table Output
   
   writes
   
   NULL
   
   to SQL Server on Linux Docker.
   
   The same pipeline writes
   
   ''
   
   (empty string)
   
   on Windows.
   
   Additional investigation performed
   
   Verified:
   
   Same Hop version (2.18.1)
   Same workflow
   Same project
   Same environment JSON
   Same SQL Server JDBC driver
   Same Java major version
   Same SQL Server destination
   
   Verified before pipeline startup:
   
   HOP_EMPTY_STRING_DIFFERS_FROM_NULL=Y
   
   Verified inside pipeline:
   
   HOP_EMPTY_STRING_DIFFERS_FROM_NULL=N
   
   Tried:
   
   Docker ENV
   Environment JSON
   HOP_CONFIG_OPTIONS
   Windows HopRun
   Windows GUI
   Linux HopRun
   
   No configuration change caused Linux HopRun to honor the value.
   
   Question
   
   Is HOP_EMPTY_STRING_DIFFERS_FROM_NULL expected to work under Linux HopRun?
   
   If so, is there another supported mechanism for configuring it in the 
official Docker image?
   
   If not, this appears to be a Linux-specific inconsistency between Windows 
HopRun and Linux HopRun.
   
   ### Issue Priority
   
   Priority: 2
   
   ### Issue Component
   
   Component: Infrastructure, Component: Hop Run


-- 
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