POST
|
Solution used as_df=True in the query to get an sdf directly from arc instead of converting query_result=a_feature_layer.query(where="some query",as_df=True)
... View more
02-20-2020
07:33 AM
|
0
|
0
|
1229
|
POST
|
Hi guys, I'm having an issue with converting a result of a query to arcgis online to an sdf it responds with this error : Exception: An error occurred with exporting the FeatureSet with message: 'NoneType' object has no attribute 'update' current code - : query_result=a_feature_layer.query(where="some query") sdf_object=query_result.sdf Ive looked at the features in the query and geometries and fields look fine any suggestions?
... View more
02-20-2020
07:15 AM
|
0
|
1
|
1315
|
POST
|
Hi Egge-Jan The reason I want to be able to copy is a User is creating the view with specific rules, /stylings / permissions as a template. I just want to be able to replicate it for the User for multiple locations quickly. Otherwise I need to figure out how to replicate his view - ie give users permissions and custom styling etc using code and updating the definitions, where as a Copy would make this much simpler - as the user may want to change the view template in the future Is there a way to create a view of the same data and then copy view parameters from a template view ?
... View more
02-14-2020
09:06 AM
|
0
|
0
|
683
|
POST
|
figured it out view_def = {"viewLayerDefinition":{"filter": {"operator":"esriSpatialRelIntersects","value": {"geometryType":"esriGeometryPolygon","geometry": {'rings': [[[some coords]]]} "spatialReference":{"wkid":29900,"latestWkid":29902}}}}} AFeatureLayer.manager.update_definition(view_def ) now I'm struggling with copying a view itself as I noticed my filter applied to the copy and the original View any suggestions would be a great help
... View more
02-13-2020
10:07 AM
|
0
|
2
|
683
|
POST
|
Hi guys, I'm attempting create multiple views off of a single feature layer - I can copy a view I've created but I cant modify the visible area (trying to make views for different parts of the country) This appears to be the geometry filter on the view : AFeatureLayer.manager.properties.adminLayerInfo.viewLayerDefinition.table.filter.value.geometry I've attempted to take a copy of the manager properties - modify the geometry value and then run AFeatureLayer.manager.update_definition(copy_of_properties) this returns an error message : RuntimeError: Unable to update feature service layer definition. Invalid definition for 'LastEditDate'. Invalid definition for ESRI.ArcGIS.SDS.Metadata.EditingInfo Then I attempted to only update using only AFeatureLayer.manager.properties.adminLayerInfo with the geometry changed . This returns {'success': True} This doesnt seem to actually update the layer and the view doesnt change filter when reloaded - Any suggestions would be very useful as I cant find any documentation
... View more
02-13-2020
07:57 AM
|
0
|
3
|
822
|
POST
|
Thanks Joshua, So what I had to do was create the hosted layer view, and hide/filter out as much information as possible. Then when you get the attachments preview link it still comes by default with a token which will timeout and become unusable after ~1 hour , But once you make your view public you can remove the text in the attachment url that appears from "?token" and now you have a publicly available preview/download URL
... View more
07-22-2019
07:42 AM
|
1
|
0
|
819
|
POST
|
I have a feature layer with images which I want to keep the data private, but make the url to the image public so it can be viewed in another system is there a way to do this? Currently there is a token on the url which times out after a few hours.
... View more
07-19-2019
09:14 AM
|
0
|
2
|
958
|
POST
|
Answer For this is when setting a geometry when appending to the SDF: record_to_append.SHAPE=geometry.Geometry({'paths': [new_line], 'spatialReference': {'wkid': 29903, 'latestWkid': 29903}} fixed this issue
... View more
05-10-2019
08:03 AM
|
0
|
0
|
4044
|
POST
|
Getting Error Codes 502,503,504 while pulling data from Argcis online In python, I've set up exceptions to retry once after 5 seconds yet I'm still having issues getting data, Is it that I'm attempting to pull too much information all at once? I have layers that can have up to 15000 points with several attributes Or is it that my feature services are being accessed by other users and the server cannot respond ? try: SDF=pd.DataFrame.spatial.from_layer(feature_layers[layer_index]) except: print("Failed to download Retry") time.sleep(5) SDF=pd.DataFrame.spatial.from_layer(feature_layers[layer_index])
... View more
05-10-2019
05:30 AM
|
0
|
0
|
341
|
POST
|
No Good Solution as of yet, working towards having all Feature classes with a naming convention, using python to find all layers that should follow a template, modifying based on a manual input (ex : "change all columns called "XXX" to "YYY" or Add a Layer called "ZZZ" to every feature collection) - very messy, every solution I can come up with is very user input heavy. I'm constantly having to create a new set of feature classes for new areas (working with large amounts of data in small locations using one large feature class is too cumbersome for arcgis pro) - I have no ability to find folders in python when looking for feature classes makes grouping layers that are related difficult (some feature classes I need to have a read only and others as write only) Any suggestions would be great also I'm using Arcgis in python scripts only, I rarely use ArcGis pro as most of the work I'm doing has to be run based on a trigger or schedule.
... View more
04-30-2019
06:09 AM
|
0
|
0
|
605
|
POST
|
Is there a way to create a feature layer Template / Master layer ? Currently I have to create several Feature classes for different areas, Each being identical just containing different data. Is it possible to create a Template or Master feature layer such that if I updated the Template the column headers, properties would update on all feature layers associated ?
... View more
04-08-2019
05:17 AM
|
0
|
5
|
724
|
POST
|
I've got back to my previous installation, all is working, think I'm going to avoid the update button until I have the time to fight gremlins.
... View more
03-11-2019
10:43 AM
|
0
|
0
|
621
|
POST
|
Hi , Since updating arcgis to 2.3.1, Ive ran into several issues, I can no longer import arcpy : Traceback (most recent call last): File "<pyshell#14>", line 1, in <module> import arcpy File "C:\Program Files\ArcGIS\Pro\Resources\ArcPy\arcpy\__init__.py", line 72, in <module> from arcpy.geoprocessing import gp File "C:\Program Files\ArcGIS\Pro\Resources\ArcPy\arcpy\geoprocessing\__init__.py", line 14, in <module> from ._base import * File "C:\Program Files\ArcGIS\Pro\Resources\ArcPy\arcpy\geoprocessing\_base.py", line 14, in <module> import arcgisscripting ImportError: DLL load failed: The specified procedure could not be found. Reading in a Spatially enabled dataframe with Polylines results in the geometries being in an invalid format I can open the files using other packages such as QGIS with no issues, but when using : pd.DataFrame.spatial.from_featureclass("path\SHAPEFILE.shp") the line geometries appear like this : {'paths': ((187630.82, 180236.282), (187678.006, 180294.916)), 'spatialReference': {'wkid': 4326}} instead of : {'paths': [[[187630.82, 180236.282], [187678.006, 180294.916]]], 'spatialReference': {'wkid': 4326}} requiring a manual change of all records in reading in files. And Third I previously created a script which uses : result=point_geometries_SEDF.SHAPE.geom.within(a_point.buffer(0.5)) which no longer works it appears the buffer function has been broken as using the within function on a point does not return an error only on a buffer >>> start_point.within(start_point) True >>> start_point.within(start_point.buffer(1)) Traceback (most recent call last): File "<pyshell#6>", line 1, in <module> start_point.within(start_point.buffer(1)) File "C:\Users\CIM_Laptop\AppData\Local\ESRI\conda\envs\arcgis1_5\lib\site-packages\arcgis\geometry\_types.py", line 2223, in within return self.as_shapely.within(second_geometry) File "C:\Users\CIM_Laptop\AppData\Local\ESRI\conda\envs\arcgis1_5\lib\site-packages\shapely\geometry\base.py", line 723, in within return bool(self.impl['within'](self, other)) File "C:\Users\CIM_Laptop\AppData\Local\ESRI\conda\envs\arcgis1_5\lib\site-packages\shapely\predicates.py", line 13, in __call__ self._validate(other, stop_prepared=True) File "C:\Users\CIM_Laptop\AppData\Local\ESRI\conda\envs\arcgis1_5\lib\site-packages\shapely\topology.py", line 18, in _validate raise ValueError("Null geometry supports no operations") ValueError: Null geometry supports no operations
... View more
03-11-2019
07:02 AM
|
0
|
2
|
756
|
POST
|
Hi, Sorry for the late reply, I've Attempted to use your solution which appears to work while modifying the records, the original issue of overwriting no longer occurs record_to_append.SHAPE = {'paths' : [new_line]} record_to_append.SHAPE {'paths': [[[322058.68479999993, 226573.08400000073], [322061.67789999954, 226573.96309999935], [322063.7945999997, 226569.7296999991], [322098.81620000023, 226533.6378000006], [322066.5378999999, 226500.82509999909], [322049.0729, 226482.97609999962]]], 'spatialReference': {'wkid': 29903, 'latestWkid': 29903}} but attempting to use record_to_append.SHAPE then throws errors that geometry type cant be dict record_to_append.SHAPE.buffer(0.5) AttributeError: 'dict' object has no attribute 'buffer' The same issue occurs when attempting to export the SDF to a feature class Is there some way of creating a "geometry object" in arcgis api that can then be used to set record_to_append.SHAPE = "geometry object"
... View more
02-13-2019
06:56 AM
|
0
|
1
|
1184
|
POST
|
Record_to_append must previously be a line geometry so you can overwrite the path
... View more
01-24-2019
11:28 AM
|
0
|
1
|
2860
|
Title | Kudos | Posted |
---|---|---|
1 | 07-22-2019 07:42 AM | |
1 | 01-18-2019 04:07 AM | |
3 | 01-16-2019 07:50 AM |
Online Status |
Offline
|
Date Last Visited |
11-11-2020
02:23 AM
|