On Aug 27, 9:24 am, felixaa <[email protected]> wrote: > Hi Again > I have this .. > > DB = Sequel.sqlite("/Users/elusuario/Database.db") > > items= DB[:items] > > ##And insert one row ... > > i_pk = items.insert(:ent => 3, :opt => 1, :title => "Test") > > ##But I have to set field :uud to primary key (i_pk) with: > > items.update(:uud => i_pk) > > Is posible to merge two sentences ??
No. You'd need to do: i_pk = items.insert(:ent => 3, :opt => 1, :title => "Test") items.filter(:id => i_pk).update(:uud => i_pk) Jeremy --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "sequel-talk" 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/sequel-talk?hl=en -~----------~----~----~----~------~----~------~--~---
