Database Reference
In-Depth Information
SQLf was conceived for fuzzy querying relational databases. Its basic query structure is:
SELECT <attributes> FROM <relations>
WHERE <fuzzy condition> WITH CALIBRATION k|α|k,α.
The result of this query is a fuzzy relation with the attributes of the SELECT clause projected from
the Cartesian product of the relations in the FROM clause that satisfy the fuzzy condition in the WHERE
clause. The optional WITH CALIBRATION clause, proposed by Tineo (2006) to maintain the orthogo-
nality of the original SQL, indicate the best rows choice in two senses: — Quantitative, retrieving the
top k answers, according to satisfaction degree. — Qualitative, obtaining rows with membership greater
or equal to a threshold α ( alpha cut ).
Goncalves and Tineo (2008) have previously worked towards a real implementation of a flexible
querying system based in SQLf and its extensions. Result of such work is the flexible querying system
named SQLfi. This system implements fuzzy querying capabilities on top of an existing RDBMS by
means of a processing strategy known as the Derivation Principle that we briefly describe here after.
At present time SQLfi is compatible with most popular RDBMS (Oracle, PostgreSQL, MySQL, IBM/
DB2, Firebird and SQL/Server). Nevertheless, SQLfi uses a Loose Coupling strategy (Timarán, 2001)
that has scalability problems.
In this chapter we provide another way of implementing SQLf that surpasses such problems due to
a Tightly Coupling implementation strategy at core of a RDBMS.
Derivation Principle
Fuzzy querying supposes extra cost of processing when compared to crisp ones. For SQLf processing,
in order to minimize this added cost, the Derivation Principle has been conceived (Bosc & Pivert, 2000;
Tineo, 2006). It takes advantage of support and α-cut concepts. Given an SQLf query φ it is possible
to derive a crisp SQL query DQ(φ) retrieving relevant rows for φ , ie support(result(φ)) result(DQ(φ)) .
Then φ is processed on result(DQ(φ)) , membership degrees are computed and rows are filtered accord-
ing to desired query calibration. When we find DQ(φ) such that support(result(φ))=result(DQ(φ)) , the
derivation is said to be strong and the processing does not make unsuccessful computation. Otherwise,
the derivation is said to be weak. Fuzzy queries with boolean connectors (AND, OR, NOT) allow strong
derivation. With the Derivation Principle, SQLf processing is made on top of the RDBMS. This kind
implementation strategy is known as Loose Coupling architecture (Timarán, 2001). Previous works (Bosc
& Pivert 2000; Lopez & Tineo, 2006) have proved Derivation Principle based processing strategy to
be the best in performance respects existing ones. Nevertheless, it has some overhead because rows in
result(DQ(φ)) are rescanned for the fuzzy query processing to compute the membership degree. This is
one reason for the scalability problem of Loose Coupling. We would like to provide a fuzzy query pro-
cessing mechanism with the advantage of Derivation Principle but without problems of Loose Coupling.
For so doing we must extend functionality of RDBMS inner modules. In this chapter we propose needed
extensions. Moreover, we present a real implementation into PostgreSQL source code. Experimental
evidences of this strategy feasibility and benefice are also in this chapter.
Search WWH ::




Custom Search