Calling stored procedure in codeigniter

前端 未结 4 646
执笔经年
执笔经年 2020-12-14 12:37

I am using latest codeigniter and trying to call stored procedure from my model. Also I am using mysqli as database driver. Now I am having an error when I call two stored p

4条回答
  •  温柔的废话
    2020-12-14 13:35

    Having the same problem I found another approach which doesn't change the core, but instead uses a small helper.

    Edit: The below linked asset is nowhere to be found.

    See CoreyLoose post.

    https://ellislab.com/forums/viewthread/71141/#663206

    I had to make a small adjusment to his helper though. The line

    if( get_class($result) == 'mysqli_stmt' )
    

    could possibly produce a warning since the $result sometimes is passed as a boolean. I just put a check prior to this line and now it works perfectly, with no tinkering with the core!

提交回复
热议问题