Complete this task to use Microsoft SQL Server 2005, 2008 or 2008
R2 as the database store for your UDDI registry data.
Before you begin
Note: The example commands provided in this topic reference
Microsoft SQL Server 2005, however these commands are also applicable
to Microsoft SQL Server 2008 and 2008 R2.
The
default name of the UDDI registry schema in the SQL scripts listed
in the following topic is UDDI30. This name is the recommended value
and is assumed throughout the UDDI information. To use a different
name, modify the SQL files listed, then substitute the new name when
UDDI30 is used in the information center.
The following steps
use a number of variables. Before you start, decide appropriate values
to use for these variables. The variables, and suggested values, are:
- <FilePath>
- The path on the hard disk of the data file uddi30.mdf or the transaction
log file uddi30Log.ldf, respectively. An example path is C:\Program
Files\Microsoft SQL Server\MSSQL$SQLS2005\Data\.
- <FileSize>
- The size of the file, in KB or MB. For uddi30.mdf, an example
value is 300MB. For uddi30Log.ldf, the minimum value is 200MB.
- <MaxSize>
- The maximum size that the file can grow to, in KB or MB. The size
must be great enough for rollback of large queries. For uddi30.mdf,
an example value is 1000MB. For uddi30Log.ldf, the minimum value is
200 MB and an example value is 800 MB.
- <FileGrowthSize>
- The increment by which the file can grow, in KB or MB. The minimum
value is 50MB.
The following restrictions
apply:
- The maximum size of discoveryURL (Business) is 4000 bytes, compared
with the UDDI specification of 4096 characters.
- For Microsoft SQL
Server, the maximum index column size is 900 bytes. Some UDDI variable
length columns might exceed this size if long values are used. In
this situation, an insert or update statement returns an SQL error.
- The following table shows the maximum field lengths that apply.
Field data is stored in UTF-8 and is two bytes for each character.
Table 1. Maximum field lengths. The
table lists the maximum field length and UDDI specification length
for each field name.Field name |
Maximum length |
UDDI specification length |
keyValue (ValueSet) |
419 characters |
765 characters |
entityKey (transferKey) |
419 characters |
765 characters |
owner (businessEntity) |
450 characters |
765 characters |
name (businessEntity) |
450 characters |
765 characters |
name_nocase (businessEntity) |
450 characters |
765 characters |
name (businessService) |
450 characters |
765 characters |
name_nocase (businessService) |
450 characters |
765 characters |
owner (tModel) |
450 characters |
765 characters |
name (tModel) |
450 characters |
765 characters |
name_nocase (tModel) |
450 characters |
765 characters |
useType (address) |
348 characters |
765 characters |
useType (phone) |
419 characters |
765 characters |
If
you want to create a
remote database, refer first to the database product documentation
about the relevant capabilities of the product.
About this task
You complete this task only once
for each UDDI registry, as part of setting up and deploying a UDDI
registry.
Procedure
- Change
the directory to app_server_root/UDDIReg/databaseScripts.
- Enter the following SQL command to
create the database by using the Microsoft SQL
Server tools:
create database UDDI30 on PRIMARY
( NAME=UDDI30_DATA,
FILENAME='<FilePath>\uddi30.mdf',
SIZE=<FileSize>
MAXSIZE=<MaxSize>
FILEGROWTH=<FileGrowthSize> )
LOG ON ( NAME = UDDI30Log,
FILENAME='<FilePath>\uddi30Log.ldf',
SIZE=<FileSize>
MAXSIZE=<MaxSize>
FILEGROWTH=<FileGrowthSize> )
- Enter the following commands to define the database structures
needed to store the UDDI data, where server_name is
the host server for the database, instance_name is
the instance of the database, login_id is the user
ID for the database, and password is the password
for that user ID.
- sqlcmd -S server_name\instance_name -U login_id -P password -i
uddi30crt_05_tables_SQLS2005.sql
- sqlcmd -S server_name\instance_name -U login_id -P password -i
uddi30crt_15_tables_SQLS2005.sql
- sqlcmd -S server_name\instance_name -U login_id -P password -i
uddi30crt_35_constraints_SQLS2005.sql
- sqlcmd -S server_name\instance_name -U login_id -P password -i
uddi30crt_45_views_SQLS2005.sql
- sqlcmd -S server_name\instance_name -U login_id -P password -i
uddi30crt_55_triggers_SQLS2005.sql
- Optional: Enter the following command if you
want the database to be used as a default UDDI node:
sqlcmd -S server_name\instance_name -U login_id -P password -i uddi30crt_70_insert_default_database_indicator.sql
What to do next
Continue with setting up and deploying your UDDI registry
node.