CodeIgniter Forums
Wants to write a new db driver - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived General Discussion (https://forum.codeigniter.com/forumdisplay.php?fid=21)
+--- Thread: Wants to write a new db driver (/showthread.php?tid=30070)



Wants to write a new db driver - El Forum - 05-02-2010

[eluser]Yours3lf[/eluser]
Hello all,

is it possible to write a new db driver for codeigniter?
If so, how?
(I want to write a new one for SQL server in PDO style - using the pdo driver which i enabled in php.ini)


Wants to write a new db driver - El Forum - 05-02-2010

[eluser]WanWizard[/eluser]
Create a new directory in ./system/database/drivers.

In that directory you need to create the four files that are present in all other directories, <driver_name>_driver, _forge, _result and _utility. Look in the existing ones what methods are defined, and make sure your driver classes contain all of these methods.


Wants to write a new db driver - El Forum - 05-05-2010

[eluser]Yours3lf[/eluser]
thanks, I've started to make it, achieving great progress... Smile


Wants to write a new db driver - El Forum - 05-05-2010

[eluser]whobutsb[/eluser]
@Yours3lf - let me know how it comes out. I use MSSQL for my main database and I would be interested in trying a new database driver with CI. Thanks!


Wants to write a new db driver - El Forum - 05-05-2010

[eluser]Jamie Rumbelow[/eluser]
Hi Yours3lf,

It's great that you're building something for CodeIgniter! Once you've finished it, I'm sure there will be a lot of people interested in using this library, so it'd be great if you could post it in the "Ignited Code" section of the forums here.

Thanks!

Jamie


Wants to write a new db driver - El Forum - 05-09-2010

[eluser]Yours3lf[/eluser]
@whobutsb:

How it comes out? I dont know probably I'm going to post it to the discussion Jamie mentioned, and it will work with MsSQL database (probably the new R2 edition), with the new PDO driver for PHP provided by Microsoft, and of course will only work with Codeigniter, however I'm sure I can make a version for non-Codeigniter users.
When? planning end of may, 2010, but if it's harder than I thought, it's gonna be june...

and I will also include the download link of the PDO driver (an installer, so it's easy to work with)

Best regards,
Yours3lf


Wants to write a new db driver - El Forum - 06-18-2010

[eluser]Yours3lf[/eluser]
I have posted it here:
PDO driver