in reply to Inserting a relation into a database with Class::DBI

MyDbase::Session->insert(...) MyDbase::User->insert(...)
My question is how to do this insert with a single database access.
What are your reasons for doing it in a single operation? I am unfamiliar with the features of SQLlite. Most databases, such as Oracle, Microsoft SQL Server, Postgres and MySQL (as of version 5.0), support stored procedures. It allows you to call a procedure inside the database much like you would call a Perl sub. That way you can combine multiple operations in a single call like you requested.

Andreas
--

Replies are listed 'Best First'.
Re^2: Inserting a relation into a database with Class::DBI
by wojtyk (Friar) on May 29, 2007 at 20:35 UTC
    What are your reasons for doing it in a single operation?
    Scalable performance/speed, as well as elegance.

    I may take a look at the stored procedures you recommended.
    I was trying to avoid having to use actual SQL in my code, as it appears kludgy to me. Stored procedures appears to be a happy medium.