Hi all,
I'd like to write a function that would allow me to verify some attributes on a table so that I could give a meaningful error message...
I've been playing with passing in to a plpgsql function the following things.
CREATE OR REPLACE FUNCTION fn_verifyObject( VARCHAR, VARCHAR, BIGI
Hi,
I'm attempting to port some JDBC driver modifications to 7.4 so I can migrate
an application. Where can I find an overview of the wire protocol v3?
--
www.designacourse.com
The Easiest Way to Train Anyone... Anywhere.
Chris Smith - Lead Software Developer/Technical Trainer
MindIQ Corporati
I am developing a client application for postgreSQL in Tcl/Tk (see
http://gborg.postgresql.org/project/pfm ).
It mainly uses PgTcl or pgintcl. I don't have any problems with those,
but I am also trying to call psql from my application for SQL statements
typed directly by the user.
I have used
Mark Harrison <[EMAIL PROTECTED]> writes:
> res = PQexec(conn,"DECLARE cur CURSOR FOR select * from assets limit ");
> printf("PQexec declare %s\n", PQresStatus(PQresultStatus(res)));
> PQclear(res);
> rc = PQsendQuery(conn, fetchstr);
> printf("PQsendQuery %d\n", rc);
Here is a test program which dies in the postgres runtime. I've simplified
the code as much as I can, and I cannot see where I'm doing anything wrong.
Has anybody had success with async mode? Am I doing something wrong here?
Or are there some problems with async operation that I don't know about?
> My problem is I defined the "before" and "after"
> fields in the audit table as TEXT and when I try to move NEW or OLD into
> these fields I get the error "NEW used in query that is not in a rule".
You're trying to insert record data into a text field, that doesn't work.
OLD and NEW can be use
is it possible to use a parameter of a plpgsql-function to order a
selection
inside the function?
You need to use the FOR-IN-EXECUTE style of query. That way
you can use any string you want (including text passed in as
a parameter) to build the query inside the function ...
http://www.postgresql.
Title: Trigger & Function
I'm trying to create a trigger (AFTER INSERT, UPDATE, DELETE) as an audit routine inserting into an audit table the "before" and "after" views of the row being acted upon. My problem is I defined the "before" and "after" fields in the audit table as TEXT and when I t
Hello folks,
First a question and then the rest:
Does the PostgreSQL log contain the stored function calls with
all parameters? Or is this something that could be set?
I would appreciate anyone wiser than me to comment on the
following:
I am making an app for PostgreSQL (the server). T
Hi Richard Huxton
below is the rhdb part of the shutdown log
any indications for the failed restart?
thanks
cheng
May 28 15:43:37 sanlinux rhdb: Stopping PostgreSQL -
Red Hat Edition service:
May 28 15:43:37 sanlinux su(pam_unix)[12400]: session
opened for user postgres by (uid=0)
May 28 15:4
> Adding a cheque number primary key would work tho'
Depending on the specifics of the application, check number may not
be a 'unique' field. Automatic bank checks come to mind, on my
monthy statments they tend to always have the same check number or none
at all.
In this case I'd use a serial c
"Scot L. Harris" <[EMAIL PROTECTED]> writes:
> So given the table name is there a way to identify the column defined as
> the primary key for that table?
You need to look in pg_index.
Note that the primary key could be a multicolumn index, so starting with
the assumption that there is "the column
I really would like to know what they are going to do if somebodies´
MySQL-database crashes really hard (eg by CPU failure) and comes back with
inconsistent state. Do they agree to be liable for that, because they certified
it?
Comparing MySQL with DB2 is IMHO quite funny. Like comparing pocket ca
Hi,
is it possible to use a parameter of a plpgsql-function to order a selection
inside the function?
What i would like to do is pass a column-name/alias-name to a plpgsql function
and use the variable as order-by-parameter like this:
create function foo(varchar)
RETURNS SETOF test
AS '
I am using Postgresql 7.2.4 and php 4.2.2 to write some generic
functions to access and manipulate all tables in a database.
I have been looking for a way to identify the primary key defined in a
table. The closest I have found is a filed in the pg_class table that
is a boolean that tells me if t
I need to have each one of my PostgreSQL databases put on a
separate filesystem.
I wanted to do the following…can someone verify that
this will work?
1)
Create the following environment variables:
a. export
PGDATA01=/filesystem1
b. export PGDATA02=/filesystem2
c. export PGDATA
Ron St-Pierre <[EMAIL PROTECTED]> writes:
> I am using postgres 7.3.4 and need to be able to determine which
> database a query is being run in (from a script).
See current_database():
http://www.postgresql.org/docs/7.4/static/functions-misc.html
regards, tom lane
--
If I understand what you're
asking try:
select count_1, count_2
from
(select count(*)
AS count_1 from leads where
ad_code = '555'),
(select count(*)
AS count_2 from leads where ad_code =
'222')
;
Duane
-Original Message-From: Jeannie Stevenson
[mailto:[EMAIL PROTECTED]Se
Sent a little too quickly the
sql should look like this:
select count_1, count_2
from
(select count(*)
AS count_1 from leads where
ad_code = '555') AS DMY1,
(select count(*)
AS count_2 from leads where ad_code =
'222') AS DMY2
;
-Original Message-From: Duane Lee - EGOVX
S
Dear Richard
it was not a crash. we issued poweroff command, then
we used a dos floppy to upgrade bios on the fibrecard.
then when we reboot into the redhat AS3, the rhdb
could not start.
the log is attached.
after using pg_resetxlog, we cannot see our db, only
template0/1 listed by psql -l
ple
Title: Running Totals and other stuff
Humpfff...Last night I tried posting this and found that
dynamic IP's are now prevented from posting to the list...
Did I miss the announcement?
Hi,
I keep all of my financial data in Postgresql ( 7.4.2).
My "
Thanks for the reply. I was afraid it would come down to testing each individual
situation.µ
The table I mentioned (6 million+ records) actually is a phonebook. And searching and
filtering is possible on almost any combination of fields. So there's an index on each
individual field now and that'
zhicheng wang wrote:
dear all
after we shutdown the rh_postgres-server 7.3.6, rhdb
could not start. we tried
pg_resetxlog -f PGDATA
then the server can be started, but only template0 and
template1 db available.
our database not listed.
Was there a crash?
What do your logs say?
How much d
On Monday 31 May 2004 04:32 pm, Oliver Elphick wrote:
> On Thu, 2004-05-27 at 17:38, Jeannie Stevenson wrote:
> ...
>
> > In MSSQL I would use
> >
> > select
> > count_1=(select count(ad_code) AS "CP" from leads where ad_code =
> > '555'),
> > count_2=(select count(ad_code) AS HED" from leads where
NMB Webmaster wrote:
Sorry for CC to mailing list, I forgot!!
No problem, I do sometimes. Then on other lists, I do it when I shouldn't.
The standard backup tool for PostgreSQL is pg_dump - this indeed
just backs up the data. You should not rely on copying the files of
a running database - that wo
dear all
after we shutdown the rh_postgres-server 7.3.6, rhdb
could not start. we tried
pg_resetxlog -f PGDATA
then the server can be started, but only template0 and
template1 db available.
our database not listed.
please any help
thanks
cheng
_
On Tuesday 01 June 2004 15:24, Mike Mascari wrote:
> "Hewlett-Packard Co. (NYSE:HPQ - news) will support open-source
> software companies JBoss and MySQL on its servers as it seeks to
> compete with International Business Machines Corp. (NYSE:IBM - news)
> in offering Linux (news - web sites)-compa
Stijn Vanroye wrote:
I don't want to but in, I just find this an interesting discussion
and would like to add my 2 cents:
I have read this in the manual: (PostgreSQL 7.4beta4 documentation,
Chapter 11.3 Multicolumn Indexes) Qoute: "Multicolumn indexes should
be used sparingly. Most of the time, an
quot;
http://story.news.yahoo.com/news?tmpl=story&cid=569&ncid=738&e=1&u=/nm/20040601/tc_nm/tech_hewlettpackard_dc
Perhaps an advocacy member should persuade them otherwise...
Mike Mascari
---(end of broadcast)---
TIP 1: subscribe and
Sorry for CC to mailing list, I forgot!!
On 01/06/2004 11.35, Richard Huxton <[EMAIL PROTECTED]> wrote:
>Please CC: the mailing list too, other people might have something
>
>useful to say.
>
>NMB Webmaster wrote:
>> It is for backup purpose. I thought that in this way I could backup
>> only dat
I don't want to but in, I just find this an interesting discussion and would like to
add my 2 cents:
I have read this in the manual: (PostgreSQL 7.4beta4 documentation, Chapter 11.3
Multicolumn Indexes)
Qoute:
"Multicolumn indexes should be used sparingly. Most of the time, an index on a single
Please CC: the mailing list too, other people might have something
useful to say.
NMB Webmaster wrote:
It is for backup purpose. I thought that in this way I could backup
only data and structure of all my databases from one machine without
backuping the application files that would be on another
Gaetano Mendola wrote:
Josué Maldonado wrote:
sort_mem = 131072 # min 64, size in KB
128 MB for sort_mem is really an huge ammount of
memory considering that is not system-wide but
almost for process ( under certain operations a
single process can use more then this quantity ).
Hacke
Hale wrote:
how do I connect to an external postgresql db on ip 1.2.3.4 using DBI and
perl? any other ways to do it in perl?
perldoc DBD::Pg
perldoc DBI
The "perldoc" command offers access to all of Perl's built-in
documentation as well as almost all modules too.
There's always more than one way
[EMAIL PROTECTED] wrote:
hello,
i'm rather new to postgresql and am now standing in front of a big problem.
if i want to host my database on any provider out there, i don't now see
any chance to get my own right to insert new users into my db. because:
i'd only be able to do this, when i had the
John Wells wrote:
Guys,
I have a general question about designing databases for large data sets.
I was speaking with a colleague about an application we're preparing to
build. One of the application's tables will potentially contain 2 million
or more names, containing (at least) the fields first_n
Ago wrote:
Is it possible to put the data and structure files of Postgres
(tables, views, indicies, sequences and so on) on another machine
than that one where system files are? In other words I want to put
only the system and application files on one server and only the
structure and data files on
Richard Huxton wrote:
On Thursday 12 February 2004 20:25, Prashanthi Muthyala wrote:
Hi Richard
Hi Prashanthi - nice to hear from you again. I've taken the liberty of cc-ing
the general list on this, since there may be others who can help here.
Um - 12th Feb? Where has this been lurking, and why
Hello Vitaly,
First off, I'm a bit of a linux newbie so I'm not so sure if I get everything correct.
Next I'm not sure how far your knowledge goes and what it is exactly you don't
understand, but here goes:
Apt-get is a sort of a update/install tool. It uses ftp-sites to download and install
al
On Tuesday 01 June 2004 01:35, Josué Maldonado wrote:
> Hello List,
>
> I'm importing some data from Foxpro to Postgres, there is atable wich
> contains aprox 4.8 million rows and it size about 830MB. I uploaded it
> to Postgres using dbf2pg and worked fine, it tooks about 10-15 minutes.
> Now I'm
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Hi,
On Thu, 27 May 2004, NTPT wrote:
> I know this is a slightly offtopic, but please hlep. I need to find a (S)FTP daemon
> for my server
> (RH7.3) , that can read username, password an home directory from PGSQL table . Can
> you advise somethin
41 matches
Mail list logo