InfoWorks ICM: simple SQL query saves big time

Switch upstream and downstream node IDs

//Switch US and DS node IDs//store the node id to variablesUPDATE SELECTED SET $Usnode = us_node_id;UPDATE SELECTED SET $Dsnode = ds_node_id;//switch the node idsUPDATE SELECTED SET us_node_id = $Dsnode;UPDATE SELECTED SET ds_node_id = $Usnode;//update the flagsUPDATE SELECTED SET us_node_id_flag = "Q";UPDATE SELECTED SET ds_node_id_flag = "Q";

Ask the user to enter the slope to calculate the invert

//Sets the upstream invert and slope of a link based on the entered slope, the downstream invert, and the length//set default valueLET $gradient = 1;//defines the input windowPROMPT LINE $gradient 'Pipe Slope';PROMPT DISPLAY;//calculate the upstream invertUPDATE SELECTED SET us_invert = ds_invert +conduit_length*$gradient/100;UPDATE SELECTED SET gradient = $gradient;UPDATE SELECTED SET us_invert_flag = "Q";UPDATE SELECTED SET gradient_flag = "Q";



Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store