Change ALIAS in DataModel

Change ALIAS in DataModel

Post by Koen Van de Vel » Thu, 19 Dec 1996 04:00:00



Hello Paradox'rs

Can someone please help me with the next problem.

I'm converting a form from one application to an other. The both have
nearly the same lay-out and use the same table-structure.
Form1 has the following DataModel :
      +-------------------+
      | :ALIAS1:Table1.db |
      +-------------------+
           |       +-------------------+
           +---->> | :ALIAS1:Table2.db |
                   +-------------------+
                         |      +-------------------+
                         +----> | :ALIAS1:Table3.db |
                                +-------------------+

Now I want to copy Form1 to Form2 and change the DataModel to the
following :
      +-------------------+
      | :ALIAS2:Table1.db |
      +-------------------+
           |       +-------------------+
           +---->> | :ALIAS2:Table2.db |
                   +-------------------+
                         |      +-------------------+
                         +----> | :ALIAS2:Table3.db |
                                +-------------------+
There seems to be no easy way to do that.
Here's what I tried:
- add the ":ALIAS2:Table*.db" to the datamodel
- in the form: bind the Fields and TableFrames to the new Tables
- Remove the original Tables from the datamodel and make the
  1-n and 1-1 binding for the new tables

And what happens: the whole lay-out of my form is distroyed, a lot of
fields are undefined and I have got the idea I'd better start with a
new/blank form to do it all over again.

I would be much easier to keep using Form1 and only change the
definition of ALIAS1 from 'c:\dir1' to 'c:\dir2'.  But I need the two
forms at the same time. One working in 'c:\dir1' and the other in
'c:\dir2'

Ony ideas would be very appreciated,

Please reply by e-mail too because my provider seems to loose a lot of

newsarticles.

TIA,

Koen.

-------------------------------------------------------------
PROVIRON INDUSTRIES N.V.             "in abundance of water
Koen Van de Velde                     only fools are thirsty"

+32-3.870.88.20

 
 
 

Change ALIAS in DataModel

Post by H?kon Finn » Thu, 19 Dec 1996 04:00:00


If you will run the two forms at different times, then try to store them in different   (working)
directories and set up private instead of public aliases. Search for Public alias in the help
system (Paradox 5.0).

-hf

 
 
 

Change ALIAS in DataModel

Post by Dwayne Zo » Fri, 20 Dec 1996 04:00:00



> Hello Paradox'rs

> Can someone please help me with the next problem.

> I'm converting a form from one application to an other. The both have
> nearly the same lay-out and use the same table-structure.
> Form1 has the following DataModel :
>       +-------------------+
>       | :ALIAS1:Table1.db |
>       +-------------------+
>            |       +-------------------+
>            +---->> | :ALIAS1:Table2.db |
>                    +-------------------+
>                          |      +-------------------+
>                          +----> | :ALIAS1:Table3.db |
>                                 +-------------------+

> Now I want to copy Form1 to Form2 and change the DataModel to the
> following :
>       +-------------------+
>       | :ALIAS2:Table1.db |
>       +-------------------+
>            |       +-------------------+
>            +---->> | :ALIAS2:Table2.db |
>                    +-------------------+
>                          |      +-------------------+
>                          +----> | :ALIAS2:Table3.db |
>                                 +-------------------+
> There seems to be no easy way to do that.
> Here's what I tried:
> - add the ":ALIAS2:Table*.db" to the datamodel
> - in the form: bind the Fields and TableFrames to the new Tables
> - Remove the original Tables from the datamodel and make the
>   1-n and 1-1 binding for the new tables

> And what happens: the whole lay-out of my form is distroyed, a lot of
> fields are undefined and I have got the idea I'd better start with a
> new/blank form to do it all over again.

> I would be much easier to keep using Form1 and only change the
> definition of ALIAS1 from 'c:\dir1' to 'c:\dir2'.  But I need the two
> forms at the same time. One working in 'c:\dir1' and the other in
> 'c:\dir2'

> Ony ideas would be very appreciated,

> Please reply by e-mail too because my provider seems to loose a lot of

> newsarticles.

> TIA,

> Koen.

> -------------------------------------------------------------
> PROVIRON INDUSTRIES N.V.             "in abundance of water
> Koen Van de Velde                     only fools are thirsty"

> +32-3.870.88.20

Firstly, you should change your table names on your form to be different
from the underlying table name.  Right click the table name in the data
model and then click on the table name.  For example if the table name
is :prod:customer.db change the name to customer.

Changing the master table is no problem, just right click the form name
from the project manager and select open with.  Detail tables are
another problem entirely.  A couple of options.  If the current form is
loading a table that has the alias of :WORK: in it, then just move the
form to a new directory with the new tables (that have the same name as
the original tables) and open the form as normal.

If you want to change the name of the detail tables, copy the tables and
form to a new directory.  If the tables referred to in the form have the
actual alias in them, either temporarily delete the alias or rename the
tables.  Either way, the objective is to not let Paradox find them.
When you open the form, you will be prompted for new table names.  Save
the form and you have effectively changed the detail table names.

 
 
 

Change ALIAS in DataModel

Post by Koen Van de Vel » Tue, 24 Dec 1996 04:00:00


Hey Guys,
thans for your replies
Here's one more answer I got by e-mail an wich gave the easiest way to
solve the problem.  It is easy and brilliant at the same time.

:Very simple, just follow this steps:
:1. Rename your old tables that are represented in the data-model, so
:paradox can't see them with their old names.
:2. Open your new form in design mode, paradox will complain that the tables
:you renamed are missing and you get an option to replace them by a new
:table. Now you fill in with your ALIAS2 names and all are set.
:3. Rename back the tables you hide in step 1.
--
: Stefan Bodingh - Paradox and Delphi Consulting
: Located in Haninge Sweden

Thanks Stefan, and all of you,

Koen.
-------------------------------------------------------------
PROVIRON INDUSTRIES N.V.             "in abundance of water
Koen Van de Velde                     only fools are thirsty"

+32-3.870.88.20

 
 
 

Change ALIAS in DataModel

Post by Daniel A. Morga » Wed, 25 Dec 1996 04:00:00


Quote:> It is easy and brilliant at the same time.

The only time this method does not work is when a table is referenced
within the datamodel more than one time.

Daniel Morgan
EXE Solutions

 
 
 

1. Help pls..Datamodel change control

Are there any tools for datamodel changes control for informix database.

database    change controls.  In this case, the development team wants to
understand what
   changes have been made to the underlying data model -- what fields or tables
   or relationships have been added or deleted or modified.  Also, it's the
kind of tool that   is more likely to be very database specific.  That is, the
tools developed
   and used for SQL Server would be quite different than those used for
   Informix,

2. Corrupt mmc.exe?

3. changing datamodel

4. Port number for FMPro Server on a PC: to access using IP number under hosts option

5. PDXWIN5.0; OPAL Changing DataModel

6. XML Help...

7. How to change db dir in datamodel?

8. extraction of data from two or more db at once

9. Change server Name or give it an alias?

10. Table Aliases change upon opening a view in design mode

11. Prevent dbo alias from changing database properties

12. Changing SQL Server Name or creating an alias?

13. Changing the User alias in MS SQL Server 6.5 for an active connection