Kevin,

Kevin Cole wrote:
> Hi,
>
> I had the same question here last week (although I was using
> PostgreSQL instead of Firebird).
>   
Sorry for the noise then, I should have checked the on-line archive, 
only subscribed a while here, so my local archive didn't show anything.
> Does Firebird offer a sequence/serial/auto-number data type?  If so,
> you could just add that to your views.
Yes it has, in older version it was called a generator, but as of 2.0 (I 
think) and can use "gen_id" or "NEXT VALUE FOR sequence".
>   In other words, just have the
> views artificially generate a unique number to satisfy SQLAlchemy,
> Elixir, TurboGears, etc.  Then make sure you never really use that key
> for anything.  (Others vetoed the idea because they were concerned
> that at some future date I might want to update something... But, if
> like me, you're fairly confident of the read-only nature, I think it
> would be fine.)
>   
I'll consider this for the views where I don't have a unique key and/or 
can't define a composite key with what I already have in there.

Thanks
Werner
>
> On 10/5/07, Werner F. Bruhin <[EMAIL PROTECTED] wrote:
>   
>> In my existing Firebird database I have some views defined.  In the
>> model I thought I could just go ahead and define them basically like
>> tables but I get an exception:
>>
>> In my case the views are always used in read-only mode, changes are made
>> to the actual table.
>>
>> |Is there someway I can define these views.  I was able to work around
>> the above exception by defining a primary key column or columns
>> (compound key) but I have one or two views which don't really have a
>> primary key.
>>
>> Appreciate any hints/tips.
>>     
>
>   


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"sqlalchemy" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sqlalchemy?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to