繁体   English   中英

如何使用 apache airflow schedule google cloud bigquery 存储过程

[英]how to use apache airflow schedule google cloud bigquery stored procedure

我想在 apache airflow 中安排一个谷歌云 bigquery 存储过程。我没有在 airflow 中看到任何文档。我应该使用哪个调度程序在 apache airflow 上安排一个 bigquery 存储过程。你能给我举个例子吗? 太感谢了。

https://airflow.apache.org/docs/apache-airflow-providers-google/stable/operators/cloud/bigquery.html#execute-bigquery-jobs

BigQueryInsertJobOperator应该是在 DAG 中使用的运算符,用于在 BigQuery 中执行 SQL——这是调用存储过程时要执行的操作。

例如:

call_stored_procedure = BigQueryInsertJobOperator(
    task_id="call_stored_procedure",
    configuration={
        "query": {
            "query": "CALL `project_id.dataset.stored_procedure_name`(arg1, arg2); ",
            "useLegacySql": False,
        }
    },
    location=location,
)

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM