Two variables of the same name are used in a merge without being listed in the by statement is usually unintentionnal (usually done by mistake).
As far I'm aware of, the only way to be informed about it is to display information messages in the log using options msglevel=i;.
Would it be possible to have a global option called for example mergeoverwrite= (or any other relevant name) with WARN by default (as VARLENCHK=)?
key=1; x=1; output;
key=2; x=2; output;
key=1; x=5; output;
key=2; x=6; output;
merge one two;
I believe you get a truncation warning (or is it a note) if doing this for a variable with different lengths.
Given all the code that's already implemented in productions globally I certainly can't vote for such a new warning by default. It could be at best an option one can set - and if you want it as the default at your site then define it as part of a .cfg or autoexec or the like. ...but in the end: Know your data and do proper testing.
Maybe name the option MergeCollision instead of MergeOverwrite? I think the shipped default would probably have to be NoWarn, even though I would set my default to ERROR.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.