Re: relational tables and objects
Date: Sun, 03 Nov 2002 23:22:34 GMT
Message-ID: <3DC5AF65.8090500_at_earthlink.net>
Dm. Arapov wrote:
>>>Sure. RTL checks if a relational operation is valid in compile-time. All
>>>checks and schema computations are done in comile-time. In compile
>>>time we calculate list of colums of result, sort order, check if
>>>colums, on which relation is sorted, make a key.
>Jonathan Leffler extrapolated:
>>So dynamic queries are out of the question - or have to be resolved by
>>compiling new code and then either dynamically loading the new code or
>>running a new program? And you cannot write a generic query program
>>that can be run against any tables in any database without either
>>prior knowledge of what is in the database or access to a compiler?
>
> You are right. All queries are to be pre-compiled and there is no
> way to write a query without prior knowledge of what is in the
> database. This is a pay for compile-type checks, type safety and
> efficient integration with C++ applications. RTL is not a
> replacement of DBMS, it is just a lightweight C++ library letting
> use relational algebra in applications like firewalls or games, for
> which traditional DBMS engines are too bulky.
OK. It's a fair enough limitation as long as it is recognized to exist. It certainly simplifies the implementation. For most of my work, it would be too constraining not to be able to do dynamic queries, but that doesn't stop it being useful to many people for many purposes. It just isn't a complete solution for all of the people all of the time, but then, few if any programming solutions achieve such generality (and few aspire to it, either).
-- Jonathan Leffler #include <disclaimer.h> Email: jleffler_at_earthlink.net, jleffler_at_us.ibm.com Guardian of DBD::Informix 1.00.PC2 -- http://dbi.perl.org/Received on Mon Nov 04 2002 - 00:22:34 CET