data-assistant icon indicating copy to clipboard operation
data-assistant copied to clipboard

Domain Map - Should there be an otherwise option

Open MikeMillerGIS opened this issue 7 years ago • 7 comments

@SteveGrise @previnWong what are your thoughts on otherwise. I know we talked about this, it this better in the value map with the domain loader we discussed?

Here is my source data. The casing has a huge list, only 4 are really used. Feel weird not mapping them.
image

MikeMillerGIS avatar Mar 22 '17 00:03 MikeMillerGIS

For me, when there is a small list of values used, I would like to see an error if there is data that falls outside of those values. For example, if there is a 1.5" culvert I'd like to see that as an error.

I think Otherwise should be a special case where a group of known values should be set to something rather than anything else encountered should be set to something. The original Value Map Otherwise came from a number of datasets I worked on where the domain/data values were being collapsed from a lot of source values to a few things and there was a specific need to set them to something rather than a catch-all for unknown source values.

SteveGrise avatar Mar 22 '17 18:03 SteveGrise

So if a user have value that is not in the domain list, there is no way for them to map it here, it will directly copy over? That is what I am thinking. I seen many times when people use field calculator to set a value and it does not adhere. But maybe you are right, this should be a data clean up issue in the source.

MikeMillerGIS avatar Mar 22 '17 18:03 MikeMillerGIS

I've been concerned at times about people logging issues about 'data corruption' and thought maybe warning them/preventing them from messing things up would be better.

The difference in the water diameter domains from source to target is a good example of how Copy would scramble pipe sizes. We could always print some warning messages when this happens but I think people don't look that closely unless there is an error message...

SteveGrise avatar Mar 22 '17 18:03 SteveGrise

Adjusted the domain map logic to set the new value to the source value so that the effect is to copy values that do not fit the domain map (such as null/None).

SteveGrise avatar Mar 28 '17 18:03 SteveGrise

Seems to be working. I omitted some domain mapping and the value for code 15, just got copied over to target. image

previnWong avatar Mar 31 '17 22:03 previnWong

We need to expose the otherwise as we have encountered issues with this.

  • Scenario 1

    • Source is a string field
    • Target is a integer
    • I only map one Source to Target
    • I run the process, the string to int fails, but the loading continues
  • Scenario 2

    • Source is a int field
    • Target is a integer field
    • There are values in the source outside the domain
    • I want to set them all to one value

MikeMillerGIS avatar Aug 07 '17 13:08 MikeMillerGIS

Lets put on hold and work through it with the other domain map fixes

MikeMillerGIS avatar Aug 07 '17 13:08 MikeMillerGIS