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

Pgsql doesn't seem to compile with ToT anymore #114

Open
oxcug opened this issue Jun 9, 2022 · 2 comments
Open

Pgsql doesn't seem to compile with ToT anymore #114

oxcug opened this issue Jun 9, 2022 · 2 comments

Comments

@oxcug
Copy link

oxcug commented Jun 9, 2022

Hey @matt-42 ! I just pulled from ToT and looks like there are some pgsql specific compiler errors when I import #include <lithium_pgsql.hh>. Any chance we could get a fix for this?

Screen Shot 2022-06-09 at 08 11 06

@matt-42
Copy link
Owner

matt-42 commented Jun 10, 2022

Hi @oxcug
Could you post the line that is triggering this error ? Seems like you are passing a type to lithium pgsql that is not supported but I'm not sure about it.

@oxcug
Copy link
Author

oxcug commented Jun 30, 2022

Sorry about the delay, the error came from a lack of support for uint64_t from the read_optional template function in the sql headers. e.g:

    auto stmt = conn.prepare("SELECT some, foo FROM things WHERE foo=?");
    const auto an_optional = stmt(thing).read_optional<uint64_t /* <- looks like this is unsupported */, std::string>();
    if (an_optional.has_value()) {

Looks like it's just a "you're holding it wrong" kind of problem but would be nice to have more type support. Changing the type to int fixed my issue.

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