承接 trooney/mssql-bundle 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

trooney/mssql-bundle

Composer 安装命令:

composer require trooney/mssql-bundle

包简介

Driver for work with Microsoft SQL Server using PDO_DBLIB

README 文档

README

This bundle implements a pdo_dblib based Microsft SQL Server. The original bundle was forked from https://github.com/intellectsoft-uk/MssqlBundle.

Symfony Install

Add the trooney/mssql-bundle into composer.json

"require": {
    ....
    "trooney/mssql-bundle": "master-dev"
},

Symfony Configuration

Update the doctrine section of your config.yml to include the option driver_class

doctrine:
    dbal:
        driver:         %database_driver%
        driver_class:   \NRC\MssqlBundle\Driver\PDODblib\Driver

FreeTDS Configuration

DBLib requires FreeTDS. Your freetds.conf connection configured should look something like following:

[mssql_freetds]
    host = 172.30.252.25
    port = 1433
    tds version = 8.0
    client charset = UTF-8
    text size = 20971520

Putting everything together

Getting everything together wasn't easy. You need to complete the following steps, checking each installation is successful by connecting with the appropriate tools:

  • Install FreeTDS and configure a server connection
    • Verify with ./tsql -S mssql_freetds -U yourusername -P yourpassword
  • Install the PHP DBLib extension -- verify with PHP script containing
    • Verify $pdo = new PDO('dblib:host=mssql_freetds;dbname=yourdb', 'yourusername', 'yourpassword');
  • Install and configure the PDODblibBundle
    • Verify Some kind of SQL against your database

Notes

统计信息

  • 总下载量: 789
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 2
  • Forks: 63
  • 开发语言: PHP

其他信息

  • 授权协议: Unknown
  • 更新时间: 2012-12-21