Well, in certain filesystems you can have the birth time
(like ufs2) stored in the inode struct.
So you find the file name in your $PGDATA/base directory
using the oid of your table (in pg_class),
and then you open that file with stat (2) or utimes (2) (or
from perl) to read creation data.
All
On Thu, Oct 02, 2003 at 16:01:16 -0700,
David B [EMAIL PROTECTED] wrote:
Hi folks,
I posted this question a few days ago and got no response so I guess it
cannot be done (surprising!)
So that leaves me with my business problem.
We create a table for each days activity.
After N days
CN [EMAIL PROTECTED] writes:
I thought I have got no more question in this thread, and I was wrong :-(
Is the extra 300ms in UNION essential?
Dividing, it looks like the Append node is taking about 3 microseconds
per tuple, which seems kind of a lot considering it isn't really doing
anything.
Jan Pips wrote:
How to convert the interval type into integer, float or any countable data
type at the time of table creation using
select ... into?
I'm guessing you want something like this:
SELECT EXTRACT('EPOCH' FROM INTERVAL
'1 days 4 hours 15 minutes 23 seconds');
--
Jeff Boes
I don't know if this is the correct forum for this
question but I will start here...
I have a job tracking system that I am developing with
postgresql and mac os x. I have all the pieces in
place (mostly) but i am having a problem with notify..
I am trying to set up things so that two (or more)
Well, there is a rowid and a rownum in Oracle. I don't remember which, but
one of them is significant to the current recieved result set only.
Hence; you can use it to manipulate and restrict the result set rather
than the data you're recieving from the tables. I.e. rownum 1 will always
be the
How to convert the interval type into integer, float or any countable data
type at the time of table creation using
select ... into?
Pips
---(end of broadcast)---
TIP 8: explain analyze is your friend
Hi All,
Rightnow I have a query which uses decode functionto get data in Oracle database, I want know is there any alternative function to decodewhich can do thedecode functionality in Postgresql.
Thanks in advance for your great help.
Thanks
Babu Mannem
Can you add two columns to the table creation definition, one with a
default current timestamp, the second to be updated with current time in
an on update trigger. Then perhaps you could do something like
SELECT
min(new_insert_timestamp_column),
max(new_update_timestamp_column) FROM
All,
Im not certain if what Im trying to do is
legal, but if I execute a statement like:
UPDATE my_table SET field1=new_value AND SET
field2=different_value WHERE my_table_id = key;
in psql, it reports that it has successfully updated one
record. However, the record does not
On Fri, Oct 03, 2003 at 09:23:46 +0200,
Jan Pips [EMAIL PROTECTED] wrote:
How to convert the interval type into integer, float or any countable data
type at the time of table creation using
select ... into?
You can use extract to do that. See the date/time function documentation.
Note that
On Fri, Oct 03, 2003 at 09:18:44 -0400,
John B. Scalia [EMAIL PROTECTED] wrote:
All,
I'm not certain if what I'm trying to do is legal, but if I execute a
statement like:
UPDATE my_table SET field1='new_value' AND SET field2='different_value'
WHERE my_table_id = 'key';
It
Shouldn't that be UPDATE my_table SET field1 = 'new_value', field2 =
'different_value' WHERE my_table_id = 'key';?
Wei
On Fri, 3 Oct 2003, John B. Scalia wrote:
All,
I'm not certain if what I'm trying to do is legal, but if I execute a
statement like:
UPDATE my_table SET
John,
UPDATE my_table SET field1='new_value' AND SET field2='different_value'
WHERE my_table_id = 'key';
Well, your SQL is bad:
UPDATE my_table SET field1='new_value, field2='different_value'
WHERE my_table_id = 'key';
in psql, it reports that it has successfully updated one record.
John,
Yeah, I figured out my SQL was bad and had switched to the comma
separated version, instead. In my mind, the first form should have
caused an error. I've attached a cut-and-pasted session from psql where
I used this syntax on a test table. While edited for brevity and to
obscure
John B. Scalia [EMAIL PROTECTED] writes:
UPDATE my_table SET field1='new_value' AND SET field2='different_value'
WHERE my_table_id = 'key';
The other responses have focused on your obvious syntax error, but I'm
assuming you didn't actually cut-and-paste that from your psql session.
in psql,
Hi,
i notice that when HeapTuple data are populated by a trigger
then the table oid can be retrieved from HeapTuple-t_tableOid.
When HeapTuple is populated by
SPI_exec(select * from foobar when id=667);
tuple = SPI_tuptable-tvals[0] (id is PK and row with 667 exists)
then tuple-t_tableOid is
[EMAIL PROTECTED] writes:
When HeapTuple is populated by
SPI_exec(select * from foobar when id=667);
tuple = SPI_tuptable-tvals[0] (id is PK and row with 667 exists)
then tuple-t_tableOid is always 0.
The result of a SELECT is never a raw table tuple, not even when it's a
straight select *
[EMAIL PROTECTED] writes:
are there gonna be changes in SPI or internal structs in 7.4?
No more than usual ;-). You will need to recompile shared libraries,
but (in theory) source code changes shouldn't be needed. You might want
to think about upgrading elog() calls to ereport() though.
19 matches
Mail list logo