livequery-models/models/_internal__contracts_map.sql
Austin 040b3fdf9a
Stream 318/an 3432/stream 324/evm highl level abstractions (#24)
* - create place holder configs for high level evm abstractions

* - rename udf_config

* - fixed macro bug

* - add generic rpc_call

* - add generic evm rpc udf

* - add generic evm rpc udf

* - more DRY primitives

* WIP

* - add example udft

* - readme.MD

* - updated comments on evm primitives

* - add model to store signatures for UI

* evm abstractions

* use schema

* Squashed commit of the following:

commit df57d3309394d13407d5f4f7a1c27ab4e51ccb4e
Author: Julius Remigio <14811322+juls858@users.noreply.github.com>
Date:   Thu Jun 15 12:31:00 2023 -0700

     - remove unneeded model

* - refactor pimitives to use schema with network name

* schema fix and polygon

* - added udf_rpc to live schema
- prefixed primitives with udf_

* use crosschain table

* use sources for crosschain

* support all chains

* add network

* updated comments

* all chains

* remove map

* reorg

* remove optimism from map

* Update utils.sql

Return null instead of empty json object

* add error column

* Revert "add error column"

This reverts commit 49bc7239a4.

* Revert "Update utils.sql"

This reverts commit 1edbeef5ee.

* Update utils.sql

Return null instead of empty json object

* Revert "Update utils.sql"

This reverts commit e4c29b0932.

---------

Co-authored-by: Julius Remigio <14811322+juls858@users.noreply.github.com>
2023-06-27 11:55:30 -07:00

20 lines
326 B
SQL

{{ config(
materialized = 'view'
) }}
SELECT
address,
symbol,
decimals,
CASE
blockchain
WHEN 'avalanche' THEN 'avalanche_c'
WHEN 'arbitrum' THEN 'arbitrum_one'
ELSE blockchain
END AS blockchain
FROM
{{ source(
'crosschain',
'dim_contracts'
) }}