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

Add example to extra data from a JSON response field #59

Open
e-gineer opened this issue Mar 24, 2023 · 0 comments
Open

Add example to extra data from a JSON response field #59

e-gineer opened this issue Mar 24, 2023 · 0 comments
Labels
documentation Improvements or additions to documentation enhancement New feature or request good first issue Good for newcomers

Comments

@e-gineer
Copy link
Contributor

From this thread, an example like this would be good on the net_http_request table:

The trick is to cast the response into JSONB . For example:

> select response_body::jsonb ->> 'number' as num_people_in_space from net_http_request where url = 'http://api.open-notify.org/astros.json'

+---------------------+
| num_people_in_space |
+---------------------+
| 10                  |
+---------------------+
@e-gineer e-gineer added documentation Improvements or additions to documentation enhancement New feature or request good first issue Good for newcomers labels Mar 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

1 participant