Subject | Re: local server connection problem |
---|---|
Author | Adam |
Post date | 2005-10-31T01:30:24Z |
--- In firebird-support@yahoogroups.com, "msarossy" <choroidal@s...>
wrote:
pipes.
A couple of things. Firstly, rename it from .gdb to .fdb. It has
nothing to do with this problem, but will solve other problems in the
long run.
Conceptually, a RDBMS acts as a mediator between the client and the
database file. Instead of your application manipulating the physical
file (as you may be used to if you come from a Paradox or equiv type
environment), you are asking the server to make the appropriate
change.
Ok, now the firebird syntax for a "connection string" over TCP is
[server host name]:[database path]
or
[server hostname]/[firebird port number]:[database path]
Now, database path can refer to the physical path of the file, or it
can refer to what is called an alias. The alias can then point to a
file.
I strongly recommend using aliases. It allows you to physically move
a database to another drive or path in the future without having to
change any clients.
So, make the following steps (assuming windows here)
rename the gdb file to fdb.
Open "c:\Program Files\Firebird\Firebird_1_5\aliases.conf" in notepad
Add the line:
MyProductName = c:\dir\file.fdb
Save the file and close.
Change your connection string in your client applications to
server:MyProductName
This will work both locally and remotely. Depending on the
reliability of the name server, you could add a hosts entry for the
server name on each client, but I have never had to.
Adam
wrote:
>Firebird doesn't use \\ for network connections but rather named
> I am a firebird newbie so i would appreciate some help
>
> i can only connect to my databases through the network name
>
> ie with gbak it only works with \\server\dir\file.gdb rather than
> c:\dir\file.gdb
>
pipes.
A couple of things. Firstly, rename it from .gdb to .fdb. It has
nothing to do with this problem, but will solve other problems in the
long run.
Conceptually, a RDBMS acts as a mediator between the client and the
database file. Instead of your application manipulating the physical
file (as you may be used to if you come from a Paradox or equiv type
environment), you are asking the server to make the appropriate
change.
Ok, now the firebird syntax for a "connection string" over TCP is
[server host name]:[database path]
or
[server hostname]/[firebird port number]:[database path]
Now, database path can refer to the physical path of the file, or it
can refer to what is called an alias. The alias can then point to a
file.
I strongly recommend using aliases. It allows you to physically move
a database to another drive or path in the future without having to
change any clients.
So, make the following steps (assuming windows here)
rename the gdb file to fdb.
Open "c:\Program Files\Firebird\Firebird_1_5\aliases.conf" in notepad
Add the line:
MyProductName = c:\dir\file.fdb
Save the file and close.
Change your connection string in your client applications to
server:MyProductName
This will work both locally and remotely. Depending on the
reliability of the name server, you could add a hosts entry for the
server name on each client, but I have never had to.
Adam