{"action":"created","issue":{"url":"https://api.github.com/repos/Starcounter/Starcounter/issues/3447","repository_url":"https://api.github.com/repos/Starcounter/Starcounter","labels_url":"https://api.github.com/repos/Starcounter/Starcounter/issues/3447/labels{/name}","comments_url":"https://api.github.com/repos/Starcounter/Starcounter/issues/3447/comments","events_url":"https://api.github.com/repos/Starcounter/Starcounter/issues/3447/events","html_url":"https://github.com/Starcounter/Starcounter/issues/3447","id":141295987,"number":3447,"title":"In SQL queries, Count not working as expected","user":{"login":"atifsheikh","id":4388707,"avatar_url":"https://avatars.githubusercontent.com/u/4388707?v=3","gravatar_id":"","url":"https://api.github.com/users/atifsheikh","html_url":"https://github.com/atifsheikh","followers_url":"https://api.github.com/users/atifsheikh/followers","following_url":"https://api.github.com/users/atifsheikh/following{/other_user}","gists_url":"https://api.github.com/users/atifsheikh/gists{/gist_id}","starred_url":"https://api.github.com/users/atifsheikh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/atifsheikh/subscriptions","organizations_url":"https://api.github.com/users/atifsheikh/orgs","repos_url":"https://api.github.com/users/atifsheikh/repos","events_url":"https://api.github.com/users/atifsheikh/events{/privacy}","received_events_url":"https://api.github.com/users/atifsheikh/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/Starcounter/Starcounter/labels/bug","name":"bug","color":"e11d21"},{"url":"https://api.github.com/repos/Starcounter/Starcounter/labels/Old%20SQL","name":"Old SQL","color":"000000"},{"url":"https://api.github.com/repos/Starcounter/Starcounter/labels/P/High","name":"P/High","color":"eb6420"}],"state":"open","locked":false,"assignee":{"login":"k-rus","id":1726044,"avatar_url":"https://avatars.githubusercontent.com/u/1726044?v=3","gravatar_id":"","url":"https://api.github.com/users/k-rus","html_url":"https://github.com/k-rus","followers_url":"https://api.github.com/users/k-rus/followers","following_url":"https://api.github.com/users/k-rus/following{/other_user}","gists_url":"https://api.github.com/users/k-rus/gists{/gist_id}","starred_url":"https://api.github.com/users/k-rus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/k-rus/subscriptions","organizations_url":"https://api.github.com/users/k-rus/orgs","repos_url":"https://api.github.com/users/k-rus/repos","events_url":"https://api.github.com/users/k-rus/events{/privacy}","received_events_url":"https://api.github.com/users/k-rus/received_events","type":"User","site_admin":false},"milestone":{"url":"https://api.github.com/repos/Starcounter/Starcounter/milestones/51","html_url":"https://github.com/Starcounter/Starcounter/milestones/v2.x","labels_url":"https://api.github.com/repos/Starcounter/Starcounter/milestones/51/labels","id":602455,"number":51,"title":"v2.x","description":"","creator":{"login":"Starcounter-Jack","id":1219049,"avatar_url":"https://avatars.githubusercontent.com/u/1219049?v=3","gravatar_id":"","url":"https://api.github.com/users/Starcounter-Jack","html_url":"https://github.com/Starcounter-Jack","followers_url":"https://api.github.com/users/Starcounter-Jack/followers","following_url":"https://api.github.com/users/Starcounter-Jack/following{/other_user}","gists_url":"https://api.github.com/users/Starcounter-Jack/gists{/gist_id}","starred_url":"https://api.github.com/users/Starcounter-Jack/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Starcounter-Jack/subscriptions","organizations_url":"https://api.github.com/users/Starcounter-Jack/orgs","repos_url":"https://api.github.com/users/Starcounter-Jack/repos","events_url":"https://api.github.com/users/Starcounter-Jack/events{/privacy}","received_events_url":"https://api.github.com/users/Starcounter-Jack/received_events","type":"User","site_admin":false},"open_issues":346,"closed_issues":508,"state":"open","created_at":"2014-03-19T09:04:00Z","updated_at":"2016-03-31T09:35:33Z","due_on":null,"closed_at":null},"comments":16,"created_at":"2016-03-16T14:44:56Z","updated_at":"2016-04-01T12:37:37Z","closed_at":null,"body":"I have 10 results of the following Query : \r\n`SELECT s FROM adfenix.database.ecommerce.seller s WHERE Advertiser.PublicationOwner.Name = 'krogsveen'`\r\n\r\nbut '0' result if i use COUNT(s) in the same query : \r\n`SELECT count(s) FROM adfenix.database.ecommerce.seller s WHERE Advertiser.PublicationOwner.Name = 'krogsveen'`\r\n\r\nMy SC Version is 2.1.1409."},"comment":{"url":"https://api.github.com/repos/Starcounter/Starcounter/issues/comments/204381907","html_url":"https://github.com/Starcounter/Starcounter/issues/3447#issuecomment-204381907","issue_url":"https://api.github.com/repos/Starcounter/Starcounter/issues/3447","id":204381907,"user":{"login":"k-rus","id":1726044,"avatar_url":"https://avatars.githubusercontent.com/u/1726044?v=3","gravatar_id":"","url":"https://api.github.com/users/k-rus","html_url":"https://github.com/k-rus","followers_url":"https://api.github.com/users/k-rus/followers","following_url":"https://api.github.com/users/k-rus/following{/other_user}","gists_url":"https://api.github.com/users/k-rus/gists{/gist_id}","starred_url":"https://api.github.com/users/k-rus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/k-rus/subscriptions","organizations_url":"https://api.github.com/users/k-rus/orgs","repos_url":"https://api.github.com/users/k-rus/repos","events_url":"https://api.github.com/users/k-rus/events{/privacy}","received_events_url":"https://api.github.com/users/k-rus/received_events","type":"User","site_admin":false},"created_at":"2016-04-01T12:37:37Z","updated_at":"2016-04-01T12:37:37Z","body":"Thank you for clarifying! Sorry, that I was not so careful. I see the same difference in query plans that the failed one is using IS predicate in the plan, which is decided by query optimiser. As soon I have time, I will investigate them."}}