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.

Is it possible to find not NULL column?

See original GitHub issue

I am going to realize something like that: SELECT * FROM country WHERE "housing" is not NULL

Can you help with it?

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:5 (1 by maintainers)

github_iconTop GitHub Comments

3reactions
dashmugcommented, Jun 20, 2020

@twheys notnull() is giving me the wrong query.

table = Table("Houses")
query = Query.from_(table).select("*").where(table.housing.notnull())

outputs the following

SELECT * FROM "Houses" WHERE NOT "housing" IS NULL

pypika v0.37.8

2reactions
twheyscommented, Mar 26, 2019
table = Table( ... )
query = Query.from_(table).select('*').where(table.housing.notnull())
    - or -
query = Query.from_(table).select(Star()).where(table.housing.notnull())
Read more comments on GitHub >

github_iconTop Results From Across the Web

SQL NULL Values - IS NULL and IS NOT NULL - W3Schools
The IS NOT NULL operator is used to test for non-empty values (NOT NULL values). The following SQL lists all customers with a...
Read more >
SQL WHERE IS NULL | IS NOT NULL - Dofactory
A WHERE IS NULL clause returns records with columns that have NULL values. ... Testing for NULL with the = operator is not...
Read more >
MySQL SELECT only not null values - Stack Overflow
I would like to only get the values from the columns that are not null, and return only the column values in the...
Read more >
SQL: IS NOT NULL Condition - TechOnTheNet
The IS NOT NULL condition is used in SQL to test for a non-NULL value. It returns TRUE if a non-NULL value is...
Read more >
How to SELECT Records With No NULL Values in MySQL
By far the simplest and most straightforward method for ensuring a particular column's result set doesn't contain NULL values is to use the...
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