Re: Temp column not in "changing" hash in a constraint

[prev] [thread] [next] [Date index for 2005/02/02]

From: Peter Speltz
Subject: Re: Temp column not in "changing" hash in a constraint
Date: 15:10 on 02 Feb 2005
--- Tony Bowden <tony-cdbitalk@xxxxx.xxx> wrote:

> On Wed, Feb 02, 2005 at 05:29:52AM -0800, Peter Speltz wrote:
> > AFter fixing that, the recipe works fine with create. TEMP columns show up
> in
> > changing hash. They still don't show up when calling create_from_cgi. Any
> ideas why?
> 
> I would assume (now that I've refreshed my memory on all this), that
> you aren't telling CDBI::FromCGI which columns you wish it to operate
> on.
> 
> You can give it a list of columns to ignore, columns which MUST be
> filled, and/or a list or all columns in which you're interested.
> 
> The latter defaults to $class->all_columns, which (mostly for backwards
> compatability reasons) doesn't include TEMP columns.

> 
> I think that all you need to do is add your TEMP column to the
> 'all' or 'required' (depends on whether or not it's optional) list when
> calling create_from_cgi 
> 

thank you. I had forgotten about those options as i'd never used them.  PUtting
it in the "all" list works. Great.  

Putting it in required only doesn't work. i guess it has to be in "all" list in
order to be required. Don't know if this is possible or worth doing but it
seems that any "required"'s could be added to the "all" list automatically
without any harm. It saves one from having to specify all just so they can
require a TEMP column.


=====
pjs


		
__________________________________ 
Do you Yahoo!? 
Yahoo! Mail - Easier than ever with enhanced search. Learn more.
http://info.mail.yahoo.com/mail_250

Re: Temp column not in "changing" hash in a constraint
Peter Speltz 15:10 on 02 Feb 2005

Generated at 16:58 on 18 Mar 2005 by mariachi v0.52