It was a little tricky with the instance of MS sql Server and you have to 
use forward slashed and back slashes

but this works

db_mssql = DAL('mssql://user:pass@SERVER\INSTANCE/DatabaseName')

db_mssql = DAL('mssql://user:pass@SERVER\SQLEXPRESS/DATABASE')

On Thursday, September 6, 2012 11:41:21 AM UTC+2, Gregg Branquinho wrote:
>
> Yeahm I am very tentative as I this is my first time working web2py and I 
> was worried intoduciny and error in db.py would stop the admin interface 
> from running.. After reading the code it seem it won't..
>
> Still cant get the conneciton open but that is probally a sql server 
> problem..
>
> On Thursday, September 6, 2012 10:50:47 AM UTC+2, Niphlod wrote:
>>
>> yep. Wouldn't it be faster if you just try that out ?
>>
>> On Thursday, September 6, 2012 10:12:56 AM UTC+2, Gregg Branquinho wrote:
>>>
>>> is it as simple as adding new global dabase objects in the db.py ?
>>>
>>> On Wednesday, 5 September 2012 22:18:37 UTC+2, Niphlod wrote:
>>>>
>>>> if you want to use the dal to retrieve data from your databases you 
>>>> should connect to them.
>>>>
>>>> dbmysql = DAL('mysql://...')
>>>> dbmmsql = DAL('mssql://...')
>>>>
>>>> What is your issue ?
>>>>
>>>> On Wednesday, September 5, 2012 6:18:23 PM UTC+2, Gregg Branquinho 
>>>> wrote:
>>>>>
>>>>> I am building a json webservice in web2py and it is being used by many 
>>>>> different frontends..
>>>>>
>>>>> What I am looking to do on the back end is connected to external 
>>>>> databases (1 postgre, 2 mssql) and return the correlated data from the 
>>>>> different servers to the json client.
>>>>>
>>>>> What I am struggling with is how to connect to any external database 
>>>>> from web2py and should I sue the DAL layer to coonect to all these 
>>>>> different servers ??
>>>>>
>>>>> Any advice would be greatly apprieciated.
>>>>>
>>>>>
>>>>>
>>>>> Kind Regards
>>>>> GRegg
>>>>>
>>>>

-- 



Reply via email to