i\'m quite new to postgres. i want to create a function (like stored procedure) that updates multiple 开发者_开发知识库rows and selects affected rows.
I keep looking for this answer online but I cannot find it. I am trying to pass one record over a PL/pgSQL function. I tried it in two ways.
Everything\'s in the title. I am Looping on a cursor and would like to have the EXIT WHEN curs%NOTFOUND
I have this function: create or replace function insert_aereo( aereo_type[] ) returns text as $$ begin return \'ok\';
I have a trigger to update my timestamps for each table. I use the following function: CREATE OR REPLACE FUNCTION update_timstamp_table0() RETURNS TRIGGER AS
In SQL Server 2005\'s T-SQL language I can shred XML value the following 开发者_JAVA百科way: SELECT
I would like to convert a given date and integer to a timestamp in a pl/pgsql function. i\'ve never done anyt开发者_如何学运维hing with pl/pgsql before, so i\'m somewhat at a loss.
I have two DB\'s one is f开发者_运维知识库eed by filtered data from another, now i\'m using perl script witch executes query on foreign DB, stores a result in a csv file, and loads it to local DB usin
since it is possible to do: INSERT INTO some_table VALUES (NEW.*) in pl/pgsql can we do somethin开发者_StackOverflow社区g similar but for UPDATE clause using NEW ? I mean i want to
I\'m not particularly accustomed to generating complex SQL queries and am having difficulty in mixing my understanding of procedural languages and of set-based operations in