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

Row as Dictionary<string, object> via GetDictionaryAsync #418

Closed
pavelvondrasek opened this issue Oct 7, 2020 · 4 comments
Closed

Row as Dictionary<string, object> via GetDictionaryAsync #418

pavelvondrasek opened this issue Oct 7, 2020 · 4 comments
Labels
bug fixed_nightly Deployed in nightly build verified_next_release Verified and will be solved in the next minor release

Comments

@pavelvondrasek
Copy link

Hi,

I'm beginner with SqlKata. I'm very happy that found tool which allows me to create low-level SQL queries but my project needs dynamic results too. Now I've problem with GetDictionaryAsync:

var query = _db
   .Query("cms.contents")
   .SelectRaw("values->'name' as name")
   .Where("type", "product");

var dictionary = await _db.GetDictionaryAsync(query);

Now dictionary is null :(
But if I use sync overload GetDictionary all works fine. I think that something is wrong with async overload.

@ahmad-moussawi
Copy link
Contributor

@pavelvondrasek , Could you share your environment details (os, .net runtime, and SqlKata version used)?

@pavelvondrasek
Copy link
Author

Yes, of course.

I'm on macos Catalina on Postgres 12 which is on remote server with Debian.
Using .NET Core SDK 3.1.402, SqlKata 2.2 and Npgsql 4.1.5

@ahmad-moussawi ahmad-moussawi added bug fixed_nightly Deployed in nightly build verified_next_release Verified and will be solved in the next minor release labels Oct 7, 2020
@ahmad-moussawi
Copy link
Contributor

I've identified the issue and fixed in the nightly build, you can get it from https://www.myget.org/feed/sqlkata/package/nuget/SqlKata

Related PR: #419

@pavelvondrasek
Copy link
Author

Thank you for your kindliness and great support! 💯 ❤️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug fixed_nightly Deployed in nightly build verified_next_release Verified and will be solved in the next minor release
Projects
None yet
Development

No branches or pull requests

2 participants