Short list with things to finish for D2
Don
nospam at nospam.com
Wed Nov 25 00:42:53 PST 2009
Don wrote:
> aarti_pl wrote:
>> Don pisze:
>>>
>>>> Additionally in my framework you can pass around parts of SQL e.g. :
>>>> WhereExpression exp = Where(More(visitcards.id, 100));
>>>>
>>>> You basically *CAN NOT* do it when just using strings.
>>>
>>> Of course you can define a where clause using strings.
Even today, it's easy to take a CTFE/string mixin front-end and create a
wrapper over your framework! So it's trivially easy to prove it can be
done. You can literally do anything. Functionality is not the problem --
the challenge is to make it nice. The CTFE/mixin combo is not nice, but
it definitely has the power.
I'm thinking something like:
auto result = SQL{ SELECT * FROM :localvar WHERE name LIKE 'abc*' AND
price > 300 ORDER BY date DESC }
where SQL is a DSL macro, and the {} are delimiters indicating that it's
a DSL, not normal D code. That's a syntax which is currently available.
More information about the Digitalmars-d
mailing list