[Dbix-class] [DbIx::Class] How to execute stored procedure?
Jess Robinson
castaway at desert-island.me.uk
Sun May 27 19:49:24 GMT 2007
On Sun, 27 May 2007, dreel at bk.ru wrote:
> [DbIx::Class] How to execute stored procedure?
>
> I have a problem with generation of model for catalyst. It's required to use MSSQL Server stored procedures, but i don't understand how can I do it with DDIx::Class?
>
> The specificity of MSSQL is a call of SP it using STRICT SYNTAX
>
> <EXECUTE sp_name param1, param2>
>
>
> NOT SUPPORTED SYNTAX
>
> <select * from sp_name>
>
> Have you any suggestions?
> ---
> P.S. I have one decision but it's not so pretty.
> There is.
>
> 1. Call SP in Catalyst controller through DBI.
> 2. Create Static class for SP result (static table in DB).
> 3. Using standard DBIx methods for tables to retrieve SP result into a model.
>
>
There's an entry in the Cookbook on how to make a resultsource for any sql
you like, including "select * from my_sp()" or whatever.. tried looking at
it ?
Jess
More information about the Dbix-class
mailing list