Hello,
I have a fairly simple notebook that takes a feature layer and converts it to an sdf and ultimately a df. I would simply like to output this as a table to ArcGIS online. I hope it's a simple path issue, but I'm not optimistic. The other options I've explored are the REST API 'export item' which I've had mixed results with and the idea of using the add() method. The last line in bold is where my question lies. Thanks in advance.
Code shared below:
from arcgis.gis import GIS
from IPython.display import display
import pandas as pd
from arcgis.features import GeoAccessor, GeoSeriesAccessor
from arcgis.features import FeatureLayer
import os
gis = GIS("home")
lyr_url = 'https://services6.arcgis.com/T8eS7sop5hLmgRRH/arcgis/rest/services/PublicProjectIdeas_ZS/FeatureServer'
layer = FeatureLayer(lyr_url)
layer
feature_layer = projIdeas
feature_layer
query = feature_layer.query()
projIdeasTable = query
sdf = projIdeasTable.sdf
sdf.head()
projectIdeasTable = sdf.spatial.to_table('ProjectIdeas.csv')