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

Map everything using oatpp::Any and display results #16

Closed
roqerxz opened this issue Jan 19, 2022 · 3 comments
Closed

Map everything using oatpp::Any and display results #16

roqerxz opened this issue Jan 19, 2022 · 3 comments

Comments

@roqerxz
Copy link

roqerxz commented Jan 19, 2022

The following seems to no longer work:
`auto dataset = queryResult->fetch<oatpp::Vector<oatpp::Fieldsoatpp::Any>>();

/* Serialize result as a json string using json object mapper */
auto json = jsonObjectMapper.writeToString(dataset);

/* Print the resultant json */
std::cout << json->c_str() << std::endl;`

example from the doc:
https://oatpp.io/docs/components/orm/#mapping-results

@lganzzzo
Copy link
Member

Hello @roqerxz ,

Not working in what way? Any errors?

lganzzzo added a commit that referenced this issue Jan 20, 2022
ResultMapper: Fix readOneRowAsMap() method (#16)
@lganzzzo
Copy link
Member

Fixed in #17

@roqerxz
Copy link
Author

roqerxz commented Jan 20, 2022

great thanks for the quick turn around !

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

No branches or pull requests

2 participants