POST
|
How can I use systemList variable with several defined types with arcpy.da.SearchCursor? Currently, I have it looking at '009' but I would like it to find every system defined in systemList. import arcpy
fc = 'Database Connections\SDE.sde\NEO_1.SDE.P_PipeSystem\NEO_1.SDE.P_Meters'
field = 'SYSTEMNUMBER'
systemList = ["009", "10", "12", "13", "21", "22", "27", "27A", "27B", "27C", "30", "31", "33", "34", "35", "36"]
cursor = arcpy.da.SearchCursor(fc, (field, "SYSTEMNUMBER"), """SYSTEMNUMBER = '009'""")
count = 0
# For each row print the
for row in cursor:
# Print the name of the gas systems
#
#print(row[1])
#result = arcpy.GetCount_management(fc)
#print('{} has {} records'.format(row[1], result[0]))
count += 1
print('{} has {} records'.format(row[1],count))
... View more
05-18-2018
07:47 AM
|
0
|
6
|
3210
|
POST
|
I am trying to query a field in a layer but it fails converting the nvarchar value '65N' to data type int. Is there a way I can prevent it from converting and simply just run a query and print the results? Runtime error
Traceback (most recent call last):
File "<string>", line 7, in <module>
RuntimeError: Underlying DBMS error [[Microsoft][ODBC Driver 13 for SQL Server][SQL Server]Conversion failed when converting the nvarchar value '65N' to data type int.] [NEO_1.SDE.P_Meters]
import arcpy
fc = 'Database Connections\SDE.sde\NEO_1.SDE.P_PipeSystem\NEO_1.SDE.P_Meters'
field = 'SYSTEMNUMBER'
cursor = arcpy.da.SearchCursor(fc, (field, "SYSTEMNUMBER"), """"SYSTEMNUMBER" = 009""")
for row in cursor:
# Print the name of the different gas systems
#
print(row[1])
result = arcpy.GetCount_management(fc)
print('{} has {} records'.format(row, result[0]))
... View more
05-18-2018
05:46 AM
|
0
|
1
|
710
|
POST
|
I created an enterprise feature service and when I open the form's excel sheet and right click to insert a new row the sheet crashes. I've tried this about 5+ times and it keeps crashing. Does anyone know why this is happening?
... View more
05-11-2018
06:04 AM
|
1
|
3
|
750
|
POST
|
We're trying to setup a survey123 form that's versioned with a feature layer that has a feature class and a related table but while trying to publish in survey123 we get the error in the picture below. They both have Global ID's, editing tracking turned on and archiving enabled. It seems that versioned tables are configured with survey123. Has anyone found a solution for this? Note - I did try some troubleshooting with a different workflow but it's not practical. If you unregistered version for the layer & table and setup everything again it'll work but users can then write directly to the default version which is bad practice and design. I'll provide our workflow below Error: Workflow > ArcMap Portal Survey123
... View more
05-09-2018
09:21 AM
|
0
|
2
|
1239
|
POST
|
We have virtual machine that's being hosted on a server at our second office 2 hours away. The OS of that VM is Windows Server 2012 R2. The machine has the following programs install: ArcGIS Server | Portal | web adapters | Data Store (Not being used at the moment) | SQL 2012 for the database. The images below show more details. Problem - When we're connecting to the database through ArcMap or ArcPro and create a child version under the Default the performance drops drastically to the point that the actual programs (ArcMap/ArcPro) stop responding and crash. I'll provide our server specs below. Please provide troubleshooting ideas below and I will do my best to stay updated with everyone on here. Physical Server VM Host - Hyper-V VM Machine specs w/ sql gdb VM - Machine task manager
... View more
05-04-2018
08:02 AM
|
0
|
3
|
3112
|
POST
|
I figured out the issue I was with tables on collector. I kept clicking on the object and starting an edit session rather than scrolling to the very bottom.
... View more
05-03-2018
12:34 PM
|
0
|
0
|
876
|
POST
|
Hi Eric, I haven't found a solution. Hopefully someone will come across this post and help us.
... View more
05-03-2018
11:32 AM
|
0
|
8
|
3390
|
POST
|
I uploaded a hosted feature service to Portal and I am trying to reorder the fields on several layers. We have more than 30+ fields in our layers and it's impossible to move fields around because the program keeps bugging out. Is there another way to move fields or import some type of style sheet that reorders them like {field name} {field name}.. ect?
... View more
05-02-2018
12:51 PM
|
0
|
1
|
620
|
POST
|
I am trying to get Portal & Collector maps to allow us to add related tables to new/existing points on the map but everything that I've tried doesn't work. The points data simply won't allow us to add related tables. I'll provide a step-by-step guide of what I did below. If you need more information, please let me know. I've spent a week trying to figure this out. Guide >> Here is the relationship class between the ACSites & ACVisits Global ID's have been added.. Currently Versioned.. Editor tracking is on.. Users were added to the Privileges Global ID's have been added.. Currently Versioned.. Editor tracking is on.. Users were added to the Privileges Publishing the ACSites & ACVisits with Create, Delete, Query, Sync, and Update operations Analyzed with 0 errors Published successfully Checked the Feature Layer and Map Image Layer for sharing with Everyone & ArcGIS Enterprise Created a New Map.. brought the feature layer in.. Opened "More Options" under the layer & table.. went to "Configured Popups" > Configured Attributes > Selected everything for "Display" & "Edit" ( ** I did this for both the Point layer & Table ** ) I added a new feature to the map and I don't see anywhere in the attribute table to add a related table. This is the same for existing points on the map. I checked the Collector app and it doesn't show anywhere to add related tables to a point
... View more
04-30-2018
08:24 AM
|
0
|
3
|
2597
|
POST
|
We already have a point layer with points recorded on the map. Can we use survey123 to access those existing points and create new related tables?
... View more
04-26-2018
07:32 AM
|
0
|
1
|
860
|
POST
|
Our enterprise geodatabase is hosted within our companies internal network. This makes it very difficult for us to work with mobile apps. When our operators are out in the field the only way to access mapping data is through a Virtual private Network(VPN). The issue we're having is the lack of cell phone reception in our area. If the cell phone signal drops we're unable to use any of the ArcGIS phone apps. We thought our downloaded offline maps would work like with hosting with ArcGIS Online but we can't even open the application after it's been logged in to the enterprise. So relying on offline maps are completely off the plate. I am still trying to setup everything and I feel like this system wasn't designed for organizations with internal networks. Does anyone have any solutions or workarounds? Our company wants to move forward and use apps like workforce, collector, survey123, and explorer but because of this hiccup we're unable to accomplish our end goal which is to build a more manageable mapping system.
... View more
04-25-2018
10:32 AM
|
0
|
1
|
667
|
POST
|
Can Survey123 use existing data from Collector? We'd like to use Survey123 to create new tables for our existing points on the map.
... View more
04-25-2018
10:03 AM
|
0
|
3
|
1689
|
POST
|
If we run a full reconcile and post, along with a full compression and the version that we used to publish feature layers to portal gets deleted and later recreated before the script finishes will the published feature layers on portal still work?
... View more
04-17-2018
06:02 AM
|
0
|
1
|
437
|
DOC
|
Does the UPDM track Atmospheric corrosion points for items such as risers, meters, valves, and 1st cut regulators? We're also wondering about leak survey line feature class too. The only thing we found was the Leak Survey Area polygon feature class.
... View more
04-16-2018
10:22 AM
|
0
|
0
|
22544
|
POST
|
Hi Joe, I looked at the links and I not quite sure if those links are able to rearrange fields in the layer properties. I am importing several FC layers into a fresh map document and I was hoping to change the attribute field order in which they will appear. I know we can change them manually but I was hoping there would be a way in python to rearrange the field order and save the map document, similar to importing FC layers and saving. I'll provide the code and image below. import os
import arcpy # if outside ArcMap
# inside ArcMap, use "CURRENT" for document name
mxd = arcpy.mapping.MapDocument(r"C:\Users\jnmiller\Desktop\Rebuild Map py Scripts\Untitled.mxd")
# Input Variables
#
path = r"C:\Users\jnmiller\AppData\Roaming\ESRI\Desktop10.6\ArcCatalog\SDE.sde" # path source w/layers
df = arcpy.mapping.ListDataFrames(mxd, "*")[0]
# Add layer to TOC
#
fullPath = os.path.join(path, "ProposedMainlineProjects\ProposedMainlineProjects")
addLayer = arcpy.mapping.Layer(fullPath)
arcpy.mapping.AddLayer(df, addLayer, "BOTTOM")
fullPath = os.path.join(path, "P_PipeSystem\P_Meters")
addLayer = arcpy.mapping.Layer(fullPath)
arcpy.mapping.AddLayer(df, addLayer, "BOTTOM")
fullPath = os.path.join(path, "P_PipeSystem\P_MeterSetting")
addLayer = arcpy.mapping.Layer(fullPath)
arcpy.mapping.AddLayer(df, addLayer, "BOTTOM")
fullPath = os.path.join(path, "P_PipeSystem\P_Regulator")
addLayer = arcpy.mapping.Layer(fullPath)
arcpy.mapping.AddLayer(df, addLayer, "BOTTOM")
# Set Visable = False
#
for lyr in arcpy.mapping.ListLayers(mxd):
print lyr.name
lyr.visible = False
mxd.save()
del mxd
... View more
04-11-2018
09:22 AM
|
0
|
1
|
840
|
Title | Kudos | Posted |
---|---|---|
1 | 05-11-2018 06:04 AM | |
1 | 04-11-2018 06:24 AM | |
1 | 04-04-2019 05:59 AM | |
1 | 05-06-2019 08:45 AM | |
2 | 06-06-2019 06:32 PM |
Online Status |
Offline
|
Date Last Visited |
01-13-2021
02:32 PM
|