admin管理员组文章数量:1300133
I am trying to create a glue job that accepts dynamic parameters and uses the parameters to query Redshift. I cannot for the life of me figure out how I am supposed to do this. I have researched and googled so many things but I cannot find a straight forward solution. I am trying not to over-complicate things.
I have looked at getting the parameters from an S3 file or from a Crawler. I've tried putting the parameters inside the SQL statement but that always errors out.
i.e.
args = getResolvedOptions(sys.argv, ['JOB_NAME','identifier'])
glueContext.create_dynamic_frame.from_options(connection_type="redshift", connection_options={"sampleQuery":"select distinct sec_id from schema.table where identifier = 'args['identifier]'",...
I am working in the Glue Visual Studio but if I need to do this via the Script itself I can.
I'm just lost and could really use some help or guidance.
本文标签: amazon s3How to use Glue Parameters in a Redshift SQL scriptStack Overflow
版权声明:本文标题:amazon s3 - How to use Glue Parameters in a Redshift SQL script? - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1741650286a2390433.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论