[std.database]

Steve Teale steve.teale at britseyeview.com
Wed Oct 12 21:42:04 PDT 2011


There's been a fair amount of discussion along the lines of:

auto thingie = getThingie("AC/DC", "user", "pwd", "schema");
Row[] rows = thingie.exec(meets(Subject("Peter), Object("Roberta")));
// Print out some rows (if you have the energy left)

The focus points have been how to specify the environment - AC/DC, or 
MySQL, or ODBC, or whatever, and the nature of meets(...), and whether it 
might generate SQL, or something completely different.

Are we really working on std.database without conceptual limits, or can I 
assume that we can use an incremental approach, and that for the moment 
we are really talking about std.sql?

Also, while we're on the use-case track, can some of you please think 
about prepared statements, and what binding variables to them might look 
like?

I'm working along the multiple lines of:

setParam(T)(ref T t, enumDirection d);
setParams(T...)(enumDirection d, T args);
setParams(S)(S s, enumDirection d) if (is(S == struct));
setParams(Variant[] va, enumDirection d);

Do we have to assume that parameters that are IN, OUT, or INOUT will be 
required in some cases for stored procedure support?

There's also the question of dealing with large column data. JDBC, I 
think, uses streams to interface to such things, but I wonder if 
providing delegates as part of the binding process might be better. Any 
thoughts?

Thanks
Steve


More information about the Digitalmars-d mailing list