Arquivo de artigos

SHOW COLUMNS

22/02/2024 19:30
SHOW COLUMNS show columns in table dt_test;

Snowflake IDE

22/02/2024 18:43
Snowsight: afg.ap-southeast-2.snowflakecomputing.com/console/login#/ Classic https://afg.ap-southeast-2.snowflakecomputing.com/console/login?disableDirectLogin=true  

Search on all the table - columns:

22/02/2024 18:41
SELECT *, ARRAY_CONSTRUCT( * ) combined FROM "AP_PROD"."ORACLEOACS_SIEBEL"."WC_PRODUCT_D" PROD_ORACLE where ARRAY_CONTAINS( 'CIFDA-90'::variant, combined );

Data validation example - Dual Test - DBT

21/02/2024 18:06
'=============================== WC_ASSET_CLIENT_H ================================' '==================================== DELETED =====================================' '================================ DATE COMPARISON...

Scheduling dbt with GitHub Actions: Pros & Cons

20/02/2024 18:11
Scheduling dbt with GitHub Actions: Pros & Cons A step-by-step illustration...

Identify if the columns are being used - Snowflake - multiple lines (enter)

06/08/2023 11:50
with cols as (select column_name, 'o.' || column_name as alias, 'AFG.' || table_schema || '.' || table_name as tbl_spec     from afg.information_schema.columns     where table_schema = 'RAW_FLEX_SIEBEL' and table_name = 'S_OPTY'     and column_name not in...

Identify if the columns are being used - Snowflake - 1 line

06/08/2023 11:49
 with cols as (select column_name, 'c.' || column_name as alias, 'AFG.' || table_schema || '.' || table_name as tbl_spec     from afg.information_schema.columns     where table_schema = 'RAW_FLEX_SIEBEL' and table_name = 'S_CONTACT'     and column_name not...

Snowflake - Structure data schema script

06/08/2023 11:47
 select get_ddl('table', 'S_OPTY')    https://docs.snowflake.com/en/sql-reference/functions/get_ddl https://docs.snowflake.com/en/sql-reference/functions/get_ddl select get_ddl('table',...

Snowflake DECODE Function Syntax and Examples

06/08/2023 11:22
Snowflake cloud data warehouse supports the DECODE function which is similar to other relational databases such as Redhift, Netezza, Oracle, SQL Server, etc. The DECODE function is used to implement simple case statements. i.e. you can use it to implement simple if-then-else...

Greatest

06/08/2023 11:20
It takes the greatest column value: greatest(o._fivetran_synced, nvl(ox._fivetran_synced, '1900-01-01'), nvl(ea._fivetran_synced, '1900-01-01'), nvl(eax._fivetran_synced, '1900-01-01'),nvl(oxm._fivetran_synced, '1900-01-01'))  AS LAST_UPD
Itens: 1 - 10 de 224
1 | 2 | 3 | 4 | 5 >>