PostGIS  2.1.10dev-r@@SVN_REVISION@@
def raster2pgsql.make_sql_create_table (   options,
  table = None,
  is_overview = False 
)

Definition at line 354 of file raster2pgsql.py.

References logit(), make_sql_full_table_name(), and quote_sql_name().

Referenced by main(), and wkblify_raster_level().

354 def make_sql_create_table(options, table = None, is_overview = False):
355 
356  if table is None:
357  table = options.table
358 
359  if options.filename:
360  sql = "CREATE TABLE %s (rid serial PRIMARY KEY, \"filename\" text);\n" \
361  % (make_sql_full_table_name(table))
362  else:
363  if options.overview_level > 1 and is_overview:
364  sql = "CREATE TABLE %s (rid serial PRIMARY KEY, %s RASTER);\n" \
365  % (make_sql_full_table_name(table), quote_sql_name(options.column))
366  else:
367  sql = "CREATE TABLE %s (rid serial PRIMARY KEY);\n" \
368  % (make_sql_full_table_name(table))
369 
370  logit("SQL: %s" % sql)
371  return sql
372 
373 
def make_sql_full_table_name(schema_table)
def make_sql_create_table
def logit(msg)
def quote_sql_name(name)

Here is the call graph for this function:

Here is the caller graph for this function: