I'm using Pulumi as Automation tool to create table/view in BigQuery . Unfortunately Pulumi supports only JSON schema instead I need to create table/view from DDL.
sample ddl :
create table <table_name> ( col1 datatype , .....) partition by date_col ;
Tried Pulumi jobs to create table but that's also not working
job = gcp.bigquery.Job("job",
job_id="job_query",
labels={
"example-label": "example-value",
},
query=gcp.bigquery.JobQueryArgs(
query="""
CREATE TABLE `pulumi_test.tb_test` (
`id` string(36) ,
`date_col` DATE
)PARTITION BY date_col
OPTIONS(
require_partition_filter=true
)
""",
use_legacy_sql = False,
))