views:

50

answers:

2

I have a host with php+mysql and i need to run a script here to register accounts to another host that has SQL Server and i also have php+mysql here also , but i need the accounts to be in SQL Server. how can i do this?

A: 

I don't fully understand your question, but if you want to work with mssql, there is mssql module for PHP you can use. check here. Otherwise provide more details of what you want to do.

ghostdog74
Well , i have a host ( BlueHost ) here I run the website / forum of my service ( ON another host ( dedicated server ), the service uses mssql to store account data , i need to run a register script at bluehost.
XkiD
A: 

I've had to deal with a similar issue, basically mssql inside PHP is totally fine and you have a couple of options about how to do it.

First up, there is the Microsoft php extension that will let you connect to SQL Server instances and execute queries, run procedures etc.. but with the restriction that it will only work on Windows hosts. As this was no good for me (linux hosting) I ended up not using this particular extension, but you can check it out here

If you are using linux hosting, or want to try something else on windows, you can use FreeTDS to extend your php installation with mssql functions. This also works on windows. You can read a bit more about it here - or I found the guide included with Moodle's docs to be really useful, which you can read here.

Also don't worry about having various database connections going at the same time - but do watch out for response times, as this can get really slow if you are using lots of remote connections over a bad line.

danp