Follow Slashdot blog updates by subscribing to our blog RSS feed


Forgot your password?
Check out the new SourceForge HTML5 internet speed test! No Flash necessary and runs on all devices. ×

Comment Re:Do away with them (Score 1) 87

In an RDBMS context, NULL and blank are two very different unrelated concepts. If you don't know the difference you'll make yourself look stupid.

NULL in an RDBMS context and a "null pointer" in C have nothing to do with each other beyond the word "null". As you get into different languages these terms may be used in various ways that are unrelated, fully related, or only tangentially related to an RDBMS context or whatever.

Comment Re:Slime-balls (Score 0) 300

Excellent point and well made. People who are coming out saying the drone operators are perfectly fine obviously haven't though more than six inches in front of their face. Short-sighted idiots, they can't envision a situation because they refuse to think about it from the "how could a bad guy misuse this" perspective.

Comment Re: Rule of thumb (Score 2) 300

It is just kids having fun.

I wonder how you'd feel if someone parked a drone over your back yard with a camera watching your comings and goings, what time you went to bed and woke up, what kind of property you leave out, who visits your house and when, how many kids you have and what ages they are, and so forth. That's just the tip of the iceberg. Someone WILL eventually do that, most likely a LOT of someones, because there are some fucked up people in this world. A law that says it's perfectly alright for someone to fly a drone in close proximity to your home would enable this exact behavior.

And please don't go with the "so what, I have nothing to hide" defense. Even if you didn't mind a private citizen doing it, I'm willing to bet you'd be out of your mind upset if the government did it. If it's not good for one to be doing it, it's not good for either to be doing it.

Comment Re:Do away with them (Score 1) 87

I say get rid of nulls. They cause all kinds of problems and bloat up code. The few times you do "need" them can be handled other ways.

For example, check to make sure the data structure has values (elements) before running an "average" operation on it. If you don't check and there are no elements in it, then it should throw an error rather than produce a null.

Perhaps nulls are used in RDBMS because it's not easy to use conditionals or error handlers in queries to deal with an empty structure or no rows. Maybe have the Average function return two values (columns): one with the result value, and another column with a the count of elements averaged. If the count is zero, then the result value is invalid (not informative), but would be set to zero for consistency.

A potential problem with getting rid of nulls is that languages may have to support them for backward compatibility with existing stuff that produces nulls.

The more you type, the bigger the hole.

In RDBMS terms, "NULL" means "we don't know the value". It's not "empty", 0, false, or anything like that. It is "unknown".

Take this dataset:


The average of those is 2 ( (0 + 2 + 4) / 3 ). The count is 3. The sum is 6. The max is 4 and the min is 0. The RDBMS doesn't count null values for those operations because nulls are not known.

Likewise, NULL != NULL and NULL = NULL both give no value because it's unknown.

NULL is not "empty". It is not "undefined". It is not "blank". This is the source of your confusion. NULLs are absolutely necessary in an RDBMS context - at least for people who know what they're doing.

In terms of C programming, "null" usually means a pointer that has a literal value of 0. Unix-based operating systems always set the first page of mapped memory to be inaccessible as an easy way to catch references to 0 pointers. That makes a null pointer an easy way to say "there's no value here yet". But it's really not the same as a NULL value in an RDBMS context.

Comment Re:Does anyone care what Trump thinks? (Score 1) 526

The last I'd heard, news fact-checking organizations were reporting that he told the truth 15% of the time. Why would I ever care what the opinion of someone like was?

And I've found the "fact-checking organizations" tell the truth about 10% of the time. These are the people who claim Hillary told the truth about her email server.

The people of the United States are still smarter than that.

So are you, Bruce.

Slashdot Top Deals

I've never been canoeing before, but I imagine there must be just a few simple heuristics you have to remember... Yes, don't fall out, and don't hit rocks.