Thread: Interfacing with MSAccess

Interfacing with MSAccess

From
"Mihai Gheorghiu"
Date:
Exporting tables from Access to PG using ODBC driver Greatbridge 1.00.0000.
Function in PG to check data validity:

CREATE FUNCTION my_MonthlyPayment (NUMERIC, NUMERIC, INTEGER)
 RETURNS NUMERIC
 -- Returns monthly payment for  $1: loan
 --    $2: annual interest rate, in %
 --    $3: number of months
 AS
 '
  SELECT CASE
   WHEN $2 :: float = 0.00 THEN
    ($1 :: float / $3)
    :: NUMERIC(7,2)
   ELSE
    ($1 :: float * $2 :: float / 1200.00 *
    (1.00 + $2 :: float / 1200.00) ^ $3 :: float /
    ((1.00 + $2 :: float / 1200.00) ^ $3 :: float - 1.00))
    :: NUMERIC(7,2)
  END
;'
 LANGUAGE 'sql';

After some processing (query progress indicator at half) the following error
message pops up:

Error while executing the query(non-fatal);
ERROR: fmgr_info: function 1350878: cache lookup failed (#-1)

Please help.


Re: Interfacing with MSAccess

From
Peter Eisentraut
Date:
Mihai Gheorghiu writes:

> Exporting tables from Access to PG using ODBC driver Greatbridge 1.00.0000.

Great, what exactly is this driver?

> Error while executing the query(non-fatal);
> ERROR: fmgr_info: function 1350878: cache lookup failed (#-1)

You dropped and recreated the function underlying the trigger after the
trigger was defined.  That does not work.  Drop the trigger and recreate
it.

--
Peter Eisentraut   peter_e@gmx.net   http://funkturm.homeip.net/~peter


Re: Interfacing with MSAccess

From
"Richard Huxton"
Date:
From: "Peter Eisentraut" <peter_e@gmx.net>

> Mihai Gheorghiu writes:
>
> > Error while executing the query(non-fatal);
> > ERROR: fmgr_info: function 1350878: cache lookup failed (#-1)
>
> You dropped and recreated the function underlying the trigger after the
> trigger was defined.  That does not work.  Drop the trigger and recreate
> it.

I seem to remember mention of a "dependencies" system table somewhere in the
mail archives / somewhere - is there anyone working on this? A tool like
"pgmake" to recompile everything would be very cool.

- Richard Huxton


Re: Interfacing with MSAccess

From
Bruce Momjian
Date:
> From: "Peter Eisentraut" <peter_e@gmx.net>
>
> > Mihai Gheorghiu writes:
> >
> > > Error while executing the query(non-fatal);
> > > ERROR: fmgr_info: function 1350878: cache lookup failed (#-1)
> >
> > You dropped and recreated the function underlying the trigger after the
> > trigger was defined.  That does not work.  Drop the trigger and recreate
> > it.
>
> I seem to remember mention of a "dependencies" system table somewhere in the
> mail archives / somewhere - is there anyone working on this? A tool like
> "pgmake" to recompile everything would be very cool.

pg_depend table.  No one is working on it.  I tried to talk Jan into
doing it but wasn't successful.  :-)

--
  Bruce Momjian                        |  http://candle.pha.pa.us
  pgman@candle.pha.pa.us               |  (610) 853-3000
  +  If your life is a hard drive,     |  830 Blythe Avenue
  +  Christ can be your backup.        |  Drexel Hill, Pennsylvania 19026

Re: Interfacing with MSAccess

From
"Mihai Gheorghiu"
Date:
http://www.greatbridge.org/project/psqlodbcplus/download/download.php
1.00.000 is what you read in Control Panels / ODBC

Thanks a lot,

Mihai Gheorghiu

-----Original Message-----
From: Peter Eisentraut <peter_e@gmx.net>
To: Mihai Gheorghiu <tanethq@earthlink.net>
Cc: pgsql-general@postgresql.org <pgsql-general@postgresql.org>
Date: Monday, July 09, 2001 5:44 PM
Subject: Re: [GENERAL] Interfacing with MSAccess


>Mihai Gheorghiu writes:
>
>> Exporting tables from Access to PG using ODBC driver Greatbridge
1.00.0000.
>
>Great, what exactly is this driver?
>
>> Error while executing the query(non-fatal);
>> ERROR: fmgr_info: function 1350878: cache lookup failed (#-1)
>
>You dropped and recreated the function underlying the trigger after the
>trigger was defined.  That does not work.  Drop the trigger and recreate
>it.
>
>--
>Peter Eisentraut   peter_e@gmx.net   http://funkturm.homeip.net/~peter
>