Scratch GDB

The scratch GDB is the location of a file geodatabase you can use to write temporary data.

The scratch GDB environment complements the Scratch Workspace environment. Its primary purpose is for use by scripts and models as geoprocessing services, with the added focus of only pointing to a known geodatabase. When ArcGIS for Server executes a geoprocessing task, the scratch GDB is always available to write output to. This environment is also useful in authoring scripts and models for use on the desktop. Writing output to the scratch GDB will make your tool portable, because this location will always be available or created at execution time.

Usage notes

Dialog syntax

NoteNote:

The scratch GDB environment is only available in Python and models.

Scripting syntax

arcpy.env.scratchGDB

Script example

import arcpy
arcpy.env.scratchWorkspace = "c:/LandUse/ForestCover"

# c:\LandUse\ForestCover\scratch.gdb
print arcpy.env.scratchGDB

Related Topics

3/3/2014