CodeIgniter Forums
closeCursor() or not ? - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forum-20.html)
+--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forum-23.html)
+--- Thread: closeCursor() or not ? (/thread-41323.html)



closeCursor() or not ? - El Forum - 05-04-2011

[eluser]souri84[/eluser]
Hello,

I have a new question but maybe isn't the best place to post it...

To optimize performances, in PDO, we can (must ?) to closeCursor() like:

Code:
$query->prepare(...);
...
$query->execute(array(...));
$query->fetchAll();
$query->closeCursor();

It's necessary to closeCursor in codeIgniter or it's automatic ?

thanks for your answers,

Thibaut