TomohitoNakayama wrote:
Hello.

I consider this issue in last weekend and agree your opinion in general.
"in general" means that I think "GENERATED_BY_DEFAULT" is better.

To think manipulating the value in some script, no space in this value would be better.
How do others think ?

The only issue with this is consistency. For a column that's "GENERATED ALWAYS", Derby currently returns NULL for the default text. In order to be consistent, I think we should have the same behavior for the two types of columns: either return NULL for the default text in both cases, or else return some constant string.

But that said, if we change GENERATED ALWAYS columns to return a non-null value (such as "GENERATED_ALWAYS"), then there's the chance that we introduce a regression: any users of the 10.0 release who expect a NULL will now get different behavior. I don't know if that's acceptable...?

The safest (consistent) thing to do is to return NULL for columns that are GENERATED BY DEFAULT, so I think that's what I would vote for (despite my initial email saying otherwise). But that's just me--I hope anyone who feels otherwise will post saying so...

Army

Reply via email to