def _raw_table_name()

in sync/metrichub.py [0:0]


def _raw_table_name(table: sqlglot.exp.Table) -> str:
    """
    Adapted from bigquery-etl:
    https://github.com/mozilla/bigquery-etl/blob/12c27464b1d5c41f15a6d3d9e2463547164e3518/bigquery_etl/dependency.py#L21
    """
    return (
        table.sql("bigquery", comments=False)
        .split(" AS ", 1)[0]  # remove alias
        .replace("`", "")  # remove quotes
    )