- Status: DRAFT
- Latest: dp4-feature-status
- Modified: 2015-2-17
This document specifies the features of N1QL DP4 and Sherlock, and their current status for QE.
The document also indicates the status of features with respect to Couchbase datastore and file-based datastore.
See the N1QL SELECT spec, DDL spec, and DML spec.
-
REST API
-
Expressions
-
Literals
-
Identifiers
-
Nested: field navigation, array indexing, array slicing
-
Case: simple case, searched case
-
Logical: AND, OR, NOT
-
Comparison: operators, BETWEEN, LIKE, IS [ VALUED, NULL, MISSING ]
-
Arithmetic: operators
-
Concatetion
-
Subqueries
-
EXISTS / IN / WITHIN
-
ANY / SOME / EVERY
-
ARRAY / FIRST / OBJECT
-
Construction: literal objects and arrays
-
Functions
-
Date functions
-
String functions
-
Number functions
-
Array functions
-
Object functions
-
JSON functions
-
Comparison functions
-
Conditional functions for unknowns
-
Conditional functions for numbers
-
Meta functions
-
Type checking functions
-
Type conversion functions
-
Aggregate functions
-
-
-
SELECT
-
DISTINCT / ALL
-
RAW
-
JOIN / NEST / UNNEST
-
UNION / INTERSECT / EXCEPT
-
LET / LETTING
-
Subqueries
-
GROUP BY / HAVING / LETTING
-
ORDER BY / LIMIT / OFFSET
-
-
EXPLAIN
-
PREPARE
-
CREATE INDEX
-
CREATE PRIMARY INDEX
-
DROP INDEX
-
DROP PRIMARY INDEX
-
INSERT
-
UPSERT
-
DELETE
-
UPDATE
-
MERGE
The REST API is defined at Query REST API. It is 80% implemented, and should be fully implemented and testable by 11/20/2014.
The REST API document includes:
- Endpoint URLs
- request and response formats
- result signatures
- result metrics
- error formats
- scan consistency settings
- prepared statements
- parameters
Expressions are implemented and testable, with the following exceptions:
-
OBJECT is not yet implemented.
-
The following operators do not yet support the
name-var :
syntax for ranging over attribute names.-
WITHIN
-
ANY / SOME / EVERY
-
ARRAY / FIRST / OBJECT
-
SELECT is implemented and testable, with the following exceptions:
-
Index selection is not yet implemented, so a primary index is always used.
-
LETTING without GROUP BY is not yet implemented.
EXPLAIN is implemented, but the output format is still being fine-tuned. It is ready for manual testing, but automated tests may break if the format changes.
PREPARE is implemented, but the output format is possibly subject to change. It is ready for manual testing, but automated tests may break if the format changes. PREPARE returns the query plan and signature of the given statement.
CREATE INDEX is implemented for view indexes. Only a subset of expressions is supported for the index expressions; other expressions will generate a "not implemented" or "not supported" message.
Secondary indexes will be integrated in the coming weeks.
CREATE PRIMARY INDEX is implemented for view indexes.
Secondary indexes will be integrated in the coming weeks.
DROP INDEX is implemented for view indexes.
Secondary indexes will be integrated in the coming weeks.
DROP PRIMARY INDEX is implemented for view indexes.
Secondary indexes will be integrated in the coming weeks.
ALTER INDEX is not in scope for DP4 or Sherlock.
The syntax for INSERT has changed. As of 12/22/2014, the new syntax has been implemented according to the spec.
The syntax for UPSERT has changed. As of 12/22/2014, the new syntax has been implemented according to the spec.
DELETE is implemented and testable for Couchbase and file-based datastores.
UPDATE is implemented and testable for Couchbase and file-based datastores.
MERGE is implemented and testable for Couchbase and file-based datastores. The current implementation is known to cause a crash See MB-12327.
All index operations will be supported on GSI indexes, in addition to view indexes.
- CREATE PRIMARY INDEX
- CREATE INDEX
- DROP INDEX
- SELECT * FROM system:indexes
Product Management has requested index hints that allow users to specify which index will be used. See MB-12219.
SASL buckets are supported in Sherlock. Every query and every type of statement can access both SASL and non-SASL buckets. Also, a single statement that contains JOINs or subqueries can access any combination of multiple SASL and non-SASL buckets.
Based on user feedback, we have added the ability to have subqueries in a FROM clause. A subquery in a FROM clause may or may not have a USE KEYS clause. In this case, the USE KEYS clause is optional.
The output formats should be fairly stable now. This applies to results, signatures, EXPLAIN, REST API, and other responses.
The error messages have also been designed and are being implemented and stabilized.
- 2014-11-17 - Initial version
- 2014-11-24 - Delivery dates
- New dates for implementing INSERT and UPSERT
- 2014-12-22 - INSERT and UPSERT
- Implement new syntax for INSERT and UPSERT
- 2015-2-16 - Sherlock
- Update feature status for Sherlock
- Remove ALTER INDEX
- 2015-2-17 - Scan consistency
- Add mention of scan consistency