Hello,
Notebooks have some nice features. Maintaining a python environment between users is fantastic, but actually coding in Notebooks is horrible. There is no debug, no breakpoints, no way to visually see the possible variables like in other notebooks. So, I code mostly in PyCharm and then just bring it into a notebook when I know the code will actually work. However, I'm getting different behaviors that are causing changes in the data.
When I put data in a df and then use the .to_featurelayer() function it uploads the data differently based on my environment. When I'm in the IDE it publishes the hosted layer with the data as a GDB and when I run it in Notebooks it publishes the hosted layer as a shapefile. The issue here is that I have a field that is getting deleted in the GDB but not in the shapefile. It doesn't seem like there is a parameter to force it to be a shapefile. Does anyone know how to get around this?
E: I was able to use the sanitize column and the missing column came in which is weird because it didnt have symbols and there are longer field names. Would still be nice to understand the difference between the environments and if that is controllable.
Solved! Go to Solution.
Hello,
The issue with fgdb not being deleted should be fixed. The reason there is filegeodatabase vs shapefile depends on whether you have arcpy in your environment or not. If you would like for it to be consistent then I would recommend having consistent environments: either use arcpy or use shapely.
Hello,
The issue with fgdb not being deleted should be fixed. The reason there is filegeodatabase vs shapefile depends on whether you have arcpy in your environment or not. If you would like for it to be consistent then I would recommend having consistent environments: either use arcpy or use shapely.
Oh ok that makes sense, the notebook environment only has the API for Python, thanks for the reply!