question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

select(p for p in P if (v1 < p.field < v2)) does not work

See original GitHub issue

it raises: NotImplementedError: Expression is too complex to decompile, try to pass query as string, e.g. select(“x for x in Something”)

First, I thought that Pony will emit BETWEEN operator. But instead, exception raised.

As I think, Pony should use two (or more) comparison operator instead of BETWEEN, because:

http://www.w3schools.com/sql/sql_between.asp :

Notice that the BETWEEN operator can produce different result in different databases!
In some databases, BETWEEN selects fields that are between and excluding the test values.
In other databases, BETWEEN selects fields that are between and including the test values.
And in other databases, BETWEEN selects fields between the test values, including the first test value and excluding the last test value.

Therefore: Check how your database treats the BETWEEN operator!

Issue Analytics

  • State:open
  • Created 9 years ago
  • Comments:6 (1 by maintainers)

github_iconTop GitHub Comments

0reactions
Queuecumbercommented, Oct 29, 2020

OK between is a thing but why not support the chained syntax (6 years later)

Read more comments on GitHub >

github_iconTop Results From Across the Web

Math 54. Selected Solutions for Week 5 Section 4.2 (Page 194 ...
Find the coordinate vector of p(t)=1+4t + 7t2 relative to B . As in Practice Problem #2 (on page 210; solution on page...
Read more >
Math 2331 – Linear Algebra - 5.3 Diagonalization
An n × n matrix A is diagonalizable if and only if A has n linearly independent eigenvectors. In fact, A = PDP-1,...
Read more >
Linear Span and Bases - UC Davis Mathematics
Pm(F) = set of all polynomials in P(F) of degree at most m. Then Pm(F) ⊂ P(F) is a subspace since it contains...
Read more >
LINEST function - Microsoft Support
The LINEST function calculates the statistics for a line by using the "least squares" method to calculate a straight line that best fits...
Read more >
9 Hypothesis Tests
Comparison of test statistic to critical region to draw initial conclusions. 4. Calculation of p-value. 5. Conclusion, written in terms of the original...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found