feat(sql): surface IS_NULLABLE on browsed column attributes (R06:S-5)
Every dialect projects IS_NULLABLE and nothing read it. The browse session now reads it (tolerantly: a dialect that does not project it reads as unknown) and the picker's descriptor line says 'nullable' / 'NOT NULL', so an operator knows a cell can come back NULL (Uncertain, or Bad under nullIsBad) before committing the tag. The runtime catalog loader keeps reading names only - nothing at runtime consumes nullability. Refs #744 Claude-Session: https://claude.ai/code/session_01Ub9hGmYLQvn9XETzw7CMsT
This commit is contained in:
@@ -78,7 +78,8 @@ public sealed class SqlBrowseSessionTests
|
||||
attribute.Name.ShouldBe(SqliteBrowseFixture.RealColumn);
|
||||
attribute.DriverDataType.ShouldBe(nameof(DriverDataType.Float64));
|
||||
attribute.IsArray.ShouldBeFalse();
|
||||
attribute.SecurityClass.ShouldBe("ViewOnly");
|
||||
// R06:S-5: every dialect projects IS_NULLABLE and the picker now says so. The column is declared NULL.
|
||||
attribute.SecurityClass.ShouldBe("ViewOnly · nullable");
|
||||
attribute.IsAlarm.ShouldBeFalse();
|
||||
}
|
||||
|
||||
@@ -92,7 +93,10 @@ public sealed class SqlBrowseSessionTests
|
||||
SqliteDialect.MainSchema, SqliteBrowseFixture.KeyValueTable, SqliteBrowseFixture.TextColumn);
|
||||
var attributes = await session.AttributesAsync(nodeId, CancellationToken.None);
|
||||
|
||||
attributes.ShouldHaveSingleItem().DriverDataType.ShouldBe(nameof(DriverDataType.String));
|
||||
var attribute = attributes.ShouldHaveSingleItem();
|
||||
attribute.DriverDataType.ShouldBe(nameof(DriverDataType.String));
|
||||
// The NOT NULL control for the nullable case above — the descriptor tracks the catalog, not a constant.
|
||||
attribute.SecurityClass.ShouldBe("ViewOnly · NOT NULL");
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
||||
Reference in New Issue
Block a user