码迷,mamicode.com
首页 > 数据库 > 详细

node.js 访问sql server的 node_modules “msnodesql"的安装编译方法

时间:2016-04-07 01:06:18      阅读:270      评论:0      收藏:0      [点我收藏+]

标签:

http://stackoverflow.com/questions/19661811/unable-to-download-msnodesql-0-2-1-v0-10-x64-msi

首先要满足以下安装环境:

Node.js - use the latest version if possible, but it has been tested on node 0.6.10 and later
node-gyp - latest version installed globally (npm install -g node-gyp)
python 2.7.x - for node-gyp (make sure it is in the path)
Visual C++ 2010 - the Express edition is freely available from Microsoft
SQL Server Native Client 11.0 - available as Microsoft SQL Server 2012 Native Client found in the SQL Server 2012 Feature Pack


然后:
先:Download the Drive separately from http://www.microsoft.com/en-us/download/details.aspx?id=29995. Then I advise you the following:
再然后按上面的步骤进行

  • 1、download from Git Hub (msnodesql) Zipped package. Unzip it to the local drive
  • 2、In the unzipped directory replace the contents of the

    scripts/install.js
  • 3、在上面.js文件中添加一行
  • var msiVer = "v0.8" 插入在 var msiName(第16行)前,保存
  • 4、然后在node.js命令行下执行以下命令
    npm install FULL_PATH_TO_UNZIPPED_PACKAGE_DIR(此处为git hub下载的压缩包解压后的路径) -g
  • 5、在npm文件目录node_modules中就能看到msnodesql文件夹,sqlserver.node文件就在lib里面。
 

node.js 访问sql server的 node_modules “msnodesql"的安装编译方法

标签:

原文地址:http://www.cnblogs.com/xmily/p/5361730.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!