Zonal statistic as table always error with 'The input path contains spaces'. However, the 'Zonal statistic' using the exact setting could successful be run.
This the detail of 'Zonal Statistics as Table'
Zonal Statistics as Table
=====================
Tool Path
Input Raster or Feature Zone Data E:\research EMIT\EMIT ArcGIS\EMIT ArcGIS.gdb\EMIT_tiles
Zone Field OBJECTID
Input Value Raster ai_v3_yr.tif
Output Table E:\research EMIT\EMIT ArcGIS\EMIT ArcGIS.gdb\ZonalSt_EMIT_ti1
Ignore NoData in Calculations DATA
Statistics Type MEAN
Process as Multidimensional CURRENT_SLICE
Percentile Values 90
Percentile Interpolation Type AUTO_DETECT
Calculate Circular Statistics ARITHMETIC
Circular Wrap Value 360
Output Join Layer
=====================
Messages
Start Time: Wednesday, December 11, 2024 9:52:31 PM
ERROR 000622: Failed to execute (ZonalStatisticsAsTable). Parameters are not valid.
ERROR 010819: The input path contains spaces.
Failed to execute (ZonalStatisticsAsTable).
Failed at Wednesday, December 11, 2024 9:52:31 PM (Elapsed Time: 0.20 seconds)
This the detail of 'Zonal Statistics as'
Zonal Statistics
=====================
Tool Path
Input Raster or Feature Zone Data E:\research EMIT\EMIT ArcGIS\EMIT ArcGIS.gdb\EMIT_tiles
Zone Field OBJECTID
Input Value Raster ai_v3_yr.tif
Output Raster E:\research EMIT\EMIT ArcGIS\EMIT ArcGIS.gdb\ZonalSt_EMIT1
Statistics Type MEAN
Ignore NoData in Calculations DATA
Process as Multidimensional CURRENT_SLICE
Percentile Value 90
Percentile Interpolation Type AUTO_DETECT
Calculate Circular Statistics ARITHMETIC
Circular Wrap Value 360
=====================
Messages
Start Time: Wednesday, December 11, 2024 9:50:48 PM
Value raster being used as snap raster; this is new default behavior.
WARNING 010566: Some zones may not have been rasterized.
Succeeded at Wednesday, December 11, 2024 9:52:31 PM (Elapsed Time: 1 minutes 42 seconds)
I just ran across this issue today in 3.5.2. Was pulling my hair out trying to find a solution because I seemingly had no spaces in my "input path". Shoutout to @OlympiaTaken for their comment - this made me test out a different pro project and led me down a testing rabbit hole.
What I found was that if the Pro Project's file path has any spaces in it, the tool will fail with Error 010819 - even if the input layers themselves are stored in a location with no spaces. If the Pro Project itself is saved to a new location with no spaces, the tool then has no issues running. Magic!
We're gonna try submitting this as a case to ESRI. Let me know if this works for you.
This is pretty poor by ESRI to not acknowledge it's actually a bug. Multiple people have had this issue (I get it with zonal stats but have had it with other raster GP tools) even when there are NO spaces in any of the file path. I didn't have the issue on 3.3 but get it with 3.5 on one of my computers but not the other, despite the same directory being used.
Others have suggested some things that might cause it, e.g., a space in any part of the project not just the dataset. Maybe ESRI should look at this and why it used to work (and works in ArcMap) instead of pretending it's not an issue
There is at least 1 related bug ticket lodged and being worked on, as far as I know.
So hopefully it gets fixed within the next few patch cycles..
From my testing, it's related to the project directory path, not the files. So making a project in a directory that contains no spaces, and then running the processing there is the only reliable workaround I know of, as frustrating as that is..