本文属于机器翻译版本。若本译文内容与英语原文存在差异,则一律以英文原文为准。
第 5 步:在 Amazon Athena 中运行查询以验证权限
对于此步骤,请使用 Amazon Athena 运行SELECT对两个表的查询(source_data and source_data_col_lvl). 使用 Amazon S3 路径作为查询结果位置(s3://lf-tagbased-demo-.Account-ID/athena-results/)
-
通过以下网址登录 Athena 控制台https://console.aws.amazon.com/athena/
如同 lf-data-analyst. 在 Athena 查询编辑器中,选择
tag_database在左侧面板中。选择旁边的附加菜单选项图标(三个垂直点)
source_data然后选择Previet.选择 Run query (运行查询)。
此查询应需要几分钟才能运行。查询会显示输出中的所有列,因为 LF-tag 在数据库级别关联,而
source_data表自动继承了LF-tag来自数据库tag_database.使用运行另一个查询
col_tag_database和source_data_col_lvl.第二个查询返回被标记为的两列
Non-Confidential和Sensitive.您还可以查看在没有策略授权的列上查看基于 Lake Formation 标记的访问策略行为。从表中选择未加标签的列时
source_data_col_lvlAthena 会返回错误。例如,您可以运行以下查询来选择未标记的列geolocationid:SELECT geolocationid FROM "col_tag_database"."source_data_col_lvl" limit 10;