NX.env in C:\ takes precedence over the one in SDM home folder.
The following error appears in stdlog:
WARNING: An NX.env file was found at C:/NX.env. Values entered here will override the values from the NX.env file in the NX_ROOT directory and may cause unexpected side-effects.
17.x
This is expected behavior. To avoid this issue from occurring, remove the NX.env from the C:\ root directory so it takes the one located under the NX_ROOT folder.