
On 01/12/2012 03:34 PM, Thorsten Ottosen wrote:
Den 12-01-2012 12:10, Roland Bock skrev:
You may be very well be right. Currently we generate lots of additional code, to allow for stuff like this:
Users users; users.insert( users.age(42), users.firstName("Roland"), users.lastName("Bock"));
The insert method knows the required columns (you can specify the non-required columns, too, of course).
So you get a compile error if a column is required, but not specified?
-Thorsten
Right. That's the whole idea of what we created: Let the compiler check as much as possible if our code is correct. This applies to insert statements, to where expressions, to retrieved values (the compiler knows which value (name, type) is returned in each column), etc. Earlier on, I tried to avoid database interaction where possible, but these days, with the compiler telling me most of the things I could do wrong, database programming is fun :-)