I experienced very strange problem today with TSQL function.
The function has several parameters (int and bit). One of the (int) is set with value NULL.
When calling a function with NULL inside the ...

MySQL 5.6.23, InnoDB
I am loading tables from character delimited text files using the LOAD DATA INFILE commnd and I would like every field with a \N, which is the NULL character in this setting, to ...

I have a database of few million records, many of the fields (call them Ec1 to EcN) have either Null or empty string in them. When I looked at them more closely, I found that for many records, several ...

My query can be simplified as this:
SELECT a.id, a.name, b.* FROM a LEFT JOIN b ON a.id=b.id
Which b is from group concat select (very dynamic column). Sometimes there are 3 columns in b, sometimes ...

I have an all-InnoDB database in MySQL (Percona) 5.6 that was previously using FK constraints. I had to give up on them as I kept running into locking issues, so I removed the constraints and added ...

If it is possible to make query in Oracle which will return single column/row with value "none" instead of empty, multi-column result?
Otherwise return proper amount of columns with result.
This is ...

Say I have a table entities (subclassed by people and organizations tables), where each entry requires a primary_email_id. The entities table looks like this:
entities
========
id INT AUTO_INCREMENT
...

So I basically have a table with lots of inserts, setting one of the fields (uploaded_at) to NULL. Then a periodic task selects all the tuples WHERE uploaded_at IS NULL, processes them and updates, ...

I have a database in which some tables have to be joined to fetch the data. The problem is that in one table the column is nullable (nullable is set to yes or no constraint given for that column) and ...

So basically in SQLServer a NULL means there is no value and thus can't be compared which returns some unexpected results.
For example, the following query doesn't return rows where value IS NULL but ...

I'm looking for a way to insert records into a 'black hole'; i.e. execute a query for a certain table successfully, but make the records disappear. Something like INSERT INTO NULL, if you will. MySQL ...

I am using PostgreSQL and trying to write value constraints.
Is it possible to record missing data as distinct from NULL values in a numeric field without using an arbitrary numeric value?
For many ...

I am doing a exercise to change a column's constraint between null to not null.
Table name: Production.categoriesTest. Please review my question and give me suggestion
on what I did wrong and how to ...

I'm trying to learn about proper database management and am having a hard time with designing a database that doesn't rely on NULLs. If you think I'm crazy for embarking on this, it is because of SQL ...

I have a query such as:
select something
from somewhere
join stuff on condition
join more_stuff on condition
where somewhere.sometime is null
and somewhere.someone is null
and stuff.whatever is null
...

EDIT: I've come up with one poor solution (below) that requires some denormalization, but does avoid the risks of UDFs in CHECK constraints. I would appreciate your help if you have a better answer.
...

I am attempting to update a column if another value from a subquery is less than a certain value or null:
UPDATE Customer
SET PriceClassID = 'A'
FROM (SELECT custid, SUM(curybaldue) as last_sum
FROM ...