Ashish Ahlawat wrote:
Hi team
I have a very intersting question to all of you. Pls help me to build this
query, I want to fetch more that 70,000 BLOB from different customer
servers. the issue is there are some BOLB files with common names on all
servers. So I want merge these files into a singl
Hi team
I have a very intersting question to all of you. Pls help me to build this
query, I want to fetch more that 70,000 BLOB from different customer
servers. the issue is there are some BOLB files with common names on all
servers. So I want merge these files into a single BLOB during fetching
"Hector Villarreal" <[EMAIL PROTECTED]> writes:
>select into a now() - ($1::text||'days')::interval;
People keep suggesting variants of that as ways to convert numeric
values to intervals, but it's really extremely bad practice. Much
better is to use number-times-interval multiplication:
In case it is a version issue:
This should always work regardless of version:
Just cast the $1 variable as text followed by interval:
create or replace function test(integer) returns setof text as $$
declare
a record;
begin
select into a now() - ($1::text||'days')::interval;
retu
Richard Ray написа:
> On Tue, 19 Dec 2006, Milen A. Radev wrote:
>
>> Richard Ray :
>>> How should this be properly quoted
>>>
>>> create or replace function test(integer) returns setof text as $$
>>> declare
>>> a record;
>>> begin
>>> select into a now() - interval '$1 day';
>>>
am Tue, dem 19.12.2006, um 14:09:37 -0600 mailte Richard Ray folgendes:
> How should this be properly quoted
>
> create or replace function test(integer) returns setof text as $$
> declare
> a record;
> begin
> select into a now() - interval '$1 day';
> return next a;
> return;
> end
> $$
On Tue, 19 Dec 2006, Milen A. Radev wrote:
Richard Ray :
How should this be properly quoted
create or replace function test(integer) returns setof text as $$
declare
a record;
begin
select into a now() - interval '$1 day';
return next a;
return;
end
$$ language 'plpgsql';
On Tue, 19 Dec 2006, Hector Villarreal wrote:
Hi Not sure about $1 parms : you may need to use a variable to set $1 to
then cast it as interval :
create or replace function test(integer) returns setof text as $$
declare
a record;
begin
select into a now() - ($1::text||'days')::inter
Hi Not sure about $1 parms : you may need to use a variable to set $1 to
then cast it as interval :
create or replace function test(integer) returns setof text as $$
declare
a record;
begin
select into a now() - ($1::text||'days')::interval;
return next a;
return;
end
$$
Richard Ray написа:
> How should this be properly quoted
>
> create or replace function test(integer) returns setof text as $$
> declare
> a record;
> begin
> select into a now() - interval '$1 day';
> return next a;
> return;
> end
> $$ language 'plpgsql';
>
> I'm not having a lot of luc
Try
select into a now() - interval ($1 || ' day')
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
On Behalf Of Richard Ray
Sent: Tuesday, December 19, 2006 3:10 PM
To: pgsql-sql@postgresql.org
Subject: [SQL] Help with quotes in plpgsql
How should this be properly qu
How should this be properly quoted
create or replace function test(integer) returns setof text as $$
declare
a record;
begin
select into a now() - interval '$1 day';
return next a;
return;
end
$$ language 'plpgsql';
I'm not having a lot of luck
Thanks
Richard
---
[EMAIL PROTECTED] wrote:
Hi ALL
I have a Quick/small Question.
Well today is the first day for me in the Postgresql.
I want to "describe table" can any one tell me how to do it in
postgresql.
If in psql, try
\d
See the psql section of the manual for details.
Most GUI tools (e.g. pgadmin)
Hi ALL
I have a Quick/small Question.
Well today is the first day for me in the Postgresql.
I want to "describe table" can any one tell me how to do it in
postgresql.
thanks
Suma Bommagani
George Pavlov wrote:
Even though, as Tom Lane explained, CREATE TABLE AS is not the problem
here, it seems to me that might be the cleanest, least obtrusive place
to add validation. If C.T.A failed at the table creation step because of
the JOIN-produces NULLs that would be an early and decent war
Yes, the thread did not seem to go very far. The SQL standard does seem
inconsistent in this area, but that is not an argument for allowing data
constraint violation. Until the standard is modified I think it would be
good for the reputation of the DBMS we all love to come up with a fix...
Even t
Στις Τρίτη 19 Δεκέμβριος 2006 16:01, ο/η Carlos Santos έγραψε:
> Hi!
> I need to query a select that returns all the fields of an specific primary
> key, but I don't have the single column's name that is constrained as
> primary key. How can I do that?
> Something like:
> SELECT * FROM myTable WHE
Hi, George,
"George Pavlov" <[EMAIL PROTECTED]> wrote:
> In 8.1 I have a situation where nullability of user defined datatypes
> does not seem to be enforced. Using the following steps I end up with a
> table that has a column that should not be nullable, but has nulls in
> it.
Ouch. That hurts!
Hi, Ezequias,
"Ezequias Rodrigues da Rocha" <[EMAIL PROTECTED]> wrote:
> What is the interval of time the vacuum will run on my database ?
That depends on your settings and load.
Autovacuum looks at every table, and checks the number of
modifications, as well as the total number of transactions
Hi!
I need to query a select that returns all the fields of an specific primary
key, but I don't have the single column's name that is constrained as primary
key.
How can I do that?
Something like:
SELECT * FROM myTable WHERE myTable.pkey = 'foo';
Thanks
Carlos Henrique Iazzetti Santos
Compe
20 matches
Mail list logo