zoukankan      html  css  js  c++  java
  • [已解决]import pymssql ImportError: libsybdb.so.5

    在python3.6的环境下安装pymssql安装包,运行程序时报错:import pymssql ImportError: libsybdb.so.5
    在网上搜索了一大圈很多都是讲文件存在但是没有添加软链接。但是我搜索了以一下自己的系统,find / -name libsybdb 发现没有任何信息。
    同事在安装好的机器上测试,发现也没有该文件,但是导入pymssql并没有发生报错的情况。

    后来想到去官网上看了一眼,豁然开朗。
    第一步:
    pip install pymssql

    第二步:安装 FreeTDS

    FreeTDS is required. On some platforms, we provide a pre-compiled FreeTDS to make installing easier, but you may want to install FreeTDS before doing pip install pymssql if you run into problems or need features or bug fixes in a newer version of FreeTDS. You can build FreeTDS from source if you want the latest. If you’re okay with the latest version that your package manager provides, then you can use your package manager of choice to install FreeTDS. E.g.:

    Ubuntu/Debian:
    sudo apt-get install freetds-dev
    

    安装了一下,世界都安静了。

    果然还是官方文档靠谱,还是英语学好靠谱!下午浪费了那么多时间,为什么自己就没有想到早点去官网看一眼呢!教训真是深刻。

  • 相关阅读:
    npm命令
    前端单元测试工具karma和jest
    加解密学习之--模运算与经典密码学
    数据结构之-翻转二叉树
    数据结构之-链表倒转
    转载:MQ
    分布式ID生成器 待整理
    软件开发中的负载均衡
    制作软件过程中所产出的文档(请补充)
    多线程的创建
  • 原文地址:https://www.cnblogs.com/everfight/p/bug_fix.html
Copyright © 2011-2022 走看看