TeamcenterKnowledge

Application Administration > Assistant configuration

Manually create a database for the Command Prediction Service microservice

If you choose to use an existing database for the Command Prediction Service microservice, you must create the database using template scripts prior to install. These scripts can be modified to create the database user, the tablespace, and the schema that includes the tables and indexes. Apart from changing tokens to appropriate values, and minor syntax changes, no other changes to the scripts are advisable. Manually create an Oracle database for the Command Prediction Service microservice Procedure Copy the template scripts from \tc\microservices\commandprediction_service.zip\tc\db_scripts<database>. Rename them as .sql files. Following SQL scripts must be used for on-premise Oracle database: oracle_create_predui.sql.template - Use this script to create the base schema database. oracle_update_predui.sql.template - Use this script to update the base schema database. Following SQL scripts must be used for cloud hosted Oracle database: oracle_rds_create_predui.sql.template - Use this script to create the base schema database. oracle_update_predui.sql.template - Use this script to update the base schema database. Replace the tokens to appropriate values. The following table describes the database parameters to be replaced in the template. Additionally, the comments in the template file also indicate the values that must be replaced. Parameter Example value Description @TABLESPACE_NAME@ predictivedb Name of the tablespace. @DB_PATH@ D:\oracle\data Path to the directory in which the data file will reside. @DB_USER@ predictivedbuser Database log in name for the Teamcenter database. @DB_PWD@ predictivedbpw The password for the database user. Save the modifications to the scripts and execute them. If syntax errors occur while executing the database scripts, the following additional changes are required: On the last line in the SQL script, delete one semicolon after END statement. Make sure that the last line of the SQL script ends with the / character. If not, you must insert the / character on a new line after the last line of the script The last two lines of the SQL script must appear as shown below: Copy ;END; Copy / Note For a complete database setup, it is necessary to execute both the create and update scripts after they are modified. Manually create an MSSQL database for the Command Prediction Service microservice Procedure Copy the appropriate template scripts from \tc\microservices\commandprediction_service.zip\tc\db_scripts<database>. Rename them as .sql files. The following SQL scripts must be used for the SQL Server database: mssql_create_predui.sql.template - Use this script to create the base schema for the SQL Server database. mssql_update_predui.sql.template - Use this script to update the base schema database. Replace the tokens to appropriate values. For more information, see Create an SQL Server database (Windows) or Create an SQL Server database (Linux). Save the modifications to the scripts and execute them. To execute the script on the command line, enter the following: Copy > sqlcmd -i mssql_create_predui.sql Copy > sqlcmd -i mssql_update_predui.sql For detailed information and help about the sqlcmd utility and its arguments, run the utility as follows: sqlcmd -h To execute the scripts using the SQL Server Management Studio, do the following: Open the mssql_create_predui.sql file in Microsoft SQL Server Management Studio. In the SQL Editor toolbar, click Execute, or choose Query→Execute to start creating the database. Open the mssql_update_predui.sql file in Microsoft SQL Server Management Studio. In the SQL Editor toolbar, click Execute, or choose Query→Execute to start updating the base schema database. Note For a complete database setup, it is necessary to execute both the create and update scripts after they are modified.

Source: https://docs.sw.siemens.com/documentation/external/PL20251212545240207/en-US/tc_help/AWAdmin/gdr3897369475591/xhi1737238539321/xid1914508.html · retrieved Fri Jul 31 2026 00:00:00 GMT+0000 (Coordinated Universal Time)