如何重命名表而不重新创建它 [英] how to rename a table without re creating it

查看:26
本文介绍了如何重命名表而不重新创建它的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我没有找到更改表名的 RENAME 选项.我有一个必须重命名表的情况,唯一的方法是选择结果到新表.这个查询需要花钱,而且无缘无故地花费了很长时间.

I didn't find a RENAME option to alter table name. I have a case that I must rename a table, and the only way is to select with result to new table. this query cost money, and taking long time for no reason.

当我需要重命名嵌套表时尤其痛苦,所以我必须导出,甚至需要处理结果集才能将其导入回来.

It is especially painful when I need to rename a nested table, so I must export, need to even work on the result set in order to import it back.

我想念的任何方式?有什么即将推出吗?

Any way that I am missing? anything coming soon?

推荐答案

没有重命名选项,但有一个复制操作,它使用快速快照过程.除了额外的存储成本外,这不会产生任何额外费用(当然,您可以删除原始表,这样您只需支付一次存储费用).

There is no rename option, but there is a copy operation, which uses a fast snapshot process. This doesn't incur any additional charges other than the additional cost of storage (of course you can delete the original table so you only get charged for the storage once).

您可以在 BigQuery 中执行此操作,方法是点击表名和表名旁边的下拉箭头,然后选择复制表".或者,您可以使用 bq 命令行工具中的 bq cp 命令.

You can do this in the BigQuery by clicking on the table name and the dropdown arrow next to the table name, then selecting 'copy table'. Alternately you can use the bq cp command in the bq command-line tool.

这篇关于如何重命名表而不重新创建它的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆