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
Feature Request: Enforce query size limit #51
Comments
Hi Brandon, The frame is limited by the protocol in 256MB. Is it possible that you are |
I believe this is a malformed query on my side. In the end the fix was to break the WHERE IN clause into multiple select's. I wish I had more time to chase this down, but the IN clause was around 1000 arguments. I was thinking, it would be beneficial to my current and future work if I can pass a tailored object to bind params on select. Similar to :execute("INSERT INTO ...(some_set) VALUES(?)", { cassandra.set){}). |
Sorry, I am not sure I understood your suggestion correctly. Do you mean named arguments like #28? Could you please elaborate? Anyway, I will close this issue for now. Please feel free to open it again if you are able to reproduce the issue. |
I want to use bind params on a large WHERE IN SET. As opposed to writing 'WHERE IN(?, ?, ?, ?, ?........) I'd like to write something like |
You can already do this @lordnynex. A So you can have c:execute("SELECT id FROM table WHERE id IN ?", { cassandra.list({"foo", "bar"})) |
Oh awesome. I'll give it a shot. I was under the impression that cassandra.list was the equivalent of { '', '' } which seemed in-congruent with the where in syntax. |
If not, give a try to one of the other types. I am 100% sure this is possible because I did it in the past, don't remember which type/syntax combination tho. |
@lordnynex, @thibaultcha is right, you can use |
It seems cassandra has some sort of max query size?
I'm performing a very large WHERE IN () and it appears the query is being truncated consistently which throws a syntax error.
Cassandra returned error (Syntax_error): "line 1:6116 no viable alternative at input ')' (...
I'm not sure what this limit is but it would be nice if the driver knew about it.
The text was updated successfully, but these errors were encountered: