SnowConvert AI - Scripts - Objetos identificados

Nota

Esta página da documentação é apenas para o Teradata.

O detalhamento de todos os objetos de banco de dados criados ou modificados em todos os arquivos de script (BTEQ, BTQ, FL, ML, TPUMP, TPT).

A seção Scripts - Identified Objects do relatório de avaliação da Teradata

Taxa de conversão - objeto

Nota

Um objeto é considerado migrado com sucesso se não tiver problemas de gravidade média, alta ou crítica.

Represents the percentage of identified objects by SnowConvert AI that were successfully migrated. This helps determine the number of objects that were successfully migrated and the objects that need manual work to complete the migration of the objects to Snowflake. If N/A is listed in the column, it means that the object type is not supported in Snowflake. A «-» could also be listed in this column. This means that the set of files migrated by SnowConvert AI did not contain objects of the specific type that could be identified.

Fórmula

(successfully_converted_scripts_objects / total_scripts_objects) * 100

Nomes de campos associados CSV

  • Tabelas: ScriptTableObjectConversionRate

  • Exibições: ScriptViewObjectConversionRate

  • Índice de junção: ScriptJoinIndexObjectConversionRate

  • Macro: ScriptMacroObjectConversionRate

  • Procedimentos: ScriptProcedureObjectConversionRate

  • Funções: ScriptFunctionObjectConversionRate

  • Acionadores: ScriptTriggerObjectConversionRate

  • Índices: N/A

Exemplo

CREATE SET TABLE Tables_Database.Employee
   (Associate_Id     INTEGER)
UNIQUE PRIMARY INDEX (Associate_Id);

CRATE SET TABLE Tables_Database.Employee2
   (Associate_Id     INTEGER)
UNIQUE PRIMARY INDEX (Associate_Id);
#*** Generated code is based on the SnowConvert AI Python Helpers version 2.0.6 ***

import os
import sys
import snowconvert.helpers
from snowconvert.helpers import Export
from snowconvert.helpers import exec
from snowconvert.helpers import BeginLoading
con = None
def main():
  snowconvert.helpers.configure_log()
  con = snowconvert.helpers.log_on()
  exec("""
    --** SSC-FDM-TD0024 - SET TABLE FUNCTIONALITY NOT SUPPORTED. TABLE MIGHT HAVE DUPLICATE ROWS **
    CREATE OR REPLACE TABLE Tables_Database.Employee (
      Associate_Id INTEGER,
      UNIQUE (Associate_Id)
    )
    """)
  #** SSC-EWI-0001 - UNRECOGNIZED TOKEN ON LINE '5' COLUMN '1' OF THE SOURCE CODE STARTING AT 'CRATE'. EXPECTED 'STATEMENT' GRAMMAR. LAST MATCHING TOKEN WAS 'CRATE' ON LINE '5' COLUMN '1'. CODE '81'. **
  #
  #--CRATE SET TABLE Tables_Database.Employee2
  #--   (Associate_Id     INTEGER)
  #--UNIQUE PRIMARY INDEX (Associate_Id)

  snowconvert.helpers.quit_application()

if __name__ == "__main__":
  main()

Taxa de conversão de objeto esperada: 50%

Explicação: Com o código de exemplo anterior, teremos uma taxa de conversão de objetos de 50% porque apenas uma das duas tabelas identificadas foi migrada com sucesso para o Snowflake.

Conversion Rate - Lines of Code (LOC)

Indica a porcentagem de conversão de linhas de código por extensão de arquivo.

Fórmula

(script_success_lines / script_total_lines) * 100

Nomes de campos CSV associados

  • Tabelas: ScriptTableLoCConversionRate

  • Exibições: ScriptViewLocConversionRate

  • Índice de junção: ScriptJoinIndexLoCConversionRate

  • Macros: ScriptMacroLoCConversionRate

  • Procedimentos: ScriptProcedureLoCConversionRate

  • Funções: ScriptFunctionLoCConversionRate

  • Acionadores: ScriptTriggerLoCConversionRate

  • Índices: N/A

Exemplo

CREATE SET TABLE Tables_Database.Employee
   (Associate_Id     INTEGER)
UNIQUE PRIMARY INDEX (Associate_Id);

CREATE SET TABLE Tables_Database.Employee2
   (Associate_Id     ANYTYPE!)
UNIQUE PRIMARY INDEX (Associate_Id);
#*** Generated code is based on the SnowConvert AI Python Helpers version 2.0.6 ***

import os
import sys
import snowconvert.helpers
from snowconvert.helpers import Export
from snowconvert.helpers import exec
from snowconvert.helpers import BeginLoading
con = None
def main():
  snowconvert.helpers.configure_log()
  con = snowconvert.helpers.log_on()
  exec("""
    --** SSC-FDM-TD0024 - SET TABLE FUNCTIONALITY NOT SUPPORTED. TABLE MIGHT HAVE DUPLICATE ROWS **
    CREATE OR REPLACE TABLE Tables_Database.Employee (
      Associate_Id INTEGER,
      UNIQUE (Associate_Id)
    )
    """)
  exec("""
    --** SSC-FDM-TD0024 - SET TABLE FUNCTIONALITY NOT SUPPORTED. TABLE MIGHT HAVE DUPLICATE ROWS **
    CREATE OR REPLACE TABLE Tables_Database.Employee2 (
-- ** SSC-EWI-0001 - UNRECOGNIZED TOKEN ON LINE '6' COLUMN '5' OF THE SOURCE CODE STARTING AT 'Associate_Id'. EXPECTED 'Column Definition' GRAMMAR. LAST MATCHING TOKEN WAS 'ANYTYPE' ON LINE '6' COLUMN '22'. CODE '15'. **
--                                                       Associate_Id     ANYTYPE!,
      UNIQUE (Associate_Id)
    )
    """)
  snowconvert.helpers.quit_application()

if __name__ == "__main__":
  main()

Taxa de conversão esperada para LOC: 83,33 %

Explicação: Com o código de exemplo anterior, teremos uma taxa de conversão de 83,33% em LOC porque a linha 5 do código de entrada (Associate_Id ANYTYPE!) não pôde ser migrada e somente 5 das 6 linhas totais de código foram migradas com êxito.

Nota

Para obter mais informações sobre esse tópico, consulte a seção Modos de taxa de conversão da nossa documentação.

Quantidade total de objetos

Representa a quantidade total de objetos identificados pelo SnowConvert AI durante a fase de análise.

Nomes de campos associados CSV

  • Tabelas: ScriptTableTotalOccurrences

  • Exibições: ScriptViewTotalOccurrences

  • Índice de junção: ScriptJoinIndexTotalOccurrences

  • Macros: ScriptMacroTotalOccurrences

  • Procedimentos: ScriptProcedureTotalOccurrences

  • Funções: ScriptFunctionTotalOccurrences

  • Acionadores: ScriptTriggerTotalOccurrences

  • Índices: ScriptIndexTotalOccurrences

Exemplo

-- Successfully parsed table.
CREATE SET TABLE Tables_Database.Employee
   (Associate_Id     INTEGER)
UNIQUE PRIMARY INDEX (Associate_Id);

-- Table with a parsing error that could not be identified.
CRATE SET TABLE Tables_Database.Employee2
   (Associate_Id     INTEGER)
UNIQUE PRIMARY INDEX (Associate_Id);
#*** Generated code is based on the SnowConvert AI Python Helpers version 2.0.6 ***

import os
import sys
import snowconvert.helpers
from snowconvert.helpers import Export
from snowconvert.helpers import exec
from snowconvert.helpers import BeginLoading
con = None
def main():
  snowconvert.helpers.configure_log()
  con = snowconvert.helpers.log_on()
  # Successfully parsed table.
  exec("""
    --** SSC-FDM-TD0024 - SET TABLE FUNCTIONALITY NOT SUPPORTED. TABLE MIGHT HAVE DUPLICATE ROWS **
    CREATE OR REPLACE TABLE Tables_Database.Employee (
      Associate_Id INTEGER,
      UNIQUE (Associate_Id)
    )
    """)
  #** SSC-EWI-0001 - UNRECOGNIZED TOKEN ON LINE '7' COLUMN '1' OF THE SOURCE CODE STARTING AT 'CRATE'. EXPECTED 'STATEMENT' GRAMMAR. LAST MATCHING TOKEN WAS 'CRATE' ON LINE '7' COLUMN '1'. CODE '81'. **
  #
  #---- Table with a parsing error that could not be identified.
  #--CRATE SET TABLE Tables_Database.Employee2
  #--   (Associate_Id     INTEGER)
  #--UNIQUE PRIMARY INDEX (Associate_Id)

  snowconvert.helpers.quit_application()

if __name__ == "__main__":
  main()

Quantidade total esperada de objetos: 1.

Explicação: uma tabela foi completamente analisada pelo SnowConvert AI durante a fase de análise, mas a outra tabela tem um erro de análise que faz com que oSnowConvert AI não a identifique como um objeto tabela.

Linhas de código

Represents the total number of lines of code for the identified top-level objects. It is important to take into account that the lines of code of the top-level object, as well as the comments, are used for this column. On the other hand, empty lines will not be counted in this column.

Nomes de campos associados CSV

  • Tabelas: ScriptTableTotalLinesOfCode

  • Exibições: ScriptViewTotalLinesOfCode

  • Índice de junção: ScriptJoinIndexTotalLinesOfCode

  • Macros: ScriptMacroTotalLinesOfCode

  • Procedimentos: ScriptProcedureTotalLinesOfCode

  • Funções: ScriptFunctionTotalLinesOfCode

  • Acionadores: ScriptTriggerTotalLinesOfCode

  • Índices: ScriptIndexTotalLinesOfCode

Exemplo

-- Hello World
CREATE SET TABLE Tables_Database.Employee
   (Associate_Id     INTEGER)
UNIQUE PRIMARY INDEX (Associate_Id);

CREATE SET TABLE Tables_Database.Employee2
   (-- hello world
   Associate_Id     ANYTYPE!)
UNIQUE PRIMARY INDEX (Associate_Id);
#*** Generated code is based on the SnowConvert AI Python Helpers version 2.0.6 ***

import os
import sys
import snowconvert.helpers
from snowconvert.helpers import Export
from snowconvert.helpers import exec
from snowconvert.helpers import BeginLoading
con = None
def main():
  snowconvert.helpers.configure_log()
  con = snowconvert.helpers.log_on()
  # Hello World
  exec("""
    --** SSC-FDM-TD0024 - SET TABLE FUNCTIONALITY NOT SUPPORTED. TABLE MIGHT HAVE DUPLICATE ROWS **
    CREATE OR REPLACE TABLE Tables_Database.Employee (
      Associate_Id INTEGER,
      UNIQUE (Associate_Id)
    )
    """)
  # hello world
  exec("""
    --** SSC-FDM-TD0024 - SET TABLE FUNCTIONALITY NOT SUPPORTED. TABLE MIGHT HAVE DUPLICATE ROWS **
    CREATE OR REPLACE TABLE Tables_Database.Employee2 (
-- ** SSC-EWI-0001 - UNRECOGNIZED TOKEN ON LINE '8' COLUMN '4' OF THE SOURCE CODE STARTING AT 'Associate_Id'. EXPECTED 'Column Definition' GRAMMAR. LAST MATCHING TOKEN WAS 'ANYTYPE' ON LINE '8' COLUMN '21'. CODE '15'. **
--   Associate_Id     ANYTYPE!,
      UNIQUE (Associate_Id)
    )
    """)
  snowconvert.helpers.quit_application()

if __name__ == "__main__":
  main()

Linhas de código esperadas: 8

Explicação: Nesse caso, temos 6 linhas que vêm do código usado para as instruções CREATE TABLE e 2 para comentários que estão dentro dos objetos de nível superior.

Erros de análise

Representa o número de erros de análise que estão dentro dos objetos identificados.

Nomes de campos associados CSV

  • Tabelas: ScriptTableTotalParsingErrors

  • Exibições: ScriptViewTotalParsingErrors

  • Índice de junção: ScriptJoinIndexTotalParsingErrors

  • Macros: ScriptMacroTotalLinesOfCode

  • Procedimentos: ScriptProcedureTotalParsingErrors

  • Funções: ScriptFunctionTotalParsingErrors

  • Acionadores: ScriptTriggerTotalParsingErrors

  • Índices: ScriptIndexTotalParsingErrors

Exemplo

-- Successfully parsed table.
CREATE SET TABLE Tables_Database.Employee
   (Associate_Id     INTEGER)
UNIQUE PRIMARY INDEX (Associate_Id);

-- Table with a parsing error that could not be identified.
CRATE SET TABLE Tables_Database.Employee2
   (Associate_Id     INTEGER)
UNIQUE PRIMARY INDEX (Associate_Id);
#*** Generated code is based on the SnowConvert AI Python Helpers version 2.0.6 ***

import os
import sys
import snowconvert.helpers
from snowconvert.helpers import Export
from snowconvert.helpers import exec
from snowconvert.helpers import BeginLoading
con = None
def main():
  snowconvert.helpers.configure_log()
  con = snowconvert.helpers.log_on()
  # Successfully parsed table.
  exec("""
    --** SSC-FDM-TD0024 - SET TABLE FUNCTIONALITY NOT SUPPORTED. TABLE MIGHT HAVE DUPLICATE ROWS **
    CREATE OR REPLACE TABLE Tables_Database.Employee (
      Associate_Id INTEGER,
      UNIQUE (Associate_Id)
    )
    """)
  #** SSC-EWI-0001 - UNRECOGNIZED TOKEN ON LINE '7' COLUMN '1' OF THE SOURCE CODE STARTING AT 'CRATE'. EXPECTED 'STATEMENT' GRAMMAR. LAST MATCHING TOKEN WAS 'CRATE' ON LINE '7' COLUMN '1'. CODE '81'. **
  #
  #---- Table with a parsing error that could not be identified.
  #--CRATE SET TABLE Tables_Database.Employee2
  #--   (Associate_Id     INTEGER)
  #--UNIQUE PRIMARY INDEX (Associate_Id)

  snowconvert.helpers.quit_application()

if __name__ == "__main__":
  main()

Erros de análise esperados: 1

Explicação: somente um erro de análise será relatado na coluna Erros de análise porque o SnowConvert AI conseguiu identificar apenas a primeira tabela. Como a segunda tabela não foi identificada, esses erros de análise não serão contados na coluna Erros de análise.