Run External Routine Migration Tool | VantageCloud Lake - Run the External Routine Migration Tool - Teradata VantageCloud Lake

Lake - Using Queries, UDFs, and External Stored Procedures

Deployment
VantageCloud
Edition
Lake
Product
Teradata VantageCloud Lake
Release Number
Published
February 2025
ft:locale
en-US
ft:lastEdition
2025-08-12
dita:mapPath
vgj1683671089901.ditamap
dita:ditavalPath
pny1626732985837.ditaval
dita:id
vgj1683671089901
Prerequisite
  • Establish a connection to a target VantageCloud Lake system with your credentials and an authentication token. You typically receive this information from your system administrator.
  • The DBA needs to grant users the necessary privileges to create UDFs and external stored procedures in VantageCloud Lake.
    • GRANT CREATE FUNCTION, DROP FUNCTION ON database_name TO username;
    • GRANT CREATE PROCEDURE, DROP PROCEDURE ON database_name TO username
    • GRANT LOGON ON ALL TO username WITH NULL PASSWORD;
    • GRANT ALL ON SQLJ TO username;
  • tdextroutine must be installed on your local system. See Install the External Routine Installation Tool.
  • XRMigrationTool must be installed on your local system. See Install the External Routine Migration Tool.
DBC user cannot be used for creating UDFs and external stored procedures. Create a different user for this purpose.
  1. Create the migration tool config.yml file and put the file in the input directory. See Migration Tool Config File.
  2. Place the SQL script containing the DDL statements for creating the UDFs and external stored procedures in the input directory. For example, a .bteq file.
  3. Place your source files in the source directory.
  4. Run XRMigrationTool:
    Running XRMigrationTool modifies the SQL script and creates a backup of .bteq and .mvsjcl files placed in the input directory.
    XRMigrationTool -d input_directory -o output_directory -s UDF_source_directory
    XRMigrationTool creates a directory named SQLToPayload in the output directory and places the generated manifest files there.
  5. After XRMigrationTool completes converting the SQL script, run the updated SQL script to create the UDFs and external stored procedures in VantageCloud Lake.
    For details about all the options of XRMigrationTool, see External Routine Migration Tool. For an example of using XRMigrationTool, see Example: Migrating Existing UDF SQL Scripts to VantageCloud Lake.