From: Arnau <arnaulist@andromeiberica.com>
To: pgsql-performance@postgresql.org
Subject: Equivalents in PostgreSQL of MySQL's "ENGINE=MEMORY" "MAX_ROWS=1000"
Date: Tue, 03 Apr 2007 20:59:45 +0200
Message-ID: <4612A421.4060808@andromeiberica.com> (raw)
Hi all,
In MySQL when you create a table you can define something like:
CREATE TABLE `sneakers` (
`sneaker_id` char(24) NOT NULL,
`sneaker_time` int(10) unsigned NOT NULL default '0',
`sneaker_user` int(10) unsigned NOT NULL default '0',
UNIQUE KEY `sneaker_id` (`sneaker_id`)
) ENGINE=MEMORY DEFAULT CHARSET=utf8 MAX_ROWS=1000;
MySQL manual says:
"The MEMORY storage engine creates tables with contents that are stored
in memory. As indicated by the name, MEMORY tables are stored in memory.
They use hash indexes by default, which makes them very fast, and very
useful for creating temporary tables. However, when the server shuts
down, all rows stored in MEMORY tables are lost. The tables themselves
continue to exist because their definitions are stored in .frm files on
disk, but they are empty when the server restarts.
MAX_ROWS can be used to determine the maximum and minimum numbers of rows"
Is there anything similar in PostgreSQL? The idea behind this is how I
can do in PostgreSQL to have tables where I can query on them very often
something like every few seconds and get results very fast without
overloading the postmaster.
Thank you very much
--
Arnau
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-performance@postgresql.org
Cc: arnaulist@andromeiberica.com
Subject: Re: Equivalents in PostgreSQL of MySQL's "ENGINE=MEMORY" "MAX_ROWS=1000"
In-Reply-To: <4612A421.4060808@andromeiberica.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox