Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Date type support when using Aurora PostgreSQL #109

Merged
merged 2 commits into from
Apr 6, 2022

Conversation

mikkom
Copy link
Contributor

@mikkom mikkom commented Nov 20, 2021

This change fixes the deserializeDate format option functionality when using Aurora PostgreSQL. From there the type names arrive in lowercase and you also have the timestamptz abbreviation for timestamp with time zone.

@jeremydaly jeremydaly merged commit 89b1e7f into jeremydaly:main Apr 6, 2022
@calvin-cdev
Copy link

@jeremydaly i was just looking at this and you merged it while i was reading 😆 thanks for this package!!

@calvin-cdev
Copy link

calvin-cdev commented Apr 6, 2022

@jeremydaly it looks like when you merged main into this before merging the pr, you dropped the typeName.toUpperCase() change. I can confirm that with the postgres data-api, the cast to upper case is necessary for the formatRecordValue function to have any effect. I put a log line in the function, console.log(typeName), and all the logs are showing typeName as lowercase.

@jeremydaly
Copy link
Owner

Thanks @calvin-summer. I'm getting ready to publish two new versions, one with a few fixes to v1.x and then v2.0 with the AWS SDK v3 support. I'll look at this as well.

@calvin-cdev
Copy link

calvin-cdev commented Apr 6, 2022

@jeremydaly I just brought this up in an issue with the orm driver package that I use (which uses your data-api-client). I wasn't sure if this should be fixed here or in consumers, although I suspect it should be fixed here, since one would expect the pg engine option to be fully compatible. I'd be happy to open a PR later with the change.

@jeremydaly
Copy link
Owner

That'd be great. Please PR against the aws-sdk-v3-migration branch as v1 will be deprecated soon.

@calvin-cdev
Copy link

@jeremydaly opened a pr #117

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants