Redshift - json functions don't exist

0

Starting sometime last night, all of my queries that use json_extract_path_text stopped working. They had been working fine for months. Now when I try a query like this:

select json_extract_path_text(json_data, 'Legal Last Name:') legal_last_name from psd_warehouse.raw_data.raw_sheets_comp_staff_dir_aes

I get the following error:

ERROR: function json_extract_path_text(super, "unknown") does not exist Hint: No function matches the given name and argument types. You may need to add explicit type casts.

Anyone have any idea why the functionality would have changed?

Thanks!

질문됨 2년 전1229회 조회
1개 답변
0

Hello,

Thank You for your question.

I have reached out to the Redshift service team and they have not indicated any recent change to this functions; parameters or functionality.

The function is expecting a 'json_string' and a super column is provided, you may use the json_serialize function to prepare your super column data for use with any of the json function expecting a 'json_string' as an input parameter. https://docs.aws.amazon.com/redshift/latest/dg/JSON_SERIALIZE.html

for example: json_extract_path_text(json_serialize(super_column), 'path_elem' )

If you have any further questions I would invite you to open a support case to further investigate and escalate if required.

Thank You and have a great day.

AWS
답변함 2년 전

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠