-
-
Notifications
You must be signed in to change notification settings - Fork 110
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
Wrong selection when dealing with null values #40
Comments
By the way, the last error is because the latest build lacks the default export for the |
So you are saying that you are getting result with job_suspendedflag:1 right ? |
Yes, I logged the found records and I see that some have the flag set to 1 (number) |
Ok, I will try to fix this one. Fyi - I am also working on a project called idbstudio which will help users to debug query and doing lots of things just like others db studio like - sql management studio etc. Also you dont need to log in to see your data, it will print your result in a table like ui. I just need a little time. Any way i will try to fix these asap. Thanks. |
Let me know others issue if you found please and any others improvement if you like to include in v2. Thanks |
I see that v2 has code that is A LOT better. Good job, this is something I can handle somehow. |
Installed v2, the problem is here. Here is the query and result set:
Please ignore the Oddly enough, removing the first part of the query makes a difference, the result set includes one more record. |
I can confirm the issue exists in version 2.0.3 |
@Mc128k - Can you reproduce this for our demo database in idbstudio.? Because all of the test cases I have is for that db only. You can insert some values or create some table or create another db - just let me know what should I do to reproduce? Thanks |
Reproduced successfully. See the attached files for the demo database and the query for the test:
The result set includes both orders with flag 0 and 1. |
Ok great. I will fix it within this week. Thanks |
@Mc128k - issue is resolved in version 2.0.5.Let me know if you are getting this any more. Thanks. |
Here is the link for testing in idbstudio - https://ujjwalguptaofficial.github.io/idbstudio/?query=select(%7B%0A%20%20%20%20from:%27Employees%27,%0A%20%20%20%20where:%20%7B%0A%20%20%20%20%20%20jobSuspendedFlag:%20%7B%27!=%27:%200%7D,%0A%20%20%20%20%20%20state:%20%7B%0A%20%20%20%20%20%20%20%20in:%20%5B%27Working%27,%20%27Diagnostics%27,%20%27FinalTest%27%5D,%0A%20%20%20%20%20%20%7D,%0A%20%20%20%20%7D%0A%7D)&db=Demo When it says column - jobSuspendedLog doesn't exist which means that you have old db created. Please drop the database by calling - dropDb() in another tab and reload the page. It should work. Thanks |
Indeed it seems to be working! Thanks a lot!! |
Hi again
During development, I found that this query produces a wrong selection:
The records have the
jobSuspended_flag
set to 1, but they are selected anyway. There can be two values for this field, 1 or null.If I change the row to this:
It throws an error:
I'm currently trying to understand JSStore's code in order to debug these problems myself (and maybe posting pull requests), but the way it's structured makes it hard for me. Also there are some type bugs, for example declaring the Promise as any in CodeExecutionHelper.ts makes the compiler angry:
but the issue here is with the selection. I'm trying to figure out these by myself, just wanted to let you know.
The text was updated successfully, but these errors were encountered: