Solved

Problem while creating alias names

Posted on 2002-03-14
7
204 Views
Last Modified: 2011-10-03
I'm Working with Delphi 5 and MSSQL 7. and using around 50 databases.. so i have to create aliases for each databases..now l can't create more aliases, while creating the alias thru alias manager this error occurs " Unable to write to configuration file" i think it is a config. settings problem. How can i create more aliases?
0
Comment
Question by:sumeesh
  • 2
  • 2
  • 2
  • +1
7 Comments
 

Author Comment

by:sumeesh
ID: 6864821
Urgent
0
 
LVL 4

Accepted Solution

by:
nestorua earned 50 total points
ID: 6865229
HI,
What a number of aliases is the maximum in your case?
Sincerely,
Nestorua.
0
 
LVL 6

Expert Comment

by:Stuart_Johnson
ID: 6866202
Hi Sumeesh,

When you say 50 databases, do you mean 50 databases or 50 tables?

Here's the code I use to create a BDE alias to a MS-SQL Server 2000 database:

var
  Params: TStringList;
begin
  Params := TStringList.Create;
  try
    Params.Add('USER NAME=SA');
    Params.Add('SERVER NAME=MSSQL2KSVR');
    Params.Add('DATABASE NAME=NEW17LOCAL');
    Session.AddAlias('TESTMSSQL','MSSQL', Params);
    Session.SaveConfigFile;
  finally
    Params.Free;
  end;
end;

If you're still getting configuration file errors, then you have a corrupt BDE.  Try reinstalling the BDE off the Delphi CD.

Hope this helps,

Stu
0
IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 
LVL 2

Expert Comment

by:IPCH
ID: 6867470
Why don't you use TDatabase component?

Ivan
0
 

Author Comment

by:sumeesh
ID: 6868575
i need around 50 alias per fin. year.. for the next year i want 50 more also...
0
 
LVL 6

Expert Comment

by:Stuart_Johnson
ID: 6876023
sumeesh,

Can I ask why nestorua got the points for this question when he provided no answer?  I provided working code as to how to create an alias within Delphi and you didn't even give me the courtesy of providing a reason why my code was useless too you.  I have no problems with other people getting points for something, but not when their post was a question, and especially when I provided a working answer!

Kindly explain...
0
 
LVL 2

Expert Comment

by:IPCH
ID: 6876166
Same as Stuart Johnson

Ivan
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Objective: - This article will help user in how to convert their numeric value become words. How to use 1. You can copy this code in your Unit as function 2. than you can perform your function by type this code The Code   (CODE) The Im…
Introduction The parallel port is a very commonly known port, it was widely used to connect a printer to the PC, if you look at the back of your computer, for those who don't have newer computers, there will be a port with 25 pins and a small print…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.
When you create an app prototype with Adobe XD, you can insert system screens -- sharing or Control Center, for example -- with just a few clicks. This video shows you how. You can take the full course on Experts Exchange at http://bit.ly/XDcourse.

705 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now