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 to support JSON/JSONB/JSONPATH datatypes #43

Merged
merged 3 commits into from
Mar 4, 2021

Conversation

shabbir10july
Copy link
Contributor

JIRA: #42

Problem: Two new datatypes are introduced in NPS: JSON and JSONB. The support of these two datatypes on the server-side requires some changes on the client-side so it can retrieve JSON/JSONB data from the server.

Solution:

  1. Enabling nzpy client to send its client version string 'Release 11.1.0.0' to the server at the beginning of each session, which tells the server that nzpy client is capable of handling JSON/ JSONB data. Notice: the client version string must start with a string, such as 'Release', in order for the server to properly parse it.
  2. Mapping JSON/JSONB data to string type in nzpy, which can be handled in a similar fashion as NVARCHAR data in nzpy.

Testing: Ran an application which fetches JSON and JSONB datatypes. Results attached in JIRA.
Ran test suite 'pytest -vv tests/test_typeconversion.py'

@abhishekjog abhishekjog merged commit 1a148fe into master Mar 4, 2021
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.

None yet

2 participants