On 10/24/2007 10:50 AM, John Siracusa wrote:

> What it doesn't do, as you noticed, is set the column type to "serial".
> Instead, it uses "integer."  Technically, this is a more accurate reflection
> of the SQLite data type.  Functionally, it does not prevent the column from
> working as expected.

True. Although AFAIK, sqlite actually stores everything but the PK as a char
string and ignores the data type. So if you had an autoincrementing column that
wasn't the PK, it wouldn't strictly be an integer but it would be serial.

> 
> I can see how the documentation might lead you to believe that the Loader
> would create a column of type "serial" when presented with the db definition
> above.  (What it actually says is the opposite: make a column of type serial
> in your class manually.)

Yes, I usually do it manually. Except that now I'm trying to automate it with
this Garden project. :)

> 
> Anyway, I can't decide if this is a bug or not.  You tell me :)  What's more
> appropriate for the loader to produce for an "integer auto-increment" db
> column definition?  An "integer" column that behaves auto-increment-y (the
> current behavior) or a "serial" column that also behaves that way?

I would prefer 'serial' so that the distinction can be mapped more granularly
to a RHTMLO Field type. For example, the working column-to-field map I have now
maps the 'serial' type to 'hidden' fields, while 'integer' maps to 'integer'
fields. [Whether serial values should be hidden in a form is, of course, a
matter of opinion, which is why the map will be configurable.]

On a related note, would you be willing to consider a Float RHTMLO field class?
I have one somewhere I can send, or I can release it in the Rose::HTMLx::
namespace as well.

Thanks, John.

pek

-- 
Peter Karman  .  [EMAIL PROTECTED]  .  http://peknet.com/


-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
Rose-db-object mailing list
Rose-db-object@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rose-db-object

Reply via email to