Creating a new data source
You use the New Datasource wizard to create new data sources in which to store Asta Powerproject projects. The wizard is divided into a number of logical stages. At each stage, you can click Next to proceed to the next screen, or Back to return to the previous screen. The number of screens you see depends on the type of data source you are creating. When you have entered all the required details, click Finish. You can cancel the creation of the new data source at any time by clicking Cancel.
To access the New
Datasource wizard, select the New
command from the Datasource menu
or click
.
This Help also applies to the Register Datasource wizard, as the steps involved in reregistering a data source are identical to those involved in creating a new data source.
Creating a database and a database user with appropriate rights
You must first create an empty Microsoft SQL ServerĀ® database.
You can choose to use the 'optimise transaction data' facility when creating a direct connection data source. This is recommended, as it speeds up the system. In order to make use of 'optimise transaction data', you must set up a database instance and a user that has database administrator rights and 'bulk insert' rights.
Ensure that the Asta Powerproject user has at least the fixed server role 'bulkadmin' assigned. Members of the bulkadmin role are allowed to execute the BULK INSERT statement, which is used when you create a data source with the 'optimise transaction data' facility, but they still must have the INSERT permission on the tables on which they wish to insert data.
Creating a new data source in Server Admin
- Within Server Admin, select the New command from the Datasource menu. The New Datasource wizard appears (if an introduction screen is displayed, click Next to skip it).
- Enter a name and description for the data source. Try to make the description describe the projects that the data source will contain.
- Enter a positive integer that links the data source to a particular server in the Server identification number field. This only applies if you have set up more than one Enterprise server on a machine, or if you want to enable users to log in automatically via Active Directory. If you only use a single server and you are not using Active Directory to enable automatic login, you can leave this number set to 1. You can make a data source inaccessible to all servers (ie take it offline), by setting this number to zero.
- Click Next. The next screen of the wizard appears.
- Click Build
to access the Connection String
Generation wizard, which you can use to create the ADO
connection string that specifies the OLE database provider and
the data source to which the Enterprise server connects. Follow
the steps in the wizard to build the connection string. You return
to the New Datasource
wizard when you have finished.
Alternatively, you can enter the connection string parameters manually in the Connection string field. The following is an example of the syntax used in a connection string:
Provider=MSOLEDBSQL;Server=;Initial Catalog=;User ID=;Password=; - Click Test to check that the connection string works correctly. You receive a message informing you whether the string is correct.
- If you are using the 'optimise transaction data' feature, which is recommended as it speeds up the system, select the Optimise transaction data check box.
- If you are using the 'optimise transaction data'
feature, you must specify whether the Enterprise server and the
database are located on the same machine. Select the Server/Database
on same machine check box if this is the case, or clear
the check box if they are located on different machines. If the
server and database are on different machines, specify a folder
in the Server/Database shared
folder field to which both server and database have access,
to be used to store temporary files. The temporary files
are stored in a subfolder, unique to the data source, within the
folder you specify.
Specify the path and name of the folder using the name of the machine on which it is located and the share name that you specify when you share the folder, rather than by referring to a local drive. For example, specify '\\Servername\Tempfolder' rather than '\\T:\Tempfolder'. - If you want to use a mapping file to provide mappings between the table and field names that Asta Powerproject expects and the actual names in the external database, select the Use a mapping file check box and select the mapping file you want to use in the field below the check box. In most cases, it is not necessary to use a mapping file. However, a mapping file is provided with Asta Powerproject: SqlServer.map. You can use this if you wish.
- Click Finish to close the New Datasource wizard and create the new data source. The data source is now ready for use.
As part of the data source creation process, Server Admin creates the tables within the new data source automatically. In the unlikely event of the table creation process failing (which is a possibility if you create a data source when you have insufficient permissions) you can generate a table creation script manually and run it to create the necessary tables.
Setting options for new data sources
Maintaining the properties of a data source