Subject Re: [firebird-support] Set up an ALIAS programmatically?
Author James Hitz
On Fri, Oct 10, 2008 at 6:25 AM, Alexandre Benson Smith
<iblist@...> wrote:
> Blizzard wrote:
>> Hi guys
>>
>> I've spent hours now looking for a way to do this...
>>
>> There are scripts for Linux/Unix that come with Firebird for adding
>> Aliases to the aliases.conf file -- but on Windows it seems the only way
>> to set up an alias is to manually edit the aliases.conf file.
>>
>> There's got to be a better way. I'd like to make things easy and
>> PROFESSIONAL for the customer
>> - I don't want to tell him to "Navigate to your Firebird directory,
>> usually located at C:\Program Files\Firebird\Firebird_2_1, drag the file
>> "alises.conf" into "readme.txt", add a line MYALISES = C:\Program
>> Files\MySoftware\DB.fdb"
>> --you get the point

There is no supplied tool for doing this in Windows. But you can
write a program that reads and parses the contents of aliases.conf, if
you do not want the customer to edit the file manually. It need not
be complicated:

- identify location of Firebird server (use registry [depending on
how FB is installed])
- load aliases.conf
- ignore comments
- load lines with x = yyy into a grid, TList, listbox...

... and if its cute and cross-platform, you can even donate it to the
Firebird Community

>>
>> Thanks in advance
>>
>
> There is no such tool in FB.
>
> Write a simple application that the user would select the database file
> trough a open dialog and add it to the aliases.conf.
>
> see you !
>
>
> --
> Alexandre Benson Smith
> Development
> THOR Software e Comercial Ltda
> Santo Andre - Sao Paulo - Brazil
> www.thorsoftware.com.br
>
>
> ------------------------------------
>
> ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>
> Visit http://www.firebirdsql.org and click the Resources item
> on the main (top) menu. Try Knowledgebase and FAQ links !
>
> Also search the knowledgebases at http://www.ibphoenix.com
>
> ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
> Yahoo! Groups Links
>
>
>
>