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 on BOOL value returns internal INT representation

See original GitHub issue

SELECT TRUE a, FALSE b, 1 c, 0 d FROM DUMMY

returns

[{"A":1,"B":0,"C":1,"D":0}]

Is this intentional? I understand that HANA uses integers for the internal representation of boolean values, but I would expect a node db client to return a javascript type boolean here.

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Reactions:3
  • Comments:8 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
wovertoncommented, Nov 2, 2016

My vote would be for javascript booleans. But this could break existing applications so a change here should be made with caution.

0reactions
gpasserocommented, Dec 11, 2018

@alexpenev-s Thanks for your help. Unfortunately, I’ll have to keep handling bools as ints since that feature is not ensured by documentation.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to use BOOLEAN type in SELECT statement
You can definitely get Boolean value from a SELECT query, you just can't use a Boolean data-type. You can represent a Boolean with...
Read more >
Boolean Struct (System) - Microsoft Learn
Represents a Boolean (true or false) value.
Read more >
MySQL Boolean - Javatpoint
MySQL Boolean. A Boolean is the simplest data type that always returns two possible values, either true or false. It can always use...
Read more >
BIGINT - IBM
The BIGINT function returns a big integer (a binary integer with a precision of 63 bits) representation of a value of a different...
Read more >
Python Booleans: Optimize Your Code With Truth Values
In this tutorial, you'll learn about the built-in Python Boolean data type, which is used to represent the truth value of an expression....
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