Migrating existing projects under source control
There are different strategies for migrating existing source
control projects from earlier versions of PowerBuilder. This is
typically a job for the manager of a multi-user project.
The strategies you (or the project manager) can use are:
To use the first strategy, you must keep a copy of the old
version of PowerBuilder–at least until you have finished
migrating all your source-controlled PBLs.
Creating a workspace and targets
PowerBuilder 9 requires that all objects reside in
targets inside a workspace. Workspaces and targets were not available
with earlier versions of PowerBuilder, so you need to create a new
workspace and appropriate targets for any older source-controlled
PowerBuilder objects that you are migrating.
Using the Existing Application target wizard
If you keep a copy of your old version of PowerBuilder, you
can check out your application object and all other objects from
source control to a work PBL. By checking out the objects in the
older version of PowerBuilder, you make sure that no one else makes
changes to the objects before you migrate them to PowerBuilder 8.
PowerBuilder 8 requires a target to contain the PBLs that
you are migrating. You should decide whether to add the target
to an existing PowerBuilder workspace or to a new workspace that
you create specifically for the target. You can then use the Existing
Application target wizard to create a new target from the local
copies of your registered PBLs (making sure to select all the supporting
PBLs for your application on the wizard Set Library Search Path page).
When you run the wizard, PowerBuilder prompts you to migrate the PBLs
you select.
The Existing Application wizard creates a new target that
it associates with your migrated PBLs. After you have run the
wizard and migrated all the source-controlled PBLs, you can define
the source control connection profile for the workspace to point
to the old source control project if you want to maintain it, or
to a new source control project if you do not. You can then check in
(or add) the migrated objects to source control and delete the work
PBL containing the older versions of the objects. (You do not use
a separate work PBL in PowerBuilder 8.)
To migrate a source control project using the
Existing Application wizard:
-
From your old version of PowerBuilder,
check out your objects to a work PBL. -
Create a new workspace in PowerBuilder 8.
or
Open an existing workspace in PowerBuilder 8.
-
Create a new target using the Existing Application
wizard.In the wizard, point to the registered PBL with an Application
object and add all the helper PBLs to the library search path.PowerBuilder prompts you to migrate the PBLs.
- Click Yes to migrate each library in the path.
-
Create a source connection profile for the workspace
that points to the old source control project or to a new project. -
Check in the migrated objects to source control
if you are using the old source control project.or
Add the migrated objects to source control if you are
using a new source control project. - Delete the work PBL whenever you want.
Importing source control files to a new library
You can use your source control manager to check out all the
old PowerBuilder objects to a named directory or folder. If you
plan to use the same project to store your migrated objects, you
must make sure that the manager locks the files you check out of
the source control archive.
You can create a new target using the Application target wizard
in a new or existing workspace. The Application wizard lets you
select or name a new PBL file to associate with the target it creates.
You can use the Target property sheet to list any additional PBLs
you want to associate with the target.
You can then import the files that you checked out of source
control, distributing them as needed to the libraries you associated
with the new target. After importing the files, you can migrate
the target by right-clicking it in the System Tree and selecting
Migrate from the target popup menu. You should also do a full build
of the target.
After you have migrated and built the target, you can define
the connection profile for the workspace to point to the old source
control project if you want to maintain it, or to a new source control
project if you do not.
This part describes how to work with PowerScript targets in
painters, how to set properties for an application, and how to manage
PowerBuilder libraries.