How to let the created table visible to current process when using SPI_execute("create table ...")?

From: sunpeng <bluevaley(at)gmail(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: How to let the created table visible to current process when using SPI_execute("create table ...")?
Date: 2010-09-04 05:46:44
Message-ID: AANLkTi=q1NkRZD5oqb3WjvZxtar3EfEV0UKU4xR34-m1@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

When Postmaster starts, I've forked another process AP just as syslogger,
bgwritter,...
In the process AP, If I can't find a table, I would create one, the codes
are:
char * sqlCreate_DM_ = "create table DM_( ...); ";
SPI_connect();
int ret = SPI_execute(sqlCreate_DM_, false, 1);
SPI_finish();
but after SPI_finish(); I found the created table DM_ is not visible to
current process, how to resolve it?
Thanks!

Browse pgsql-general by date

  From Date Subject
Next Message Devrim GÜNDÜZ 2010-09-04 09:08:15 Re: On-disk size of db increased after restore
Previous Message sunpeng 2010-09-04 05:26:58 Re: How to restore a Plan from a stored plan text?