From: | Dave Page <dpage(at)pgadmin(dot)org> |
---|---|
To: | Murtuza Zabuawala <murtuza(dot)zabuawala(at)enterprisedb(dot)com> |
Cc: | pgadmin-hackers <pgadmin-hackers(at)postgresql(dot)org> |
Subject: | Re: PATCH: Added Node Type & Catalog objects [pgAdmin4] |
Date: | 2016-03-22 09:22:29 |
Message-ID: | CA+OCxowAevPwtNb1O6Shx1NndTjNJYPBd_ie-xnk4Hw4j-nKqA@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgadmin-hackers |
Hi
On Tue, Mar 22, 2016 at 8:14 AM, Murtuza Zabuawala
<murtuza(dot)zabuawala(at)enterprisedb(dot)com> wrote:
> Hi Dave,
>
> We can create new external type using below method, By running all of below
> queries at the same time , we can not create separate external type by only
> using create type statement.
>
> So as per my discussion with Ashesh, We should not allow user to create
> external type in pgAdmin4 but only show definition in edit mode.
Hmm, would it not make sense to allow the user to create the shell
type as well (perhaps, with a new type of "SHELL")? Then they could do
what is needed (and that should be easy, as it's just CREATE TYPE
foo;)
For example:
CREATE TYPE box;
CREATE FUNCTION my_box_in_function(cstring) RETURNS box AS ... ;
CREATE FUNCTION my_box_out_function(box) RETURNS cstring AS ... ;
CREATE TYPE box (
INTERNALLENGTH = 16,
INPUT = my_box_in_function,
OUTPUT = my_box_out_function
);
CREATE TABLE myboxes (
id integer,
description box
);
--
Dave Page
Blog: http://pgsnake.blogspot.com
Twitter: @pgsnake
EnterpriseDB UK: http://www.enterprisedb.com
The Enterprise PostgreSQL Company
From | Date | Subject | |
---|---|---|---|
Next Message | Nicola | 2016-03-22 09:39:41 | Re: Fix PSQL Console plugin for OS X |
Previous Message | Murtuza Zabuawala | 2016-03-22 08:20:57 | Fwd: Stalled post to pgadmin-hackers |