# Issues connecting to Remote SQL

**URL:** <https://community.dreamfactory.com/t/issues-connecting-to-remote-sql/440>\
**Category:** Connecting to SQL\
**Created:** [October 8, 2014, 3:17am UTC](https://community.dreamfactory.com/t/issues-connecting-to-remote-sql/440 "2014-10-08T03:17:42Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![defaultname](https://avatars.discourse-cdn.com/v4/letter/d/a88e57/32.png) [@defaultname](https://community.dreamfactory.com/u/defaultname)\
**Post date:** [October 8, 2014, 3:17am UTC](https://community.dreamfactory.com/t/issues-connecting-to-remote-sql/440/1 "2014-10-08T03:17:42Z")

</div>

Hello,

Installed dreamfactory on my mac and windows server 2012. windows server has the SQL server installed. When I connect to remote sql from MAC, I can connect and have no issues. When I connect from the same server using its ip address (exactly like I do from mac) - it gives me an error

API Error  
Failed to launch service “senseiinc”: CDbConnection failed to open the DB connection.  
DreamFactory Utility Module  
DreamFactory Utility Module: Failed to launch service “senseiinc”: CDbConnection failed to open the DB connection.

I also created a cloud version on dreamfactory server. I am able to connect to the remote sql without issues.

Help!

Thank you

---

<div class="post-metadata">

**Author:** ![Mark](https://yyz1.discourse-cdn.com/flex035/user_avatar/community.dreamfactory.com/mark/32/69_2.png) [@Mark](https://community.dreamfactory.com/u/Mark)\
**Post date:** [October 8, 2014, 1:53pm UTC](https://community.dreamfactory.com/t/issues-connecting-to-remote-sql/440/2 "2014-10-08T13:53:45Z")

</div>

Hi,

Please refer to the guide I created on connecting to sql server within a windows environment:

[Connecting to Microsoft SQL Server with DreamFactory](https://community.dreamfactory.com/t/ms-sql-connection-string-format/153/10?u=mark). Simply follow the steps and then you should be good to go. Note that the driver you will use is going to change from dblib (linux based) to sqlsrv.

Keep us posted.

- Mark

---

<div class="post-metadata">

**Author:** ![defaultname](https://avatars.discourse-cdn.com/v4/letter/d/a88e57/32.png) [@defaultname](https://community.dreamfactory.com/u/defaultname)\
**Post date:** [October 9, 2014, 3:45am UTC](https://community.dreamfactory.com/t/issues-connecting-to-remote-sql/440/3 "2014-10-09T03:45:26Z")

</div>

> [@Mark](#):
>
> Connecting to Microsoft SQL Server with DreamFactory

Perfect, thank you. The drivers did the trick, all other items were as in the document.

Both dblib and sqlsrv works (on 1.8.0 version - [dreamfactory.com](http://dreamfactory.com) and also on the server where the sql is hosted, which originally had issues). However, my local dev machine (MAC which has issues when I upgrade to 1.8, different error thread started) it is broke! This machine is still on version 1.7.8.

May be it is not related but it was working on dev machine before these changes. I will probably upgrade the dev machine to same version and test again (after the upgrade issue is resolved)

For now, I am set to work from the remote machine, until dev is set.

Thanks for help

---

<div class="post-metadata">

**Author:** ![defaultname](https://avatars.discourse-cdn.com/v4/letter/d/a88e57/32.png) [@defaultname](https://community.dreamfactory.com/u/defaultname)\
**Post date:** [October 9, 2014, 3:48am UTC](https://community.dreamfactory.com/t/issues-connecting-to-remote-sql/440/4 "2014-10-09T03:48:31Z")

</div>

Update:  
On the MAC which is still on 1.7.8 the following connection string worked -  
dblib:host=xx.xxx.xxx.xx:1433;dbname=xxxx

---

<div class="post-metadata">

**Author:** ![Mark](https://yyz1.discourse-cdn.com/flex035/user_avatar/community.dreamfactory.com/mark/32/69_2.png) [@Mark](https://community.dreamfactory.com/u/Mark)\
**Post date:** [October 9, 2014, 2:20pm UTC](https://community.dreamfactory.com/t/issues-connecting-to-remote-sql/440/5 "2014-10-09T14:20:09Z")

</div>

Great! Enjoy 😃
