Install freetds in Ubuntu to access sysbase and Microsoft SQL Server databases.

Source: Internet
Author: User
Install freetds in Ubuntu to access sysbase and Microsoft SQL Server databases.

To access sqlserver in Linux, use freetds!


: Http://www.freetds.org


CD: Enter the directory where freetds is located. (For example, CD/root/usr/local/freetds) there is a space after CD.

For example, my directory is as follows:

$ Tar zxvf freetds-stable.tgz (unzipping)

Enter the decompressed directory CD freetds-0.82/

$. /Configure -- prefix =/usr/local/freetds -- With-tdsver = 8.0 -- enable-msdblib -- enable-dbmfix -- With-GNU-LD -- enable-shared -- enable-static

After the password is entered, the configuration takes less than 1 minute.

$ Make

$ Make install

These two processes are also very fast, just a few minutes. Note: because our configuration and installation address is under/usr/local, the administrator privilege is required. You can use the sudo command.


The following shows how to configure the corresponding library file:


Freetds is installed in the/usr/local/freetds directory by default, and the library file is in the corresponding lib directory.

Edit/etc/lD. So. conf,


Insert a row:

/Usr/local/freetds/lib


Run the following command to make the change take effect:

Ldconfig

After the entire process is completed, we can set the environment under codeblocks:

/Usr/local/freetds/lib/libct. So

/Usr/local/freetds/lib/libsybdb. So

Searchdirections:

/Usr/local/freetds/include

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.