Search Postgresql Archives

Re: Preventing a user to use implicit casts

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



2009/7/1 "Stéphane A. Schildknecht" <stephane.schildknecht@xxxxxxxxxxxxxxxx>:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Hi,
>
> Is there a way to define some implicit casts so that only one specific database
> user can use them, and they're not visible to others?

no - it's not possible - maybe with some very ugly hacks - you need to
hack cache.

regards
Pavel Stehule
>
> I'm facing the case where to have same behaviour as in 8.2 for this
> "Non-character data types are no longer automatically cast to TEXT" 8.3
> improvements, I used implicit casts proposed here:
>
> http://wiki.postgresql.org/images/d/d1/Pg83-implicit-casts.sql
>
> Problem yet is I can't use slony any more to replicate data, as it falls in
> error with this kind of messages:
>
> Jul  1 17:23:20 jck20 slon[6671]: [62-1] 2009-07-01 17:23:20 CEST FATAL
> cleanupThread: "select "_gvr".cleanupEvent('10 minutes'::interval,
> 'false'::boolean); " - ERROR:
> Jul  1 17:23:20 jck20 slon[6671]: [62-2]   operator is not unique: unknown ||
> integer
> Jul  1 17:23:20 jck20 slon[6671]: [62-3] LINE 1: SELECT  'PartInd_gvr_sl_log_'
> ||  $1  || '-node-' ||  $2
> Jul  1 17:23:20 jck20 slon[6671]: [62-4]                                       ^
> Jul  1 17:23:20 jck20 slon[6671]: [62-5] HINT:  Could not choose a best
> candidate operator. You might need to add explicit type casts.
> Jul  1 17:23:20 jck20 slon[6671]: [62-6] QUERY:  SELECT  'PartInd_gvr_sl_log_'
> ||  $1  || '-node-' ||  $2
> Jul  1 17:23:20 jck20 slon[6671]: [62-7] CONTEXT:  PL/pgSQL function
> "addpartiallogindices" line 28 at assignment
> Jul  1 17:23:20 jck20 slon[6671]: [62-8] SQL statement "SELECT
> "_gvr".addPartialLogIndices()"
> Jul  1 17:23:20 jck20 slon[6671]: [62-9] PL/pgSQL function "logswitch_finish"
> line 99 at PERFORM
>
> I'm quit disappointed, as if I let slony replicate the application, still in a
> process of migration to 8.3 correct behaviour can't be used, on the other hand
> if I add implicit casts to allow application to work, I can't replicate with slony.
>
> Thanks in advance for any help.
>
> Regards,
> - --
> Stéphane Schildknecht
> PostgreSQLFr - http://www.postgresql.fr
>
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.6 (GNU/Linux)
> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
>
> iD8DBQFKS6OCA+REPKWGI0ERAqw1AJ9EPWbsDTp1K0glwBVW5+KCCbhcpgCggvh0
> i8A4YmH3tg3lq7eK71IaaKI=
> =wKwd
> -----END PGP SIGNATURE-----
>
> --
> Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-general
>

-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux