Troubleshooting > ThirdPartyIssues > Resolving Empty Environment Variable Contents on Japanese Windows XP

Resolving Empty Environment Variable Contents on Japanese Windows XP

Article #: Product: Version:

Summary

When running a DMExpress task that references environment variables on Japanese localized versions of Windows XP, environment variables whose contents are at least 1024 bytes in size may be incorrectly evaluated as empty.

This behavior is caused by a bug in Japanese localized versions of Windows XP where environment variable contents are not retrieved as expected under certain conditions.

To resolve the problem, divide the contents of the environment variable among multiple shorter environment variables or upgrade to Windows Vista or Windows 7

Symptom

Environment variables whose contents are at least 1024 bytes in length may be evaluated as empty in DMExpress tasks run on Japanese localized versions of Windows XP. This may cause incorrect output in tasks that depend on these environment variables.

For instance, if an environment variable $VAR is defined with a value at least 1024 bytes in size on an affected system, a DMExpress value defined as abc $VAR xyz can evaluate as abc xyz even though $VAR contains data.

When the environment variable’s contents are at least 1024 bytes in length, whether or not the problem occurs depends on the exact contents of the variable. The problem has only been reported when the environment variable contains a combination of both ASCII and Shift JIS data. Even in this case, the problem only appears for some data sizes.

Resolution

To resolve the problem, avoid storing more than 1023 bytes of data in any environment variables that will be used in a DMExpress task if you expect to run the task on a Japanese localized version of Windows XP.

If you must retrieve at least 1024 bytes of data from the environment, you can divide the intended contents of the environment variable among multiple new variables that are 1023 bytes or smaller. You can then use these variables in sequence within the appropriate field in DMExpress.

For instance, you can split the contents of the environment variable $VAR between two new variables, $VAR1 and $VAR2, each of which is smaller than 1024 bytes. You could then replace $VAR with $VAR1$VAR2 in your DMExpress task.

Alternatively, upgrade to Windows Vista or Windows 7.

Last updated: