Compute
Elastic Cloud Server
Huawei Cloud Flexus
Bare Metal Server
Auto Scaling
Image Management Service
Dedicated Host
FunctionGraph
Cloud Phone Host
Huawei Cloud EulerOS
Networking
Virtual Private Cloud
Elastic IP
Elastic Load Balance
NAT Gateway
Direct Connect
Virtual Private Network
VPC Endpoint
Cloud Connect
Enterprise Router
Enterprise Switch
Global Accelerator
Management & Governance
Cloud Eye
Identity and Access Management
Cloud Trace Service
Resource Formation Service
Tag Management Service
Log Tank Service
Config
OneAccess
Resource Access Manager
Simple Message Notification
Application Performance Management
Application Operations Management
Organizations
Optimization Advisor
IAM Identity Center
Cloud Operations Center
Resource Governance Center
Migration
Server Migration Service
Object Storage Migration Service
Cloud Data Migration
Migration Center
Cloud Ecosystem
KooGallery
Partner Center
User Support
My Account
Billing Center
Cost Center
Resource Center
Enterprise Management
Service Tickets
HUAWEI CLOUD (International) FAQs
ICP Filing
Support Plans
My Credentials
Customer Operation Capabilities
Partner Support Plans
Professional Services
Analytics
MapReduce Service
Data Lake Insight
CloudTable Service
Cloud Search Service
Data Lake Visualization
Data Ingestion Service
GaussDB(DWS)
DataArts Studio
Data Lake Factory
DataArts Lake Formation
IoT
IoT Device Access
Others
Product Pricing Details
System Permissions
Console Quick Start
Common FAQs
Instructions for Associating with a HUAWEI CLOUD Partner
Message Center
Security & Compliance
Security Technologies and Applications
Web Application Firewall
Host Security Service
Cloud Firewall
SecMaster
Anti-DDoS Service
Data Encryption Workshop
Database Security Service
Cloud Bastion Host
Data Security Center
Cloud Certificate Manager
Edge Security
Managed Threat Detection
Blockchain
Blockchain Service
Web3 Node Engine Service
Media Services
Media Processing Center
Video On Demand
Live
SparkRTC
MetaStudio
Storage
Object Storage Service
Elastic Volume Service
Cloud Backup and Recovery
Storage Disaster Recovery Service
Scalable File Service Turbo
Scalable File Service
Volume Backup Service
Cloud Server Backup Service
Data Express Service
Dedicated Distributed Storage Service
Containers
Cloud Container Engine
SoftWare Repository for Container
Application Service Mesh
Ubiquitous Cloud Native Service
Cloud Container Instance
Databases
Relational Database Service
Document Database Service
Data Admin Service
Data Replication Service
GeminiDB
GaussDB
Distributed Database Middleware
Database and Application Migration UGO
TaurusDB
Middleware
Distributed Cache Service
API Gateway
Distributed Message Service for Kafka
Distributed Message Service for RabbitMQ
Distributed Message Service for RocketMQ
Cloud Service Engine
Multi-Site High Availability Service
EventGrid
Dedicated Cloud
Dedicated Computing Cluster
Business Applications
Workspace
ROMA Connect
Message & SMS
Domain Name Service
Edge Data Center Management
Meeting
AI
Face Recognition Service
Graph Engine Service
Content Moderation
Image Recognition
Optical Character Recognition
ModelArts
ImageSearch
Conversational Bot Service
Speech Interaction Service
Huawei HiLens
Video Intelligent Analysis Service
Developer Tools
SDK Developer Guide
API Request Signing Guide
Terraform
Koo Command Line Interface
Content Delivery & Edge Computing
Content Delivery Network
Intelligent EdgeFabric
CloudPond
Intelligent EdgeCloud
Solutions
SAP Cloud
High Performance Computing
Developer Services
ServiceStage
CodeArts
CodeArts PerfTest
CodeArts Req
CodeArts Pipeline
CodeArts Build
CodeArts Deploy
CodeArts Artifact
CodeArts TestPlan
CodeArts Check
CodeArts Repo
Cloud Application Engine
MacroVerse aPaaS
KooMessage
KooPhone
KooDrive
On this page

Show all

Teradata Perl Configuration

Updated on 2023-03-17 GMT+08:00

Teradata Perl parameters are used to customize rules for Teradata Perl script migration.

Open the perl-migration.properties file in the config folder and set parameters in Table 1 as required.

NOTE:
  • Parameter values are case-insensitive.
  • You can modify value of the following two parameters db-bteq-tag-name and db-tdsql-tag-name parameters in the following table:
Table 1 Parameters in the perl-migration.properties file

Parameter

Description

Value Range

Default Value

Example

  • db-bteq-tag-name

Scripts to be processed in Perl files.

BTEQ: Only the scripts under the BTEQ tag will be processed.

  • bteq

bteq

db-bteq-tag-name=bteq

  • db-tdsql-tag-name

Only the scripts under the db-tdsql-tag-name tag will be processed.

SQL_LANG: Only the scripts under the SQL_LANG tag will be processed.

sql_lang

sql_lang

db-tdsql-tag-name=sql_lang

  • add-timing-on

Whether to enable the insertion of scripts to calculate execution time.

If it is enabled, the script will be added to each input file.

  • true
  • false

false

add-timing-on=true

  • remove-intermediate-files

Whether to delete the intermediate SQL file generated by the DSC after the migration is complete.

The intermediate files contain the BTEQ and SQL_LANG syntax in SQL files. These files are used as input for DSC.

true: Delete the intermediate files.

false: Do not delete the intermediate files.

  • true
  • false

true

remove-intermediate-files=true

  • migrate-variables

Whether to enable the migration of Perl variables containing SQL statements.

Perl files can contain Perl variables with SQL statements. These variables are executed by using the PREPARE and EXECUTE statement in Perl. DSC can extract SQL statements from Perl variables and migrate them.

true: enables the migration of Perl variables containing SQL statements.

false: disables the migration of Perl variables containing SQL statements.

Example 1:

migrate-variables is set to true and input is as follows:

1
$V_SQL = "CT X1(C1 INT,C2 CHAR(30))";

Output

1
CREATE TABLE X1(C1 INT,C2 CHAR(30));

Example 2:

Input

1
2
3
4
$onesql ="SELECT trim(tablename) from dbc.tables       
           WHERE databasename = '${AUTO_DQDB}' and tablename like 'V_%' 
           order by 1;";
  $sth_rundq = $dbh->execute_query($onesql);

Output

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
  $onesql ="SELECT
          TRIM( tablename )
     FROM
          dbc.tables
     WHERE
          databasename = '${AUTO_DQDB}'
          AND tablename LIKE 'V_%'
     ORDER BY
          1
;

";
  $sth_rundq = $dbh->execute_query($onesql);
  • true
  • false

true

migrate-variables=true

  • logging-level

Logging level of Teradata Perl migration log files.

error: Log only errors.

warning: Log errors and warnings.

info: Log errors, warnings, and activity information. This level contains all log information.

  • error
  • warning
  • info

info

logging-level=info

  • log-file-count

Maximum number of log files retained, including the log files in use and archived log files.

If the number of log files exceeds the upper limit, the earliest files will be deleted until the new log files are successfully archived.

3 - 10

5

log-file-count=10

  • log-file-size

Maximum file size.

Upon reaching the specified size, a file is archived by adding a timestamp to the file name.

Example:

perlDSC_2018-07-08_16_12_08.log

After the archiving, a new log file perlDSC.log with a timestamp is generated.

1MB - 10MB

5MB

log-file-size=10MB

  • migrate-executequery

Whether to enable the migration of execute_query containing SQL statements.

true: enables the migration of execute_query containing SQL statements.

false: disables the migration of execute_query containing SQL statements.

For example:

migrate-executequery is set to true and input is as follows:

1
2
my $rows1=$conn1->execute_query("sel ${selectclause} from ${databasename}.${tablename};
         ");

Output

1
2
3
4
5
my $rows1=$conn1->execute_query("SELECT
          ${selectclause}
     FROM
          ${databasename}.${tablename}
;");
  • true
  • false

true

migrate-executequery =true

We use cookies to improve our site and your experience. By continuing to browse our site you accept our cookie policy. Find out more

Feedback

Feedback

Feedback

0/500

Selected Content

Submit selected content with the feedback