ArcGIS Desktop

  • ArcGIS Pro
  • ArcMap

  • My Profile
  • Help
  • Sign Out
ArcGIS Desktop

ArcGIS Online

The mapping platform for your organization

ArcGIS Desktop

A complete professional GIS

ArcGIS Enterprise

GIS in your enterprise

ArcGIS Developers

Tools to build location-aware apps

ArcGIS Solutions

Free template maps and apps for your industry

ArcGIS Marketplace

Get apps and data for your organization

  • Documentation
  • Support
Esri
  • Sign In
user
  • My Profile
  • Sign Out

ArcMap

  • Home
  • Get Started
  • Map
  • Analyze
  • Manage Data
  • Tools
  • Extensions

Create Table

  • Summary
  • Usage
  • Syntax
  • Code sample
  • Environments
  • Licensing information

Summary

Creates a geodatabase table, an INFO table, or a dBASE table.

Usage

  • If the output location is a folder, the default output is an INFO table.

  • To create a dBASE table in a folder, you must append the extension .dbf to the output table name.

Syntax

arcpy.management.CreateTable(out_path, out_name, {template}, {config_keyword})
ParameterExplanationData Type
out_path

The workspace in which the output table will be created.

Workspace
out_name

The name of the table to be created.

String
template
[template,...]
(Optional)

A table with an attribute schema that is used to define the output table. Fields in the template tables will be added to the output table.

Table View
config_keyword
(Optional)

The configuration keyword that determines the storage parameters of the table in an enterprise geodatabase.

String

Derived Output

NameExplanationData Type
out_table

The new output table.

Table

Code sample

CreateTable example 1 (Python window)

The following Python Window script demonstrates how to use the CreateTable function in immediate mode:

import arcpy
arcpy.env.workspace = "C:/data"
arcpy.CreateTable_management("C:/output", "habitatTemperatures.dbf", 
                             "vegtable.dbf")
CreateTable example 2 (stand-alone script)

The following Python script demonstrates how to use the CreateTable function in a stand-alone script:

# Name: CreateTable_Example2.py
# Description: Create table to store temperature data in gnatcatcher habitat areas

# Import system modules
import arcpy

# Set workspace
arcpy.env.workspace = "C:/data"

# Set local variables
out_path = "C:/output"
out_name = "habitatTemperatures.dbf"
template = "vegtable.dbf"
config_keyword = ""

# Execute CreateTable
arcpy.CreateTable_management(out_path, out_name, template, config_keyword)

Environments

  • Current Workspace
  • Output CONFIG Keyword
  • Scratch Workspace

Licensing information

  • Basic: Yes
  • Standard: Yes
  • Advanced: Yes

Related topics

  • An overview of the Table toolset

ArcGIS Desktop

  • Home
  • Documentation
  • Support

ArcGIS

  • ArcGIS Online
  • ArcGIS Desktop
  • ArcGIS Enterprise
  • ArcGIS
  • ArcGIS Developer
  • ArcGIS Solutions
  • ArcGIS Marketplace

About Esri

  • About Us
  • Careers
  • Esri Blog
  • User Conference
  • Developer Summit
Esri
Tell us what you think.
Copyright © 2021 Esri. | Privacy | Legal