sqlsrv_utility.php 2.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889
  1. <?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
  2. /**
  3. * CodeIgniter
  4. *
  5. * An open source application development framework for PHP 5.1.6 or newer
  6. *
  7. * @package CodeIgniter
  8. * @author EllisLab Dev Team
  9. * @copyright Copyright (c) 2008 - 2014, EllisLab, Inc.
  10. * @copyright Copyright (c) 2014 - 2015, British Columbia Institute of Technology (http://bcit.ca/)
  11. * @license http://codeigniter.com/user_guide/license.html
  12. * @link http://codeigniter.com
  13. * @since Version 1.0
  14. * @filesource
  15. */
  16. // ------------------------------------------------------------------------
  17. /**
  18. * SQLSRV Utility Class
  19. *
  20. * @category Database
  21. * @author EllisLab Dev Team
  22. * @link http://codeigniter.com/user_guide/database/
  23. */
  24. class CI_DB_sqlsrv_utility extends CI_DB_utility {
  25. /**
  26. * List databases
  27. *
  28. * @access private
  29. * @return bool
  30. */
  31. function _list_databases()
  32. {
  33. return "EXEC sp_helpdb"; // Can also be: EXEC sp_databases
  34. }
  35. // --------------------------------------------------------------------
  36. /**
  37. * Optimize table query
  38. *
  39. * Generates a platform-specific query so that a table can be optimized
  40. *
  41. * @access private
  42. * @param string the table name
  43. * @return object
  44. */
  45. function _optimize_table($table)
  46. {
  47. return FALSE; // Is this supported in MS SQL?
  48. }
  49. // --------------------------------------------------------------------
  50. /**
  51. * Repair table query
  52. *
  53. * Generates a platform-specific query so that a table can be repaired
  54. *
  55. * @access private
  56. * @param string the table name
  57. * @return object
  58. */
  59. function _repair_table($table)
  60. {
  61. return FALSE; // Is this supported in MS SQL?
  62. }
  63. // --------------------------------------------------------------------
  64. /**
  65. * MSSQL Export
  66. *
  67. * @access private
  68. * @param array Preferences
  69. * @return mixed
  70. */
  71. function _backup($params = array())
  72. {
  73. // Currently unsupported
  74. return $this->db->display_error('db_unsuported_feature');
  75. }
  76. }
  77. /* End of file mssql_utility.php */
  78. /* Location: ./system/database/drivers/mssql/mssql_utility.php */