.

OGR miscellaneous

Execute SQL

Descripción

<colocar la descripción del algoritmo aquí>

Parametros

Capa de entrada [vector: cualquiera]

<colocar la descripción de parámetros aquí>

SQL [string]

<colocar la descripción de parámetros aquí>

Default: (not set)

Salidas

SQL result [vector]

<colocar aquí la descripción de la salida>

Uso de la consola

processing.runalg('gdalogr:executesql', input, sql, output)

Ver también

Import Vector into PostGIS database (available connections)

Descripción

Imports vector layers inside a PostGIS database on the basis of an available connection. The connection has to be defined properly with the ‘Add PostGIS Table(s)’ dialog before. Use the ‘Edit’ button to define the connection. Be aware that the checkboxes ‘Save Username’ and ‘Save Password’ are activated. Then you can use the algorithm. The algorithm is derived from the ogr2ogr utility .

Parametros

Database (connection name) [selection]

Requires the database (connection) name.

Opciones:

  • 0 — local

Predeterminado: 0

Capa de entrada [vector: cualquiera]
Any OGR-supported vector layer loaded into the QGIS map canvas.
Output geometry type [selection]

Defines the output geometry type. By default this is Polygon.

Opciones:

  • 0 —
  • 1 — NONE
  • 2 — GEOMETRY
  • 3 — POINT
  • 4 — LINESTRING
  • 5 — POLYGON
  • 6 — GEOMETRYCOLLECTION
  • 7 — MULTIPOINT
  • 8 — MULTIPOLYGON
  • 9 — MULTILINESTRING

Predeterminado: 5

Input CRS (EPSG Code) [crs]

CRS of the input vector layer.

Default: EPSG:4326

Output CRS (EPSG Code) [crs]

Defines the output CRS of the database table.

Default: EPSG:4326

Schema name [string]

Opcional

Defines the schema to which the database table will be assigned to. By default, ‘public’ is chosen.

Default: public

Table name, leave blank to use input name [string]

Opcional

Defines a name for the table that will be imported into the database. By default the table name is the name of the input vector file.

Default: (not set)

Primary Key [string]

Opcional

Defines which attribute field will be the primary key of the database table. By default this is ‘id’.

Default: id

Geometry column name [string]

Opcional

Defines in which attribute field of the database there will be the geometry information. By default it will be taken from the ‘geom’ column.

Default: geom

Vector dimensions [selection]

Defines if the vector file to be imported has 2-D or 3-D data.

Opciones:

  • 0 — 2
  • 1 — 3

Predeterminado: 0

Distance tolerance for simplification [string]

Opcional

Defines a distance tolerance for the simplification of the vector geometries to be imported. By default no simplification there is no simplification.

Default: (not set)

Maximum distance between 2 nodes (densification) [string]

Opcional

The maximum distance between two nodes. Used to create intermediate points. By default there is no maximum distance.

Default: (not set)

Select features by extent (defined in input layer CRS) [extent]

You can select features from a given extent that will be in the output table.

Por defecto: 0,1,0,1

Clip the input layer using the above (rectangle) extent [boolean]

The input layer will be clipped by the extent you defined before.

Predeterminado: False

Select features using a SQL "WHERE" statement (Ex: column="value") [string]

Opcional

Defines with a SQL “WHERE” statement which features should be selected for the output table.

Default: (not set)

Group "n" features per transaction (Default: 20000) [string]

Opcional

You can group the input features in transactions where “n” defines the size. By default “n” limits the transaction size to 20000 features.

Default: (not set)

Overwrite existing table? [boolean]

If there is a table with the same name in the database, it won’t be overwritten. By default this takes place.

Por defecto: True

Append to existing table? [boolean]

<colocar la descripción de parámetros aquí>

Predeterminado: False

Append and add new fields to existing table? [boolean]

If activated the vector data will be appended to an existing table, there won’t be created a new table. By default a new table will be created.

Predeterminado: False

Do not launder columns/table name/s? [boolean]

With this option you can prevent processing from converting column names to lowercase, from removing spaces and other invalid characters.

Predeterminado: False

Do not create Spatial Index? [boolean]

Prevents that a spatial index in the output table will be created.

Predeterminado: False

Continue after a failure, skipping the failed feature [boolean]

<colocar la descripción de parámetros aquí>

Predeterminado: False

Additional creation options [string]

Opcional

<colocar la descripción de parámetros aquí>

Default: (not set)

Salidas

Uso de la consola

processing.runalg('gdalogr:importvectorintopostgisdatabaseavailableconnections', database, input_layer, gtype, s_srs, t_srs, schema, table, pk, geocolumn, dim, simplify, segmentize, spat, clip, where, gt, overwrite, append, addfields, launder, index, skipfailures, options)

Ver también

Import Vector into PostGIS database (new connection)

Descripción

Imports vector layers inside a PostGIS database. A new connection to the PostGIS database must be created. The algorithm is derived from the ogr2ogr utility .

Parametros

Capa de entrada [vector: cualquiera]

<colocar la descripción de parámetros aquí>

Output geometry type [selection]

<colocar la descripción de parámetros aquí>

Opciones:

  • 0 —
  • 1 — NONE
  • 2 — GEOMETRY
  • 3 — POINT
  • 4 — LINESTRING
  • 5 — POLYGON
  • 6 — GEOMETRYCOLLECTION
  • 7 — MULTIPOINT
  • 8 — MULTIPOLYGON
  • 9 — MULTILINESTRING

Predeterminado: 5

Input CRS (EPSG Code) [crs]

<colocar la descripción de parámetros aquí>

Default: EPSG:4326

Output CRS (EPSG Code) [crs]

<colocar la descripción de parámetros aquí>

Default: EPSG:4326

Host [string]

<colocar la descripción de parámetros aquí>

Default: localhost

Port [string]

<colocar la descripción de parámetros aquí>

Default: 5432

Username [string]

<colocar la descripción de parámetros aquí>

Default: (not set)

Database Name [string]

<colocar la descripción de parámetros aquí>

Default: (not set)

Password [string]

<colocar la descripción de parámetros aquí>

Default: (not set)

Schema name [string]

Opcional

<colocar la descripción de parámetros aquí>

Default: public

Table name, leave blank to use input name [string]

Opcional

<colocar la descripción de parámetros aquí>

Default: (not set)

Primary Key [string]

Opcional

<colocar la descripción de parámetros aquí>

Default: id

Geometry column name [string]

Opcional

<colocar la descripción de parámetros aquí>

Default: geom

Vector dimensions [selection]

<colocar la descripción de parámetros aquí>

Opciones:

  • 0 — 2
  • 1 — 3

Predeterminado: 0

Distance tolerance for simplification [string]

Opcional

<colocar la descripción de parámetros aquí>

Default: (not set)

Maximum distance between 2 nodes (densification) [string]

Opcional

<colocar la descripción de parámetros aquí>

Default: (not set)

Select features by extent (defined in input layer CRS) [extent]

<colocar la descripción de parámetros aquí>

Por defecto: 0,1,0,1

Clip the input layer using the above (rectangle) extent [boolean]

<colocar la descripción de parámetros aquí>

Predeterminado: False

Select features using a SQL "WHERE" statement (Ex: column="value") [string]

Opcional

<colocar la descripción de parámetros aquí>

Default: (not set)

Group "n" features per transaction (Default: 20000) [string]

Opcional

<colocar la descripción de parámetros aquí>

Default: (not set)

Overwrite existing table? [boolean]

<colocar la descripción de parámetros aquí>

Por defecto: True

Append to existing table? [boolean]

<colocar la descripción de parámetros aquí>

Predeterminado: False

Append and add new fields to existing table? [boolean]

<colocar la descripción de parámetros aquí>

Predeterminado: False

Do not launder columns/table name/s? [boolean]

<colocar la descripción de parámetros aquí>

Predeterminado: False

Do not create Spatial Index? [boolean]

<colocar la descripción de parámetros aquí>

Predeterminado: False

Continue after a failure, skipping the failed feature [boolean]

<colocar la descripción de parámetros aquí>

Predeterminado: False

Additional creation options [string]

Opcional

<colocar la descripción de parámetros aquí>

Default: (not set)

Salidas

Uso de la consola

processing.runalg('gdalogr:importvectorintopostgisdatabasenewconnection', input_layer, gtype, s_srs, t_srs, host, port, user, dbname, password, schema, table, pk, geocolumn, dim, simplify, segmentize, spat, clip, where, gt, overwrite, append, addfields, launder, index, skipfailures, options)

Ver también

Información

Descripción

Creates an information file that lists information about an OGR-supported data source. The output will be shown in a ‘Result’ window and can be written into a HTML-file. The information includes the geometry type, feature count, the spatial extent, the projection information and many more.

Parametros

Capa de entrada [vector: cualquiera]
Input vector layer.

Salidas

Información de capa [html]
Name of the output HTML-file that includes the file information. If no HTML-file is defined the output will be written into a temporary file.

Uso de la consola

processing.runalg('gdalogr:information', input, output)

Ver también