Re: object databases



Well, I never understood the so called "impedance mismatch" problem.
Calling SQL from say java code is one of the easiest tasks in mordern
programming. Getting results back is straightforward as well.

The major problem is that SQL statements are written as strings in
Java. And in Java you can't write a string that spans multiple lines.
You need use + operator or StringBuffer append. Even in languages with
proper string features, the strings are not compiled until runtime. But
embedded SQL is the solution to that problem. Unfortunately embedded
SQL for java, SQLJ, is very rarely used. In other languages like COBOL
or C it is much more common.

What I
also never has been able to grasp is why would you discard this simple
idea lightly in favor of learning obscure 20 something mapping rules
(TopLink).

It is based on the misconception that the network model (object graphs)
are better suited for data management, than the relational model (set
theory and predicate logic). If you prefer object graphs, you need
verbose O/R mapping.

Fredrik Bertilsson
http://frebe.php0h.com

.



Relevant Pages

  • Re: use of DBI; I am getting multiple error messages mixed in with the correct output.
    ... Perl was to relate it to uninitialized values in Java or C++. ... The fact that nulls in SQL have special ... Both Java and C++ have containers that support set theoretic ...
    (comp.lang.perl.misc)
  • Re: find certain strings in java files not inside comments
    ... > I want to determine if there any of the following strings in a java ... > with a list of java files starting at $ARGV. ... > /* blah blah blah ... > foreach(@ARGV) ...
    (comp.lang.perl.misc)
  • Re: Java compatibility issues (WAS: MF having issues?)
    ... I believe, that the JLS (Java Language Specification) REQUIRES that this optimization be done. ... package testPackage; ... true true true true false true ... * Literal strings within different classes in the same package represent references to the same String object. ...
    (comp.lang.cobol)
  • Re: SQL
    ... Persistence access is the abstraction, ... However, UML is just one of many OOA/D notations proposed, so it is an implementation of an OOA/D notation. ... Note that I was careful to say that SQL is a solution to persistence /access/ when the data is represented in RDB form. ... Sounds a little bit like Java and the JVM.... ...
    (comp.object)
  • Re: SQL Injection with JDBC
    ... fixed SQL instead of building the SQL dynamicly. ... At most, they may have included clauses dynamically, but in my own experience that type of code is very messy to maintain, and one winds up selecting entire query strings based on user input, not building the strings up piecemeal. ... The thing that Arne say "should not be used in real-world projects" is non-parametrized, non-prepared statements where the SQL string is built up entirely in text then executed as such. ... The thing that we recommend is the use of PreparedStatement to embed type-safe parameters into SQL statements that are not subject to such flaws. ...
    (comp.lang.java.programmer)