Alas, my alias won't work. All is not lost.

Cringer

ProgressTalk.com Moderator
Staff member
Hoping someone can help me out here!
I'm trying to write some generic code that will work with any database connected so I am working with aliases. I've set up an empty database called ProInfo for compiling purposes which is connected to my PDSOE (11.2.1). I create my Alias (ProInfo) and run my procedure. All works fine. But if I'm running in debug mode I need the actual ProInfo DB connected and I get an error to say my alias conflicts with a database name. Can anyone help me work my way around this so that I can debug my code?
Thanks
 

Rob Fitzpatrick

ProgressTalk.com Sponsor
So if I understand this, there is a database you connect to, say foo, and you connect to it with an alias:
connect foo -ld ProInfo
Then later you need to connect to a database called ProInfo, and you can't. Correct? Did you try to delete the ProInfo alias from foo before you connect the ProInfo database?

Looking at this from another angle, why do you need aliases at all? Are you fully qualifying your table references with "ProInfo."?
 

TheMadDBA

Active Member
In general if you are trying to make something generic you either use dynamic code or use an alias that is different from any database. Like Progress uses DICTDB for all of the database admin screens.

Odds are pretty good that you don't even need an alias like Rob suggested and there is a better/safer approach depending on what you are doing.
 

Cringer

ProgressTalk.com Moderator
Staff member
It's a utility for my colleagues. The idea is they can connect up any number of databases and then examine certain elements of any one connected databases. As I've got multiple databases connected I need to alias it (I think).
As to my problem, I was being dense. Not the first time! I can just tell PDSOE not to connect a Database in the Run Configuration of the debug session and all will be well. Essentially the DB will only be there as a compile time entity then.
 
Top