Esta página ainda não está disponível no idioma selecionado. Estamos trabalhando para adicionar mais opções de idiomas. Agradecemos sua compreensão.

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

Migration of Object Names Starting with $

Updated on 2025-01-09 GMT+08:00

This section describes the migration of object names starting with $.

The migration behavior for object names starting with $ is explained in the following table. Use the tdMigrateDollar configuration parameter to configure the behavior.

For details, see IN and NOT IN Conversion.

Table 1 Migration of object names starting with $

tdMigrateDollar Setting

Object Name

Migrated To

true

$V_SQL

Static object name starting with $

"$V_SQL"

true

${V_SQL}

Dynamic object name starting with $

${V_SQL}

No change: Dynamic object names not supported

false

$V_SQL

Static object name starting with $

$V_SQL

No change: Configuration parameter is set to false.

false

${V_SQL}

Dynamic object name starting with $

${V_SQL}

No change: Configuration parameter is set to false.

NOTE:

Any variable starting with $ is considered as a Value. The tool will migrate this by adding ARRAY.

Input - OBJECT STARTING WITH $
1
SELECT $C1 from p11 where $C1 NOT LIKE ANY ($sql1);

Output (tdMigrateDollar = TRUE)

1
2
3
4
5
6
7
8
9
SELECT
        "$C1"
FROM
        p11
WHERE
        "$C1" NOT LIKE ANY (
        ARRAY[ "$sql1" ]
        )
;

Output (tdMigrateDollar = FALSE)

1
2
3
4
5
6
7
8
9
SELECT
        $C1
FROM
        p11
WHERE
        $C1 NOT LIKE ANY (
        ARRAY[ $sql1 ]
        )
;
Input - Value starting with $ in LIKEALL/LIKE ANY
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
SELECT * FROM T1
WHERE T1.Event_Dt>=ADD_MONTHS(CAST('${OUT_DATE}' AS DATE FORMAT 'YYYYMMDD')+1,(-1)*CAST(T7.Tm_Range_Month AS INTEGER)) 
   AND T1.Event_Dt<=CAST('${OUT_DATE}' AS DATE FORMAT 'YYYYMMDD')
   AND T1.Cntpty_Acct_Name NOT LIKE ALL ( SELECT Tx_Cntpty_Name_Key FROM TEMP_NAME )
   AND T1.Cntpty_Acct_Name NOT LIKE ANY ( SELECT Tx_Cntpty_Name_Key FROM TEMP_NAME )
   AND T1.Cntpty_Acct_Name LIKE ALL ( SELECT Tx_Cntpty_Name_Key FROM TEMP_NAME )
   AND T1.Cntpty_Acct_Name LIKE ANY ( SELECT Tx_Cntpty_Name_Key FROM TEMP_NAME )
   AND T1.Col1 NOT LIKE ANY ($sql1)
   AND T1.Col1 NOT LIKE ALL ($sql1)
   AND T1.Col1 LIKE ANY ($sql1)
   AND T1.Col1 LIKE ALL ($sql1);

Output:

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
SELECT
          *
     FROM
          T1
     WHERE
          T1.Event_Dt >= ADD_MONTHS (CAST( '${OUT_DATE}' AS DATE ) + 1 ,(- 1 ) * CAST( T7.Tm_Range_Month AS INTEGER ))
          AND T1.Event_Dt <= CAST( '${OUT_DATE}' AS DATE )
          AND T1.Cntpty_Acct_Name NOT LIKE ALL (
               SELECT
                         Tx_Cntpty_Name_Key
                    FROM
                         TEMP_NAME
          )
          AND T1.Cntpty_Acct_Name NOT LIKE ANY (
               SELECT
                         Tx_Cntpty_Name_Key
                    FROM
                         TEMP_NAME
          )
          AND T1.Cntpty_Acct_Name LIKE ALL (
               SELECT
                         Tx_Cntpty_Name_Key
                    FROM
                         TEMP_NAME
          )
          AND T1.Cntpty_Acct_Name LIKE ANY (
               SELECT
                         Tx_Cntpty_Name_Key
                    FROM
                         TEMP_NAME
          )
          AND T1.Col1 NOT LIKE ANY (
               ARRAY[ "$sql1" ]
          )
          AND T1.Col1 NOT LIKE ALL (
               ARRAY[ "$sql1" ]
          )
          AND T1.Col1 LIKE ANY (
               ARRAY[ "$sql1" ]
          )
          AND T1.Col1 LIKE ALL (
               ARRAY[ "$sql1" ]
          )
;

QUALIFY, CASE, and ORDER BY

Input:

select 
   a.Cust_UID as Cust_UID          /*   UID */
  ,a.Rtl_Usr_Id as Ini_CM          /*        */
  ,a.Cntr_Aprv_Dt as Aprv_Pass_Tm          /*        */
  ,a.Blg_Org_Id as CM_BRN_Nbr          /*         */
  ,a.Mng_Chg_Typ_Cd  as MNG_CHG_TYP_CD          /*          */
  ,case when a.Blg_Org_Id = b.BRN_Org_Id and a.Mng_Chg_Typ_Cd= 'PMD' and a.Pst_Id in ('PB0101','PB0104') then 'Y' ----        ,        
       when a.Blg_Org_Id = b.BRN_Org_Id and a.Mng_Chg_Typ_Cd= 'DEVPMD' and a.Pst_Id ='PB0106'  then 'Y' ----            
       when a.Blg_Org_Id = b.BRN_Org_Id and a.Mng_Chg_Typ_Cd= 'DMD' and a.Pst_Id in ('PB0201','PB0204') then 'Y' ----        ,        
      when a.Blg_Org_Id = b.BRN_Org_Id and a.Mng_Chg_Typ_Cd= 'DEVDMD' and a.Pst_Id ='PB0109'  then 'Y' ----            ,
       else ''
end  as Pst_Flg          /*      */
  ,a.Pst_Id as Pst_Id          /*      */
  ,a.BBK_Org_Id  as BBK_Org_Id          /*        */
from VT_CUID_MND_NMN_CHG_INF as a          /* VT_         */
LEFT OUTER JOIN ${BRTL_VCOR}.BRTL_EM_USR_PST_REL_INF_S as b          /* EM_           */
  on  a.Rtl_Usr_Id = b.Rtl_Usr_Id          
  AND a.Blg_Org_Id  = b.BRN_Org_Id           
  AND a.Pst_Id = b.Pst_Id          
  AND b.Sys_Id = 'privatebanking'           
  AND b.pst_sts IN ('1','0','-2') /*     1   -2   0  */          
  AND b.DW_Snsh_Dt =  cast('${v_Trx_Dt}' as date format 'yyyy-mm-dd')          
qualify   row_number() over(partition by a.Cust_UID,a.bbk_org_id order by 
case when ( a.Mng_Chg_Typ_Cd= 'PMD'    and   a.Pst_Id in ('PB0101','PB0104')) or ( a.Mng_Chg_Typ_Cd= 'DEVPMD'    and   a.Pst_Id ='PB0106')   
then 0 when  (a.Mng_Chg_Typ_Cd= 'DMD' and a.Pst_Id in ('PB0201','PB0204')) or    (a.Mng_Chg_Typ_Cd= 'DEVDMD' and a.Pst_Id ='PB0109 ')   then 0 else 1 end  asc )  = 1         
;

Output:

 SELECT
                     Cust_UID AS Cust_UID /*   UID */
                     ,Ini_CM /*        */
                     ,Aprv_Pass_Tm /*        */
                     ,CM_BRN_Nbr /*         */
                     ,MNG_CHG_TYP_CD /*          */
                     ,Pst_Flg /*      */
                     ,Pst_Id AS Pst_Id /*      */
                     ,BBK_Org_Id AS BBK_Org_Id /*        */
                FROM
                     ( SELECT
                          a.Cust_UID AS Cust_UID /*   UID */
                          ,a.Rtl_Usr_Id AS Ini_CM /*        */
                          ,a.Cntr_Aprv_Dt AS Aprv_Pass_Tm /*        */
                          ,a.Blg_Org_Id AS CM_BRN_Nbr /*         */
                          ,a.Mng_Chg_Typ_Cd AS MNG_CHG_TYP_CD /*          */
                          ,CASE WHEN a.Blg_Org_Id = b.BRN_Org_Id AND a.Mng_Chg_Typ_Cd = 'PMD' AND a.Pst_Id IN ( 'PB0101' ,'PB0104' )
                                    THEN 'Y' /*         , */
                               WHEN a.Blg_Org_Id = b.BRN_Org_Id AND a.Mng_Chg_Typ_Cd = 'DEVPMD' AND a.Pst_Id = 'PB0106'
                                    THEN 'Y' /*  */
                               WHEN a.Blg_Org_Id = b.BRN_Org_Id AND a.Mng_Chg_Typ_Cd = 'DMD' AND a.Pst_Id IN ( 'PB0201' ,'PB0204' )
                                    THEN 'Y' /*         , */
                               WHEN a.Blg_Org_Id = b.BRN_Org_Id AND a.Mng_Chg_Typ_Cd = 'DEVDMD' AND a.Pst_Id = 'PB0109'
                                    THEN 'Y' /*             , */
                          ELSE
                               ''
                          END AS Pst_Flg /*      */
                          ,a.Pst_Id AS Pst_Id /*      */
                          ,a.BBK_Org_Id AS BBK_Org_Id /*        */
                          ,row_number( ) over( partition BY a.Cust_UID
                          ,a.bbk_org_id
                     ORDER BY
                          CASE WHEN( a.Mng_Chg_Typ_Cd = 'PMD' AND Q1.Pst_Id IN ( 'PB0101' ,'PB0104' ) ) OR( Q1.Mng_Chg_Typ_Cd = 'DEVPMD' AND a.Pst_Id = 'PB0106' )
                                    THEN 0
                               WHEN( a.Mng_Chg_Typ_Cd = 'DMD' AND Q1.Pst_Id IN ( 'PB0201' ,'PB0204' ) ) OR( Q1.Mng_Chg_Typ_Cd = 'DEVDMD' AND a.Pst_Id = 'PB0109 ' )
                                    THEN 0
                          ELSE
                               1
                          END ASC ) AS ROW_NUM1
                     FROM
                          VT_CUID_MND_NMN_CHG_INF AS a /* VT_         */
                          LEFT OUTER JOIN BRTL_VCOR.BRTL_EM_USR_PST_REL_INF_S AS b /* EM_           */
                               ON a.Rtl_Usr_Id = b.Rtl_Usr_Id
                          AND a.Blg_Org_Id = b.BRN_Org_Id
                          AND a.Pst_Id = b.Pst_Id
                          AND b.Sys_Id = 'privatebanking'
                          AND b.pst_sts IN ( '1' ,'0' ,'-2' ) /*     1   -2   0  */
                          AND b.DW_Snsh_Dt = CAST( lv_mig_v_Trx_Dt AS DATE ) ) Q1
                     WHERE
                          Q1.ROW_NUM1 = 1 ;

Usamos cookies para aprimorar nosso site e sua experiência. Ao continuar a navegar em nosso site, você aceita nossa política de cookies. Saiba mais

Feedback

Feedback

Feedback

0/500

Selected Content

Submit selected content with the feedback