Top "Plpgsql" questions

PL/pgSQL is the default procedural language for PostgreSQL.

Drop or create database from stored procedure in PostgreSQL

I have a function that looks like this: BEGIN DROP DATABASE IF EXISTS db_1; END; I'm getting the following error: …

postgresql stored-procedures plpgsql ddl dblink
Passing a ResultSet into a Postgresql Function

Is it possible to pass the results of a postgres query as an input into another function? As a very …

sql postgresql plpgsql postgresql-9.2
COPY with dynamic file name

I am trying to write a function to load csv data into a table. I want the input argument to …

sql postgresql plpgsql dynamic-sql postgresql-copy
Finding mean, standard deviation ,percentiles for all numeric variables in table

I have 30 numeric numeric columns in a table .I want to find mean,std, percentiles for all the columns in …

sql postgresql stored-procedures plpgsql greenplum
Postgres- SQL state: 22004 - query string argument of EXECUTE is null

I have a table (named VGI_table) that contains a column (named match_tabl) which contains the names of other …

postgresql postgis plpgsql dynamic-sql execute