On Fri, Jun 10, 2016 at 1:54 PM, rob stone <floripa...@gmail.com> wrote:

>
> Hi Ken,
>
> Would this be static or dynamic?
> For example, if you altered a column to become defined as NOT NULL,
> say, when you build the form used to maintain that table you'd like to
> have a "required" attribute against the input field for that column. So
> if it were dynamic you'd have to access the database information_schema
> each time you wanted to send the HTML down the wire as well as when
> carrying out validation.
>

Hi Rob.  I guess this is currently static, in that whenever you change the
tables you have to run an update process that rereads the tables and stores
the configuration information.


> Also, views are updateable and you'd have to check the tables and

columns making up the view.
>

Yeah.  We're not using any updateable views at the moment, so for now I'd
be happy for this to work with tables.  One step at a time! :)


> I've never used pg_meta_data but it might be helpful.
> Another thought would be to write a program that scanned all the tables
> in your database and wrote out a table in your application's schema
> where the table and column constraints were synthesised in a way
> suitable for use in PHP code.
>
> I'm not sure I'm following this one.  Wouldn't such a program have to
parse the SQL and convert it to PHP anyway?


> Cheers,
> Rob
>

Thanks!

Ken

-- 
AGENCY Software
A Free Software data system
By and for non-profits
*http://agency-software.org/ <http://agency-software.org/>*
*https://agency-software.org/demo/client
<https://agency-software.org/demo/client>*
ken.tan...@agency-software.org
(253) 245-3801

Subscribe to the mailing list
<agency-general-requ...@lists.sourceforge.net?body=subscribe> to
learn more about AGENCY or
follow the discussion.

Reply via email to