SQLf

SQLf is a SQL extended with fuzzy set theory application for expressing flexible (fuzzy) queries to traditional (or ″Regular″) Relational Databases. Among the known extensions proposed to SQL, at the present time, this is the most complete, because it allows the use of diverse fuzzy elements in all the constructions of the language SQL.
SQLf is the only known proposal of flexible query system allowing linguistic quantification over set of rows in queries, achieved through the extension of SQL nesting and partitioning structures with fuzzy quantifiers. It also allows the use of quantifiers to qualify the quantity of search criteria satisfied by single rows. Several mechanisms are proposed for query evaluation, the most important being the one based on the derivation principle. This consists in deriving classic queries that produce, given a threshold "t", a "t"-cut of the result of the fuzzy query, so that the additional processing cost of using a fuzzy language is diminished.
Basic block.
The fundamental querying structure of SQLf is the multi-relational block. The conception of this structure is based on the three basic operations of the relational algebra: projection, cartesian product and selection, and the application of fuzzy sets’ concepts. The result of a SQLf query is a fuzzy set of rows that is a fuzzy relation instead of a regular relation.
A basic block in SQLf consists of a codice_1 clause, a codice_2 clause and an optional codice_3 clause. The semantic of this query structure is:
The following is an example of a codice_1 query that returns a list of hotels that are cheap. The query retrieves all rows from the "Hotels" table that satisfice the fuzzy predicate "cheap" defined by the fuzzy set μ=(, , 25, 30). The result is sorted in descending order by the membership degree of the query.
SELECT name, address
 FROM Hotels
 WHERE price = cheap;