Fog Creek Software
Discussion Board




Knowledge Base
Documentation
Terry's Tips
Darren's Tips

CityDesk and someone else's online database

Now that there are clarifications and new developments on the interfacing between CityDesk and data in external databases, a new question comes up.

Suppose there is a third party database that does not reside on my own webserver but on the other party's server, is it then possible to dynamically retrieve data from this database? And if so, how?

Ruud van Soest
Tuesday, October 26, 2004

Yes, but... do you have permissions to access the data?

To clarify: it's *not* CD that is doing any external database stuff.

Bob Bloom
Tuesday, October 26, 2004

I understand, I use data from our own online database with embedded ASP code. I have all the permissions and know how to connect to it and retrieve data from it.

But I have no experience doing that with databases of other organisations. Is it just a matter of sending the right user/password combination with the connect string and then everything is as easy as if it was your own database? What does the other party have to do to make it possible, are there technically complicated things?

Ruud van Soest
Wednesday, October 27, 2004

Yes, it's possible to retrieve data from a third party database IF the third party server does allow this. The server - or better the database - has to be configured that way that it allows access from another server.

To access the database then you have to use the correct host (normally it's 'localhost' but not in that case), the correct database and of course the correct login/password in your script.

For PHP it could look like this (example):

$db_host = "db12345.provider.tld";
$db_name = "databasename";
$db_user = "username";
$db_pass = "password";

$connection = mysql_connect($db_host,$db_user,$db_pass);

$db = mysql_select_db($db_name);


The best thing would be to ask the administrator or provider of the specific database if it's possible to connect to the database from "outside".

Stefan Ganz
telepark
www.telepark.de

Stefan Ganz
Wednesday, October 27, 2004



I think with sql or mysql you can do that but not with odbc like MS ACCESS

john cesta
Wednesday, October 27, 2004

Thanks! We are using CityDesk as a sort of 'middleware' (not sure if I'm using the term correctly). I mean, it looks like we can use CD as a means to manage or retrieve all kinds of data from all kinds of sources.

That is, if you manage it well, organisationally, you can make data from many organisations accessible from one central website. These organisations could use their own CD or another tool to produce and manage their part of the data. Which minimizes the disadvantage of not really having remote management tools.

If only the new version would arrive. Helaas, alas....

Ruud van Soest
Wednesday, October 27, 2004

*  Recent Topics

*  Fog Creek Home