Is there anywhere I can get these in binary?
Or is my only option to compile Postgres from source??
Larry Rosenman wrote:
--On Friday, January 31, 2003 01:34:42 -0800 David Durst
[EMAIL PROTECTED] wrote:
Does there exsist a MD5 Function I can call???
look at /contrib/pgcrypto in the source
is there a example on how to pass user defined types into
a function??
What I am looking for is something of this nature.
CREATE TYPE dumby_type AS (dumby_id int4, dumby_name text);
create function kick_dumby(dumby dumby_type) returns INTEGER AS '
DECLARE
somenumber integer;
BEGIN
return 1;
David Durst [EMAIL PROTECTED] writes:
insert into journal_lines
(entry_id,account_id,line_type,line_amount)
values (eid,aid,ltype,amount);
select into line * from journal_lines where entry_id = eid AND
account_id = aid AND ltype = ltype;
I bet that last should be line_type = ltype
I have a function that is to create a Accounting JOURNAL entry.
The strange thing is the function works for simple entries such as:
Cash - Debit 100
A/R - Credit 100
But when I try to trick it or break it for testing purposes (IT DOES BREAK
WHEN IT SHOULDN'T) on a entry like this:
Cash -
I recieve this error when executing the following function:
select lookup_journal_entries(to_date('20030125','MMDD'),
to_date('20030125','MMDD'));
Here is the function itself:
create function lookup_journal_entries(date,date) returns setof journal as '
I figured out the issue, DH stupid mistake
select entry_id, entry_description from
lookup_journal_entries(to_date('20030125','MMDD'),
to_date('20030125','MMDD'));
I recieve this error when executing the following function:
select
here is a possible NON-Cron solution that a friend of mine came up w/
1) Create a table w/ scheduled events and Account Ids attached to them.
2) Create a table w/ temporal event execution timestamps.
3) On journal entry check to see if there any schedule events for the Account
4) Check timestamp
Are there functions for adding and subtracting this type from itself?
Or is there a simple way to do it?
---(end of broadcast)---
TIP 4: Don't 'kill -9' the postmaster
David,
Are there functions for adding and subtracting this type from itself?
Or is there a simple way to do it?
The MONEY type is depreciated, and should have been removed from the
Postgres source but was missed as an oversight. Use NUMERIC instead.
--
-Josh Berkus
Aglio Database
Can anyone tell me why postgres is creating a implicit index when
I already have a PKEY specified
Or am I just interpreting this all wrong?
Here is the entry I am putting in:
create sequence journal_line_id_seq increment 1 start 1;
create table journal_lines (
journal_line_id int4
I have a function that I want to return setof a table in plpgsql.
Here is what I have:
CREATE FUNCTION lookup_account(varchar(32)) RETURNS SETOF accounts AS '
DECLARE
aname ALIAS FOR $1;
rec RECORD;
BEGIN
select into rec * from accounts where accountname = aname;
return rec;
END;'
I want to create a function that will return
a row or rows of a table is this possible?
If so can someone replay with a complete example?
---(end of broadcast)---
TIP 2: you can get off all lists at once with the unregister command
(send
declared to return integer, but final statement is not a
SELECT
I thought that a insert would return a internal row #, but I am not sure
about this.
Thanks,
David Durst
MIS Manager
www.la-rubber.com
---(end of broadcast)---
TIP 4: Don't 'kill -9
I was wondering if there was a way of returning a complete row from a
function, in reading the documentation of CREATE FUNCTION. I was under the
impression that you could return a row by using setof, but this does not
seem to be true.
Can anyone help?
---(end of
14 matches
Mail list logo