Select to view content in your preferred language

Should the Utility Network validate that two pipes cannot connect to the same terminal on a device?

254
2
Jump to solution
2 weeks ago
DasheEbra
Frequent Contributor

Scenario:
I have a pressure valve device placed at the junction of two water mains (Transmission Main). The device has two terminals representing the two sides of the valve (In / Out). The physical and logical expectation is:

- Pipe A → connects to terminal **High Pressure In**
- Pipe B → connects to terminal **High Pressure Out**

This reflects real-world behavior — a valve has two distinct ports, and two separate pipes cannot physically feed into or out of the same port simultaneously.

Issue:
Using Modify Terminal Connections I was able to assign both pipes/lines (Wtr-Mn-3509 and Wtr-Mn-4231) to the same terminal (High Pressure In) with no warning or error. Even after Validate Network Topology, no error was raised either.

See screenshot below — both configurations (one pipe per terminal vs. two pipes on the same terminal) are accepted without any validation feedback.

DasheEbra_1-1776458406399.png

 

Question:
1. Is this expected behavior in the current UN schema, or is terminal uniqueness per-pipe supposed to be enforced?
2. Is there a way to configure the network today (e.g., via network rules, connectivity rules, or terminal configuration) to prevent two lines from connecting to the same terminal?
3. If this is a known gap, has it been submitted as an enhancement request? Should this be flagged for a future UN release functionalities?

I understand that connectivity rules can restrict which asset types are allowed to connect on each terminal/side of a device. However, even if such rules exist, I think the Modify Terminal Connections pane itself should reflect the current connection state dynamically. Specifically:
- If a terminal (e.g., High Pressure In) is already occupied by a connected pipe, the second pipe being assigned should, automatically default to the next available terminal, or
- All terminals should remain visible in the dropdown, but already-occupied terminals should be grayed out / disabled to prevent the user from accidentally assigning two lines/pipes to the same port.

This would make the terminal assignment experience more intuitive and error-proof.

I believe the UN should enforce that each terminal can only have one connected line at a time, at least for devices where terminals represent physical ports (valves, switches, etc.). Would love to hear how others have handled this or whether this is by design.

**Environment:**
- ArcGIS Pro 3.6
- ArcGIS Utility Network Water-Foundation project

 

Thanks!

0 Kudos
1 Solution

Accepted Solutions
gis_KIWI4
MVP Regular Contributor

Agree with @RobertKrisher
You can do this with Validation Rules but you will have to run these separately to the UN Validation i.e these will create errors but NOT dirty areas. The edit experience isn't the best. 

One way you can get past this is using pop-ups to draw attention to devices where you have lines connected to the same Terminals. This way is safer and simpler than validation rules (you can create a lot of false positives if you don't set up the rule correctly). 

gis_KIWI4_0-1776641426790.png

A very crude arcade script that checks the device and the connected lines and the TODEVICETERMINAL and FROMDEVICETERMIANLS on those lines to flag an error. 

You will need to edit this to if you only want to run for a certain subtype, etc. 

var lines = FeatureSetByName(
    $datastore,
    "ElectricLine",
    ["OBJECTID", "fromdeviceterminal", "todeviceterminal"],
    true
)

var deviceGeom = Geometry($feature)
var hit = Intersects(lines, deviceGeom)

var tolerance = 0.01
var out = []
var terminals = []

for (var l in hit) {
    var g = Geometry(l)
    if (IsEmpty(g) || IsEmpty(g.paths) || Count(g.paths) == 0) continue

    var p = First(g.paths)
    if (IsEmpty(p) || Count(p) == 0) continue

    var startPt = Point({
        x: p[0].x,
        y: p[0].y,
        spatialReference: deviceGeom.spatialReference
    })

    var endPt = Point({
        x: p[-1].x,
        y: p[-1].y,
        spatialReference: deviceGeom.spatialReference
    })

    if (Distance(deviceGeom, startPt) <= tolerance) {
        var t1 = Text(l["fromdeviceterminal"])
        Push(out, "Line " + Text(l.OBJECTID) + " → FROM → " + t1)
        if (!IsEmpty(t1) && t1 != "None") Push(terminals, t1)
    }

    if (Distance(deviceGeom, endPt) <= tolerance) {
        var t2 = Text(l["todeviceterminal"])
        Push(out, "Line " + Text(l.OBJECTID) + " → TO → " + t2)
        if (!IsEmpty(t2) && t2 != "None") Push(terminals, t2)
    }
}

if (Count(out) == 0) {
    return {
        type: 'text',
        text: "No terminals found"
    }
}

// check duplicates
var hasDuplicate = Count(terminals) != Count(Distinct(terminals))

var z = Concatenate(out, "<br>")

if (hasDuplicate) {
    z = "<b style='color:red;'>⚠ ERROR: Lines are connected to the SAME terminal</b><br><br>" + z
}

return { 
    type : 'text', 
    text : z 
}

 

Hope this helps. 



View solution in original post

2 Replies
RobertKrisher
Esri Regular Contributor

This is currently working as designed, in that the modify terminal assignment tool allows you to manually assign terminal connections to whichever pipes you want. Especially in the case of a device with a directional terminal configuration the system cannot know which side is upstream/downstream.

There are quite a few legitimate scenarios in several industries where you can have more than one line connected to the same terminal. This is why we don't create a topology error. You could create a validation rule to check for this situation.

You are welcome to create separate ideas for any enhancements you want to see, and the team can evaluate them.

0 Kudos
gis_KIWI4
MVP Regular Contributor

Agree with @RobertKrisher
You can do this with Validation Rules but you will have to run these separately to the UN Validation i.e these will create errors but NOT dirty areas. The edit experience isn't the best. 

One way you can get past this is using pop-ups to draw attention to devices where you have lines connected to the same Terminals. This way is safer and simpler than validation rules (you can create a lot of false positives if you don't set up the rule correctly). 

gis_KIWI4_0-1776641426790.png

A very crude arcade script that checks the device and the connected lines and the TODEVICETERMINAL and FROMDEVICETERMIANLS on those lines to flag an error. 

You will need to edit this to if you only want to run for a certain subtype, etc. 

var lines = FeatureSetByName(
    $datastore,
    "ElectricLine",
    ["OBJECTID", "fromdeviceterminal", "todeviceterminal"],
    true
)

var deviceGeom = Geometry($feature)
var hit = Intersects(lines, deviceGeom)

var tolerance = 0.01
var out = []
var terminals = []

for (var l in hit) {
    var g = Geometry(l)
    if (IsEmpty(g) || IsEmpty(g.paths) || Count(g.paths) == 0) continue

    var p = First(g.paths)
    if (IsEmpty(p) || Count(p) == 0) continue

    var startPt = Point({
        x: p[0].x,
        y: p[0].y,
        spatialReference: deviceGeom.spatialReference
    })

    var endPt = Point({
        x: p[-1].x,
        y: p[-1].y,
        spatialReference: deviceGeom.spatialReference
    })

    if (Distance(deviceGeom, startPt) <= tolerance) {
        var t1 = Text(l["fromdeviceterminal"])
        Push(out, "Line " + Text(l.OBJECTID) + " → FROM → " + t1)
        if (!IsEmpty(t1) && t1 != "None") Push(terminals, t1)
    }

    if (Distance(deviceGeom, endPt) <= tolerance) {
        var t2 = Text(l["todeviceterminal"])
        Push(out, "Line " + Text(l.OBJECTID) + " → TO → " + t2)
        if (!IsEmpty(t2) && t2 != "None") Push(terminals, t2)
    }
}

if (Count(out) == 0) {
    return {
        type: 'text',
        text: "No terminals found"
    }
}

// check duplicates
var hasDuplicate = Count(terminals) != Count(Distinct(terminals))

var z = Concatenate(out, "<br>")

if (hasDuplicate) {
    z = "<b style='color:red;'>⚠ ERROR: Lines are connected to the SAME terminal</b><br><br>" + z
}

return { 
    type : 'text', 
    text : z 
}

 

Hope this helps.