We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Test sample queries for the PIT changes on following types of queries:
Parent issue - #2603
JOIN Queries:
Inner Join: curl -X POST "http://localhost:9200/_plugins/_sql" -H 'Content-Type: application/json' -d' { "query": "SELECT t1.field_1, t2.field_3 FROM testpit t1 INNER JOIN testjoin t2 ON t1.field_2 = t2.field_4" } ' Response: { "schema": [ { "name": "t1.field_1", "type": "text" }, { "name": "t2.field_3", "type": "text" } ], "total": 4, "datarows": [ [ "Sample data 1", "Related data 1" ], [ "Sample data 2", "Related data 2" ], [ "Sample data 1", "Related data 1" ], [ "Sample data 1", "Related data 4" ] ], "size": 4, "status": 200 } Cross Join: curl -X POST "http://localhost:9200/_plugins/_sql" -H 'Content-Type: application/json' -d' { "query": "SELECT t1.field_1, t2.field_3 FROM testpit t1 CROSS JOIN testjoin t2" } ' Response: { "schema": [ { "name": "t1.field_1", "type": "text" }, { "name": "t2.field_3", "type": "text" } ], "total": 40, "datarows": [ [ "Sample data 9", "Related data 1" ], [ "Sample data 10", "Related data 1" ], [ "Sample data 1", "Related data 1" ], [ "Sample data 8", "Related data 1" ], [ "Sample data 7", "Related data 1" ], [ "Sample data 4", "Related data 1" ], [ "Sample data 2", "Related data 1" ], [ "Sample data 6", "Related data 1" ], [ "Sample data 5", "Related data 1" ], [ "Sample data 3", "Related data 1" ], [ "Sample data 9", "Related data 2" ], [ "Sample data 10", "Related data 2" ], [ "Sample data 1", "Related data 2" ], [ "Sample data 8", "Related data 2" ], [ "Sample data 7", "Related data 2" ], [ "Sample data 4", "Related data 2" ], [ "Sample data 2", "Related data 2" ], [ "Sample data 6", "Related data 2" ], [ "Sample data 5", "Related data 2" ], [ "Sample data 3", "Related data 2" ], [ "Sample data 9", "Related data 1" ], [ "Sample data 10", "Related data 1" ], [ "Sample data 1", "Related data 1" ], [ "Sample data 8", "Related data 1" ], [ "Sample data 7", "Related data 1" ], [ "Sample data 4", "Related data 1" ], [ "Sample data 2", "Related data 1" ], [ "Sample data 6", "Related data 1" ], [ "Sample data 5", "Related data 1" ], [ "Sample data 3", "Related data 1" ], [ "Sample data 9", "Related data 4" ], [ "Sample data 10", "Related data 4" ], [ "Sample data 1", "Related data 4" ], [ "Sample data 8", "Related data 4" ], [ "Sample data 7", "Related data 4" ], [ "Sample data 4", "Related data 4" ], [ "Sample data 2", "Related data 4" ], [ "Sample data 6", "Related data 4" ], [ "Sample data 5", "Related data 4" ], [ "Sample data 3", "Related data 4" ] ], "size": 40, "status": 200 } Left Outer Join: curl -X POST "http://localhost:9200/_plugins/_sql" -H 'Content-Type: application/json' -d' { "query": "SELECT t1.field_1, t2.field_3 FROM testpit t1 LEFT OUTER JOIN testjoin t2 ON t1.field_2 = t2.field_4" } ' Response: { "schema": [ { "name": "t1.field_1", "type": "text" }, { "name": "t2.field_3", "type": "text" } ], "total": 12, "datarows": [ [ "Sample data 1", "Related data 1" ], [ "Sample data 2", "Related data 2" ], [ "Sample data 1", "Related data 1" ], [ "Sample data 1", "Related data 4" ], [ "Sample data 4", null ], [ "Sample data 10", null ], [ "Sample data 6", null ], [ "Sample data 7", null ], [ "Sample data 9", null ], [ "Sample data 5", null ], [ "Sample data 3", null ], [ "Sample data 8", null ] ], "size": 12, "status": 200 }
Multi-Query Query: 1.Create the products Index curl -X PUT "http://localhost:9200/products" -H 'Content-Type: application/json' -d' { "mappings": { "properties": { "product_id": { "type": "integer" }, "name": { "type": "text" }, "category": { "type": "keyword" }, "price": { "type": "float" } } } } ' 2. Insert Documents into products curl -X POST "http://localhost:9200/products/_doc/1" -H 'Content-Type: application/json' -d' { "product_id": 1, "name": "Laptop", "category": "electronics", "price": 999.99 } ' curl -X POST "http://localhost:9200/products/_doc/2" -H 'Content-Type: application/json' -d' { "product_id": 2, "name": "Smartphone", "category": "electronics", "price": 499.99 } ' 3. Create the orders Index curl -X PUT "http://localhost:9200/orders" -H 'Content-Type: application/json' -d' { "mappings": { "properties": { "order_id": { "type": "integer" }, "product_id": { "type": "integer" }, "quantity": { "type": "integer" }, "order_date": { "type": "date" } } } } ' 4. Insert Documents into orders curl -X POST "http://localhost:9200/orders/_doc/1" -H 'Content-Type: application/json' -d' { "order_id": 1, "product_id": 1, "quantity": 2, "order_date": "2024-08-17" } ' 5. Perform a Multi-Query Table subquery: curl -X POST "http://localhost:9200/_plugins/_sql" -H 'Content-Type: application/json' -d' { "query": "SELECT p.product_id, p.name AS product_name, p.price FROM products p WHERE p.product_id IN (SELECT o.product_id FROM orders o WHERE o.quantity > 0)" } ' Response: { "schema": [ { "name": "p.product_id", "type": "integer" }, { "name": "p.name", "alias": "product_name", "type": "text" }, { "name": "p.price", "type": "float" } ], "total": 2, "datarows": [ [ 1, "Laptop", 999.99 ], [ 2, "Smartphone", 499.99 ] ], "size": 2, "status": 200 } FROM subquery: curl -X POST "http://localhost:9200/_plugins/_sql" -H 'Content-Type: application/json' -d' { "query": "SELECT sub.product_id, sub.product_name, sub.product_price FROM (SELECT p.product_id, p.name AS product_name, p.price AS product_price FROM products p WHERE p.price > 500) AS sub" } ' Response: { "schema": [ { "name": "product_id", "type": "integer" }, { "name": "product_name", "type": "text" }, { "name": "product_price", "type": "float" } ], "datarows": [ [ 1, "Laptop", 999.99 ] ], "total": 1, "size": 1, "status": 200 }
Query 1 - Pagination query curl -X POST "http://localhost:9200/_plugins/_sql?format=jdbc" -H 'Content-Type: application/json' -d' { "query": "SELECT field_1 FROM testpit where field_2 > 0", "fetch_size" : 2 } ' Response: { "schema": [ { "name": "field_1", "type": "text" } ], "datarows": [ [ "Sample data 1" ], [ "Sample data 2" ] ], "total": 2, "size": 2, "status": 200, "cursor": "n:1f8b08000000000000ff9d94cb4fd4401cc7671f082a51c078d178d0901824765d60358a31e1b12de05ae4555e3166d80eddba7d8cd359e862c28183f1a2e1e2e3a607434cd49b319a180f265e887ae0e65f403ce0d97830fea63c5a657d845e66dae9eff7fdccf7f79b79b686aa3c865a5d66482e258e4730cb1724efba25510b3b0e61122d943d338f2de93273af913cefa78461eeb255f9fcab33475f646b11f229e4389d776dc9705dc322124c6dd781c1b22042eab5ed12c75316c9991e6f1c22ccc496394774d96536da78e22836896a88456ce2708fa30393b96b7806a780c248f54f09e5769f96d8e6822416a48d85c54f630febbc262b2e5820590c784e56d813f129239e67029b8a6da267b7debfdd6cb8f7e3f9838e384ae45015e061606888200c71663a467b0eedd601d2c09ce81c9dc881482a144981482a144985f92130e980e475348f6a7c2a0c4bff1d70904c13469c3c8940a2b5e6f7c50f8b01641273ce8274004c312f0070dd3a70899b564a782d547999128e8e5722d531c729b11e800ec3042ce6a87ada24967e350d8c8702ab453ea983315cf61a8341e4fefcf8fcdb8fb776ad04858b614192d85ea00ddb9eaf68ab5f8edc50b60a247edf0f02e72a9810791584922094a0ed9ca1e0e330f1b9607d7d7fb96d61c95800801cda15308305fb23165cc2b4dddf9146377c131aeff26f96e3dfab3281e3b5a23a5d2e23c381a5cdffb674f367a8c35e1b530a56acc7f6548a8dbc8669b633355e0a3341e23d944120e326f184a9077d3acf5053852d87fb8ca26d9ebf06a80c43fbc2ca659d921d5d148d31a25e54fb4755109077ee69943f2a20e80f739414f585cec8fcc77d0299fe789dc4a1f78ba4fcdb31deb830a06166b0555ab7ec18b4ad18ab4460380386fab0fdbb401ba446ef3c7d79eef093fa048af5a204c746d0ce89d9a488f07f393b17fe6e910777283688e4e5b11371a9d7d1893f04df96ecaf871e75685782fb75f62ea4bf1d4ffab26295c65bfcf484a24d8fb79c2de98ad6a6cb67d3faa855ec1e93d313637d9981d14c71d0d64e8db7189db25d18c82b32238ada3da2a93d44e15c2b6ac561b9d09fd3b21d5bcfe07859cd66e6484fe7809eee73d4a29b565b27329a324855a5d01adbdc58ac9a138f53930b937dff27775eb2b841060000" } curl -X POST "http://localhost:9200/_plugins/_sql" -H 'Content-Type: application/json' -d' > { > "cursor": "n:1f8b08000000000000ff9d94cb4fd4401cc7671f082a51c078d178d0901824765d60358a31e1b12de05ae4555e3166d80eddba7d8cd359e862c28183f1a2e1e2e3a607434cd49b319a180f265e887ae0e65f403ce0d97830fea63c5a657d845e66dae9eff7fdccf7f79b79b686aa3c865a5d66482e258e4730cb1724efba25510b3b0e61122d943d338f2de93273af913cefa78461eeb255f9fcab33475f646b11f229e4389d776dc9705dc322124c6dd781c1b22042eab5ed12c75316c9991e6f1c22ccc496394774d96536da78e22836896a88456ce2708fa30393b96b7806a780c248f54f09e5769f96d8e6822416a48d85c54f630febbc262b2e5820590c784e56d813f129239e67029b8a6da267b7debfdd6cb8f7e3f9838e384ae45015e061606888200c71663a467b0eedd601d2c09ce81c9dc881482a144981482a144985f92130e980e475348f6a7c2a0c4bff1d70904c13469c3c8940a2b5e6f7c50f8b01641273ce8274004c312f0070dd3a70899b564a782d547999128e8e5722d531c729b11e800ec3042ce6a87ada24967e350d8c8702ab453ea983315cf61a8341e4fefcf8fcdb8fb776ad04858b614192d85ea00ddb9eaf68ab5f8edc50b60a247edf0f02e72a9810791584922094a0ed9ca1e0e330f1b9607d7d7fb96d61c95800801cda15308305fb23165cc2b4dddf9146377c131aeff26f96e3dfab3281e3b5a23a5d2e23c381a5cdffb674f367a8c35e1b530a56acc7f6548a8dbc8669b633355e0a3341e23d944120e326f184a9077d3acf5053852d87fb8ca26d9ebf06a80c43fbc2ca659d921d5d148d31a25e54fb4755109077ee69943f2a20e80f739414f585cec8fcc77d0299fe789dc4a1f78ba4fcdb31deb830a06166b0555ab7ec18b4ad18ab4460380386fab0fdbb401ba446ef3c7d79eef093fa048af5a204c746d0ce89d9a488f07f393b17fe6e910777283688e4e5b11371a9d7d1893f04df96ecaf871e75685782fb75f62ea4bf1d4ffab26295c65bfcf484a24d8fb79c2de98ad6a6cb67d3faa855ec1e93d313637d9981d14c71d0d64e8db7189db25d18c82b32238ada3da2a93d44e15c2b6ac561b9d09fd3b21d5bcfe07859cd66e6484fe7809eee73d4a29b565b27329a324855a5d01adbdc58ac9a138f53930b937dff27775eb2b841060000" > } > ' { "schema": [ { "name": "field_1", "type": "text" } ], "datarows": [ [ "Sample data 3" ], [ "Sample data 4" ] ], "total": 2, "size": 2, "status": 200, "cursor": "n:1f8b08000000000000ff9d94cb4fd4401cc7671f082a51c078d178d0901824765d60358a31e1b12de05ae4555e3166d80eddba7d8cd359e862c28183f1a2e1e2e3a607434cd49b319a180f265e887ae0e65f403ce0d97830fea63c5a657d845e66dae9eff7fdccf7f79b79b686aa3c865a5d66482e258e4730cb1724efba25510b3b0e61122d943d338f2de93273af913cefa78461eeb255f9fcab33475f646b11f229e4389d776dc9705dc322124c6dd781c1b22042eab5ed12c75316c9991e6f1c22ccc496394774d96536da78e22836896a88456ce2708fa30393b96b7806a780c248f54f09e5769f96d8e6822416a48d85c54f630febbc262b2e5820590c784e56d813f129239e67029b8a6da267b7debfdd6cb8f7e3f9838e384ae45015e061606888200c71663a467b0eedd601d2c09ce81c9dc881482a144981482a144985f92130e980e475348f6a7c2a0c4bff1d70904c13469c3c8940a2b5e6f7c50f8b01641273ce8274004c312f0070dd3a70899b564a782d547999128e8e5722d531c729b11e800ec3042ce6a87ada24967e350d8c8702ab453ea983315cf61a8341e4fefcf8fcdb8fb776ad04858b614192d85ea00ddb9eaf68ab5f8edc50b60a247edf0f02e72a9810791584922094a0ed9ca1e0e330f1b9607d7d7fb96d61c95800801cda15308305fb23165cc2b4dddf9146377c131aeff26f96e3dfab3281e3b5a23a5d2e23c381a5cdffb674f367a8c35e1b530a56acc7f6548a8dbc8669b633355e0a3341e23d944120e326f184a9077d3acf5053852d87fb8ca26d9ebf06a80c43fbc2ca659d921d5d148d31a25e54fb4755109077ee69943f2a20e80f739414f585cec8fcc77d0299fe789dc4a1f78ba4fcdb31deb830a06166b0555ab7ec18b4ad18ab4460380386fab0fdbb401ba446ef3c7d79eef093fa048af5a204c746d0ce89d9a488f07f393b17fe6e910777283688e4e5b11371a9d7d1893f04df96ecaf871e75685782fb75f62ea4bf1d4ffab26295c65bfcf484a24d8fb79c2de98ad6a6cb67d3faa855ec1e93d313637d9981d14c71d0d64e8db7189db25d18c82b32238ada3da2a93d44e15c2b6ac561b9d09fd3b21d5bcfe07859cd66e6484fe7809eee73d4a29b565b27329a324855a5d01adbdc58ac9a138f53930b937dff27775eb2b841060000" } curl -X POST "http://localhost:9200/_plugins/_sql" -H 'Content-Type: application/json' -d' { "cursor": "n:1f8b08000000000000ff9d94cb4fd4401cc7671f082a51c078d178d0901824765d60358a31e1b12de05ae4555e3166d80eddba7d8cd359e862c28183f1a2e1e2e3a607434cd49b319a180f265e887ae0e65f403ce0d97830fea63c5a657d845e66dae9eff7fdccf7f79b79b686aa3c865a5d66482e258e4730cb1724efba25510b3b0e61122d943d338f2de93273af913cefa78461eeb255f9fcab33475f646b11f229e4389d776dc9705dc322124c6dd781c1b22042eab5ed12c75316c9991e6f1c22ccc496394774d96536da78e22836896a88456ce2708fa30393b96b7806a780c248f54f09e5769f96d8e6822416a48d85c54f630febbc262b2e5820590c784e56d813f129239e67029b8a6da267b7debfdd6cb8f7e3f9838e384ae45015e061606888200c71663a467b0eedd601d2c09ce81c9dc881482a144981482a144985f92130e980e475348f6a7c2a0c4bff1d70904c13469c3c8940a2b5e6f7c50f8b01641273ce8274004c312f0070dd3a70899b564a782d547999128e8e5722d531c729b11e800ec3042ce6a87ada24967e350d8c8702ab453ea983315cf61a8341e4fefcf8fcdb8fb776ad04858b614192d85ea00ddb9eaf68ab5f8edc50b60a247edf0f02e72a9810791584922094a0ed9ca1e0e330f1b9607d7d7fb96d61c95800801cda15308305fb23165cc2b4dddf9146377c131aeff26f96e3dfab3281e3b5a23a5d2e23c381a5cdffb674f367a8c35e1b530a56acc7f6548a8dbc8669b633355e0a3341e23d944120e326f184a9077d3acf5053852d87fb8ca26d9ebf06a80c43fbc2ca659d921d5d148d31a25e54fb4755109077ee69943f2a20e80f739414f585cec8fcc77d0299fe789dc4a1f78ba4fcdb31deb830a06166b0555ab7ec18b4ad18ab4460380386fab0fdbb401ba446ef3c7d79eef093fa048af5a204c746d0ce89d9a488f07f393b17fe6e910777283688e4e5b11371a9d7d1893f04df96ecaf871e75685782fb75f62ea4bf1d4ffab26295c65bfcf484a24d8fb79c2de98ad6a6cb67d3faa855ec1e93d313637d9981d14c71d0d64e8db7189db25d18c82b32238ada3da2a93d44e15c2b6ac561b9d09fd3b21d5bcfe07859cd66e6484fe7809eee73d4a29b565b27329a324855a5d01adbdc58ac9a138f53930b937dff27775eb2b841060000" } ' { "schema": [ { "name": "field_1", "type": "text" } ], "datarows": [ [ "Sample data 5" ], [ "Sample data 6" ] ], "total": 2, "size": 2, "status": 200, "cursor": "n:1f8b08000000000000ff9d94cb4fd4401cc7671f082a51c078d178d0901824765d60358a31e1b12de05ae4555e3166d80eddba7d8cd359e862c28183f1a2e1e2e3a607434cd49b319a180f265e887ae0e65f403ce0d97830fea63c5a657d845e66dae9eff7fdccf7f79b79b686aa3c865a5d66482e258e4730cb1724efba25510b3b0e61122d943d338f2de93273af913cefa78461eeb255f9fcab33475f646b11f229e4389d776dc9705dc322124c6dd781c1b22042eab5ed12c75316c9991e6f1c22ccc496394774d96536da78e22836896a88456ce2708fa30393b96b7806a780c248f54f09e5769f96d8e6822416a48d85c54f630febbc262b2e5820590c784e56d813f129239e67029b8a6da267b7debfdd6cb8f7e3f9838e384ae45015e061606888200c71663a467b0eedd601d2c09ce81c9dc881482a144981482a144985f92130e980e475348f6a7c2a0c4bff1d70904c13469c3c8940a2b5e6f7c50f8b01641273ce8274004c312f0070dd3a70899b564a782d547999128e8e5722d531c729b11e800ec3042ce6a87ada24967e350d8c8702ab453ea983315cf61a8341e4fefcf8fcdb8fb776ad04858b614192d85ea00ddb9eaf68ab5f8edc50b60a247edf0f02e72a9810791584922094a0ed9ca1e0e330f1b9607d7d7fb96d61c95800801cda15308305fb23165cc2b4dddf9146377c131aeff26f96e3dfab3281e3b5a23a5d2e23c381a5cdffb674f367a8c35e1b530a56acc7f6548a8dbc8669b633355e0a3341e23d944120e326f184a9077d3acf5053852d87fb8ca26d9ebf06a80c43fbc2ca659d921d5d148d31a25e54fb4755109077ee69943f2a20e80f739414f585cec8fcc77d0299fe789dc4a1f78ba4fcdb31deb830a06166b0555ab7ec18b4ad18ab4460380386fab0fdbb401ba446ef3c7d79eef093fa048af5a204c746d0ce89d9a488f07f393b17fe6e910777283688e4e5b11371a9d7d1893f04df96ecaf871e75685782fb75f62ea4bf1d4ffab26295c65bfcf484a24d8fb79c2de98ad6a6cb67d3faa855ec1e93d313637d9981d14c71d0d64e8db7189db25d18c82b32238ada3da2a93d44e15c2b6ac561b9d09fd3b21d5bcfe07859cd66e6484fe7809eee73d4a29b565b27329a324855a5d01adbdc58ac9a138f53930b937dff27775eb2b841060000" } curl -X POST "http://localhost:9200/_plugins/_sql" -H 'Content-Type: application/json' -d' { "cursor": "n:1f8b08000000000000ff9d94cb4fd4401cc7671f082a51c078d178d0901824765d60358a31e1b12de05ae4555e3166d80eddba7d8cd359e862c28183f1a2e1e2e3a607434cd49b319a180f265e887ae0e65f403ce0d97830fea63c5a657d845e66dae9eff7fdccf7f79b79b686aa3c865a5d66482e258e4730cb1724efba25510b3b0e61122d943d338f2de93273af913cefa78461eeb255f9fcab33475f646b11f229e4389d776dc9705dc322124c6dd781c1b22042eab5ed12c75316c9991e6f1c22ccc496394774d96536da78e22836896a88456ce2708fa30393b96b7806a780c248f54f09e5769f96d8e6822416a48d85c54f630febbc262b2e5820590c784e56d813f129239e67029b8a6da267b7debfdd6cb8f7e3f9838e384ae45015e061606888200c71663a467b0eedd601d2c09ce81c9dc881482a144981482a144985f92130e980e475348f6a7c2a0c4bff1d70904c13469c3c8940a2b5e6f7c50f8b01641273ce8274004c312f0070dd3a70899b564a782d547999128e8e5722d531c729b11e800ec3042ce6a87ada24967e350d8c8702ab453ea983315cf61a8341e4fefcf8fcdb8fb776ad04858b614192d85ea00ddb9eaf68ab5f8edc50b60a247edf0f02e72a9810791584922094a0ed9ca1e0e330f1b9607d7d7fb96d61c95800801cda15308305fb23165cc2b4dddf9146377c131aeff26f96e3dfab3281e3b5a23a5d2e23c381a5cdffb674f367a8c35e1b530a56acc7f6548a8dbc8669b633355e0a3341e23d944120e326f184a9077d3acf5053852d87fb8ca26d9ebf06a80c43fbc2ca659d921d5d148d31a25e54fb4755109077ee69943f2a20e80f739414f585cec8fcc77d0299fe789dc4a1f78ba4fcdb31deb830a06166b0555ab7ec18b4ad18ab4460380386fab0fdbb401ba446ef3c7d79eef093fa048af5a204c746d0ce89d9a488f07f393b17fe6e910777283688e4e5b11371a9d7d1893f04df96ecaf871e75685782fb75f62ea4bf1d4ffab26295c65bfcf484a24d8fb79c2de98ad6a6cb67d3faa855ec1e93d313637d9981d14c71d0d64e8db7189db25d18c82b32238ada3da2a93d44e15c2b6ac561b9d09fd3b21d5bcfe07859cd66e6484fe7809eee73d4a29b565b27329a324855a5d01adbdc58ac9a138f53930b937dff27775eb2b841060000" } ' { "schema": [ { "name": "field_1", "type": "text" } ], "datarows": [ [ "Sample data 7" ], [ "Sample data 8" ] ], "total": 2, "size": 2, "status": 200, "cursor": "n:1f8b08000000000000ff9d94cb4fd4401cc7671f082a51c078d178d0901824765d60358a31e1b12de05ae4555e3166d80eddba7d8cd359e862c28183f1a2e1e2e3a607434cd49b319a180f265e887ae0e65f403ce0d97830fea63c5a657d845e66dae9eff7fdccf7f79b79b686aa3c865a5d66482e258e4730cb1724efba25510b3b0e61122d943d338f2de93273af913cefa78461eeb255f9fcab33475f646b11f229e4389d776dc9705dc322124c6dd781c1b22042eab5ed12c75316c9991e6f1c22ccc496394774d96536da78e22836896a88456ce2708fa30393b96b7806a780c248f54f09e5769f96d8e6822416a48d85c54f630febbc262b2e5820590c784e56d813f129239e67029b8a6da267b7debfdd6cb8f7e3f9838e384ae45015e061606888200c71663a467b0eedd601d2c09ce81c9dc881482a144981482a144985f92130e980e475348f6a7c2a0c4bff1d70904c13469c3c8940a2b5e6f7c50f8b01641273ce8274004c312f0070dd3a70899b564a782d547999128e8e5722d531c729b11e800ec3042ce6a87ada24967e350d8c8702ab453ea983315cf61a8341e4fefcf8fcdb8fb776ad04858b614192d85ea00ddb9eaf68ab5f8edc50b60a247edf0f02e72a9810791584922094a0ed9ca1e0e330f1b9607d7d7fb96d61c95800801cda15308305fb23165cc2b4dddf9146377c131aeff26f96e3dfab3281e3b5a23a5d2e23c381a5cdffb674f367a8c35e1b530a56acc7f6548a8dbc8669b633355e0a3341e23d944120e326f184a9077d3acf5053852d87fb8ca26d9ebf06a80c43fbc2ca659d921d5d148d31a25e54fb4755109077ee69943f2a20e80f739414f585cec8fcc77d0299fe789dc4a1f78ba4fcdb31deb830a06166b0555ab7ec18b4ad18ab4460380386fab0fdbb401ba446ef3c7d79eef093fa048af5a204c746d0ce89d9a488f07f393b17fe6e910777283688e4e5b11371a9d7d1893f04df96ecaf871e75685782fb75f62ea4bf1d4ffab26295c65bfcf484a24d8fb79c2de98ad6a6cb67d3faa855ec1e93d313637d9981d14c71d0d64e8db7189db25d18c82b32238ada3da2a93d44e15c2b6ac561b9d09fd3b21d5bcfe07859cd66e6484fe7809eee73d4a29b565b27329a324855a5d01adbdc58ac9a138f53930b937dff27775eb2b841060000" } curl -X POST "http://localhost:9200/_plugins/_sql" -H 'Content-Type: application/json' -d' { "cursor": "n:1f8b08000000000000ff9d94cb4fd4401cc7671f082a51c078d178d0901824765d60358a31e1b12de05ae4555e3166d80eddba7d8cd359e862c28183f1a2e1e2e3a607434cd49b319a180f265e887ae0e65f403ce0d97830fea63c5a657d845e66dae9eff7fdccf7f79b79b686aa3c865a5d66482e258e4730cb1724efba25510b3b0e61122d943d338f2de93273af913cefa78461eeb255f9fcab33475f646b11f229e4389d776dc9705dc322124c6dd781c1b22042eab5ed12c75316c9991e6f1c22ccc496394774d96536da78e22836896a88456ce2708fa30393b96b7806a780c248f54f09e5769f96d8e6822416a48d85c54f630febbc262b2e5820590c784e56d813f129239e67029b8a6da267b7debfdd6cb8f7e3f9838e384ae45015e061606888200c71663a467b0eedd601d2c09ce81c9dc881482a144981482a144985f92130e980e475348f6a7c2a0c4bff1d70904c13469c3c8940a2b5e6f7c50f8b01641273ce8274004c312f0070dd3a70899b564a782d547999128e8e5722d531c729b11e800ec3042ce6a87ada24967e350d8c8702ab453ea983315cf61a8341e4fefcf8fcdb8fb776ad04858b614192d85ea00ddb9eaf68ab5f8edc50b60a247edf0f02e72a9810791584922094a0ed9ca1e0e330f1b9607d7d7fb96d61c95800801cda15308305fb23165cc2b4dddf9146377c131aeff26f96e3dfab3281e3b5a23a5d2e23c381a5cdffb674f367a8c35e1b530a56acc7f6548a8dbc8669b633355e0a3341e23d944120e326f184a9077d3acf5053852d87fb8ca26d9ebf06a80c43fbc2ca659d921d5d148d31a25e54fb4755109077ee69943f2a20e80f739414f585cec8fcc77d0299fe789dc4a1f78ba4fcdb31deb830a06166b0555ab7ec18b4ad18ab4460380386fab0fdbb401ba446ef3c7d79eef093fa048af5a204c746d0ce89d9a488f07f393b17fe6e910777283688e4e5b11371a9d7d1893f04df96ecaf871e75685782fb75f62ea4bf1d4ffab26295c65bfcf484a24d8fb79c2de98ad6a6cb67d3faa855ec1e93d313637d9981d14c71d0d64e8db7189db25d18c82b32238ada3da2a93d44e15c2b6ac561b9d09fd3b21d5bcfe07859cd66e6484fe7809eee73d4a29b565b27329a324855a5d01adbdc58ac9a138f53930b937dff27775eb2b841060000" } ' { "schema": [ { "name": "field_1", "type": "text" } ], "datarows": [ [ "Sample data 9" ], [ "Sample data 10" ] ], "total": 2, "size": 2, "status": 200, "cursor": "n:1f8b08000000000000ff9d94cb4fd4401cc7671f082a51c078d178d0901824765d60358a31e1b12de05ae4555e3166d80eddba7d8cd359e862c28183f1a2e1e2e3a607434cd49b319a180f265e887ae0e65f403ce0d97830fea63c5a657d845e66dae9eff7fdccf7f79b79b686aa3c865a5d66482e258e4730cb1724efba25510b3b0e61122d943d338f2de93273af913cefa78461eeb255f9fcab33475f646b11f229e4389d776dc9705dc322124c6dd781c1b22042eab5ed12c75316c9991e6f1c22ccc496394774d96536da78e22836896a88456ce2708fa30393b96b7806a780c248f54f09e5769f96d8e6822416a48d85c54f630febbc262b2e5820590c784e56d813f129239e67029b8a6da267b7debfdd6cb8f7e3f9838e384ae45015e061606888200c71663a467b0eedd601d2c09ce81c9dc881482a144981482a144985f92130e980e475348f6a7c2a0c4bff1d70904c13469c3c8940a2b5e6f7c50f8b01641273ce8274004c312f0070dd3a70899b564a782d547999128e8e5722d531c729b11e800ec3042ce6a87ada24967e350d8c8702ab453ea983315cf61a8341e4fefcf8fcdb8fb776ad04858b614192d85ea00ddb9eaf68ab5f8edc50b60a247edf0f02e72a9810791584922094a0ed9ca1e0e330f1b9607d7d7fb96d61c95800801cda15308305fb23165cc2b4dddf9146377c131aeff26f96e3dfab3281e3b5a23a5d2e23c381a5cdffb674f367a8c35e1b530a56acc7f6548a8dbc8669b633355e0a3341e23d944120e326f184a9077d3acf5053852d87fb8ca26d9ebf06a80c43fbc2ca659d921d5d148d31a25e54fb4755109077ee69943f2a20e80f739414f585cec8fcc77d0299fe789dc4a1f78ba4fcdb31deb830a06166b0555ab7ec18b4ad18ab4460380386fab0fdbb401ba446ef3c7d79eef093fa048af5a204c746d0ce89d9a488f07f393b17fe6e910777283688e4e5b11371a9d7d1893f04df96ecaf871e75685782fb75f62ea4bf1d4ffab26295c65bfcf484a24d8fb79c2de98ad6a6cb67d3faa855ec1e93d313637d9981d14c71d0d64e8db7189db25d18c82b32238ada3da2a93d44e15c2b6ac561b9d09fd3b21d5bcfe07859cd66e6484fe7809eee73d4a29b565b27329a324855a5d01adbdc58ac9a138f53930b937dff27775eb2b841060000" } curl -X POST "http://localhost:9200/_plugins/_sql" -H 'Content-Type: application/json' -d' { "cursor": "n:1f8b08000000000000ff9d94cb4fd4401cc7671f083ea280f102f1a0213162ecbac06a046282b02de85204d6f28a31c376e8d6ed6398ce4a57130e1e8c27e3c5c7c5e8c11013e5668c26c6838917a21eb8f917180f78361e8cbf292c6d7445430f9dceebf7fdf4fbfbcd3c5f43751e439d2e33249712c72398158a92376f49d4c28e4398448b15cf2c604bbac0dc2ba4c047286198bbec8bdcfbead4a117d93d08f914629c2cb8b664b8ae6111093e6dd781c6b260873464db658e672d92333dde364e98892df31ad16597d968e389a3d80c6a2016b189c33d8ef6cfe4aee0ab380514466a645628f7f8b4ccaa139298903626ee7c9a7cd4e81db5e2824504039ee335fe89f89411cf33814dc536d1b39bfdef379beffd5c7ed01747891caa033c0c0ccd118471ce4cc7e8c9a19d3a401a98139da3f61c88a442911488a4429154181f36261d909c478ba8c1a7c2b0f4d68063648e30e214480412ad1d7b5ffa7027804c62ce59100e8029e645006e5c072e73d34a09af852aaf50c2d1915aa43ae63825e603d03c7c80c51cd5cf99c4d22fa781b125b05ac493fa18c315af2d6844eccf4f7adf7ebcb56335485c0c0b92c49f09dab06d7955fbf2f5e075a59aa09858be0f04ba6b9810e90a4249104a5076ce783098273e17acafefaf74dd58326e00400eed0898c1827d110b8631edf1b7a531006342e35de1cd4afc475d26707c8fc84ebfcb483eb0f4d8bf2dad2e863cecb631a560c5fadec15a7b23dd30cc9f4c6dc3612408bc8b32d8c8b8493c61ea019f2e3274b4c62f87ff1945ab9ebf66c80c437bc3cc659db21d9d148571513daf8e4ca820206fdfd3287f5440d0b7729414f985cac8fcc77d0291fe7a9dc4a1f64ba4f2db31deb830a060ae62abbc6ed961285bd1d6898de117303485e5df0fda203571fbd9cbeed6a74d09141b42098e8da09c130b49b1c35faf6af1aea741b37bf3347504fdc6207c73f504b42f8a770b2c1a52f359253b160c82f099adedf5e0fec50691bc0276220e0f393af1c7616cc9fed6f2b84fbb14dccd0b0f41ee6e3ce9cb8a559eeaf0d3d38a3637d571baac2b5a972e9f4eeb13566960524e4f4f9ecb8c4e644a63b67662aac3382bdbc5d1822233a2a80317357590289c6b25ad94978b23392ddbb7f914a72a6a36738d0c9e1dd5d3e71cb5e4a6d5cee98ca68c51552976c6ab174ad58a583d271ea72607b0a4efff025e3e789685060000" } ' { "schema": [ { "name": "field_1", "type": "text" } ], "datarows": [], "total": 0, "size": 0, "status": 200 } ************************* Query 2 - curl -X POST "http://localhost:9200/_plugins/_sql" -H 'Content-Type: application/json' -d' { "query": "SELECT * FROM testpit", "fetch_size" : 4 } ' Response: { "schema": [ { "name": "field_1", "type": "text" }, { "name": "field_2", "type": "integer" } ], "datarows": [ [ "Sample data 1", 1 ], [ "Sample data 2", 2 ], [ "Sample data 3", 3 ], [ "Sample data 4", 4 ] ], "total": 4, "size": 4, "status": 200, "cursor": "n:1f8b08000000000000ff9d94cb4fd4401cc7671f083ea280f102f1a0213162ecbac06a046282b02de85204d6f28a31c376e8d6ed6398ce4a57130e1e8c27e3c5c7c5e8c11013e5668c26c6838917a21eb8f917180f78361e8cbf292c6d7445430f9dceebf7fdf4fbfbcd3c5f43751e439d2e33249712c72398158a92376f49d4c28e4398448b15cf2c604bbac0dc2ba4c047286198bbec8bdcfbead4a117d93d08f914629c2cb8b664b8ae6111093e6dd781c6b260873464db658e672d92333dde364e98892df31ad16597d968e389a3d80c6a2016b189c33d8ef6cfe4aee0ab380514466a645628f7f8b4ccaa139298903626ee7c9a7cd4e81db5e2824504039ee335fe89f89411cf33814dc536d1b39bfdef379beffd5c7ed01747891caa033c0c0ccd118471ce4cc7e8c9a19d3a401a98139da3f61c88a442911488a4429154181f36261d909c478ba8c1a7c2b0f4d68063648e30e214480412ad1d7b5ffa7027804c62ce59100e8029e645006e5c072e73d34a09af852aaf50c2d1915aa43ae63825e603d03c7c80c51cd5cf99c4d22fa781b125b05ac493fa18c315af2d6844eccf4f7adf7ebcb56335485c0c0b92c49f09dab06d7955fbf2f5e075a59aa09858be0f04ba6b9810e90a4249104a5076ce783098273e17acafefaf74dd58326e00400eed0898c1827d110b8631edf1b7a531006342e35de1cd4afc475d26707c8fc84ebfcb483eb0f4d8bf2dad2e863cecb631a560c5fadec15a7b23dd30cc9f4c6dc3612408bc8b32d8c8b8493c61ea019f2e3274b4c62f87ff1945ab9ebf66c80c437bc3cc659db21d9d148571513daf8e4ca820206fdfd3287f5440d0b7729414f985cac8fcc77d0291fe7a9dc4a1f64ba4f2db31deb830a060ae62abbc6ed961285bd1d6898de117303485e5df0fda203571fbd9cbeed6a74d09141b42098e8da09c130b49b1c35faf6af1aea741b37bf3347504fdc6207c73f504b42f8a770b2c1a52f359253b160c82f099adedf5e0fec50691bc0276220e0f393af1c7616cc9fed6f2b84fbb14dccd0b0f41ee6e3ce9cb8a559eeaf0d3d38a3637d571baac2b5a972e9f4eeb13566960524e4f4f9ecb8c4e644a63b67662aac3382bdbc5d1822233a2a80317357590289c6b25ad94978b23392ddbb7f914a72a6a36738d0c9e1dd5d3e71cb5e4a6d5cee98ca68c51552976c6ab174ad58a583d271ea72607b0a4efff025e3e789685060000" } curl -X POST "http://localhost:9200/_plugins/_sql" -H 'Content-Type: application/json' -d' { "cursor": "n:1f8b08000000000000ff9d94cb4fd4401cc7671f083e220fe305e241436290d87581d508c404615bd0a508ace5156386edd0addbc7309d95ae261c3c184fc68b8f8bd1833126cacd184d8c07132f463d78f32f301ef06c3c187f5358dac88a861e3a9dd7effbe9f7f79b79b68aea3c86ba5d66482e258e47302b14256fd192a8851d873089162b9e59c096748eb99748818f51c23077d957b9ffe58983cfb37b10f229c4385e706dc9705dc322127cdaae038d65c10e69c4b6cb1ccf5b24677abc7d9230135be615a2cb2eb3d1fa1347b139d4402c6213877b1ced9bcb5dc297710a288cd4d8bc50eef369995527243121ad4fdcfa34fda0c9ebb0e2824504039ea335fe89f89411cf33814dc536d1b31bfd1fd75beefc5ab9371047891caa033c0c0c2d118449ce4cc7e8cba19d3a401a98139da32339104985222910498522a9303e6c4c3a20b9889651834f8561e9ad0127c80261c4299008245aed7c57fa702b804c62ce59100e8029e645006e5a032e73d34a09af852aaf50c2d1e15aa43ae63825e603d03c7c80c51cd52f98c4d22fa681b135b05ac4930618c315af3d6844ec2f8ffadf7cbcb1e37390b818162489cd095ab76de5b3f6f5db81ab4a354131b1bc11047a6b9810e90a4249104a5076ce643098273e17acafeebeefb9f6d8b8060039b42360060b1a23168c62dae76f4b6308c684c6dbc2ebf7f19f7599c0f13d223b832e23f9c0d2ce7f5b5a5d0c79d86d634ac18ab5bdc3b5f646ba6198cd4ceda3612408bc8b32d8c8b8493c61ea7e9f2e33d451e397c3ff8ca255cf5f0b6486a1bd61e6b24ed98e4e8ac238af9e55c7a6541090b7ef69943f2a20e8db384a8afc426564fee33e81487fbd4ee250fb2552f9e318af5f18503097b1555eb3ec1094ad68ebc4c6f00b189ac3f21f046d909abaf9f4456fdb93e6048a8da004c74650ce89a5a4d8e1af55b578d7d3a0d9bd719aba827e5310bea57a028e2c8b772b2c1a51f359253b110c82f0a9adedf5e0fec50691bc0276220e8f383af12761ecb1fdbdf5e1807621b89b97ee83dced78d29715ab3cd3e5a767156d61a6eb645957b41e5d3e99d6a7acd2d0b49c9e9d3e93199fca94266cedd84c97715ab68be3054566445187ce6bea305138d74a5a292f17c7725a7660e3f1672a6a3673850c9f1ed7d3671cb5e4a6d5eed98ca64c50552976c7ab174ad58a583d271ea72607b0a4efff065980199d85060000" } ' Response: { "schema": [ { "name": "field_1", "type": "text" }, { "name": "field_2", "type": "integer" } ], "datarows": [ [ "Sample data 5", 5 ], [ "Sample data 6", 6 ], [ "Sample data 7", 7 ], [ "Sample data 8", 8 ] ], "total": 4, "size": 4, "status": 200, "cursor": "n:1f8b08000000000000ff9d94cb4fd4401cc7671f083e220fe305e241436290d87581d508c404615bd0a508ace5156386edd0addbc7309d95ae261c3c184fc68b8f8bd1833126cacd184d8c07132f463d78f32f301ef06c3c187f5358dac88a861e3a9dd7effbe9f7f79b79b68aea3c86ba5d66482e258e47302b14256fd192a8851d873089162b9e59c096748eb99748818f51c23077d957b9ffe58983cfb37b10f229c4385e706dc9705dc322127cdaae038d65c10e69c4b6cb1ccf5b24677abc7d9230135be615a2cb2eb3d1fa1347b139d4402c6213877b1ced9bcb5dc297710a288cd4d8bc50eef369995527243121ad4fdcfa34fda0c9ebb0e2824504039ea335fe89f89411cf33814dc536d1b31bfd1fd75beefc5ab9371047891caa033c0c0c2d118449ce4cc7e8cba19d3a401a98139da32339104985222910498522a9303e6c4c3a20b9889651834f8561e9ad0127c80261c4299008245aed7c57fa702b804c62ce59100e8029e645006e5a032e73d34a09af852aaf50c2d1e15aa43ae63825e603d03c7c80c51cd52f98c4d22fa681b135b05ac4930618c315af3d6844ec2f8ffadf7cbcb1e37390b818162489cd095ab76de5b3f6f5db81ab4a354131b1bc11047a6b9810e90a4249104a5076ce643098273e17acafeebeefb9f6d8b8060039b42360060b1a23168c62dae76f4b6308c684c6dbc2ebf7f19f7599c0f13d223b832e23f9c0d2ce7f5b5a5d0c79d86d634ac18ab5bdc3b5f646ba6198cd4ceda3612408bc8b32d8c8b8493c61ea7e9f2e33d451e397c3ff8ca255cf5f0b6486a1bd61e6b24ed98e4e8ac238af9e55c7a6541090b7ef69943f2a20e8db384a8afc426564fee33e81487fbd4ee250fb2552f9e318af5f18503097b1555eb3ec1094ad68ebc4c6f00b189ac3f21f046d909abaf9f4456fdb93e6048a8da004c74650ce89a5a4d8e1af55b578d7d3a0d9bd719aba827e5310bea57a028e2c8b772b2c1a51f359253b110c82f0a9adedf5e0fec50691bc0276220e8f383af12761ecb1fdbdf5e1807621b89b97ee83dced78d29715ab3cd3e5a767156d61a6eb645957b41e5d3e99d6a7acd2d0b49c9e9d3e93199fca94266cedd84c97715ab68be3054566445187ce6bea305138d74a5a292f17c7725a7660e3f1672a6a3673850c9f1ed7d3671cb5e4a6d5eed98ca64c50552976c7ab174ad58a583d271ea72607b0a4efff065980199d85060000" } curl -X POST "http://localhost:9200/_plugins/_sql" -H 'Content-Type: application/json' -d' { "cursor": "n:1f8b08000000000000ff9d94cb4fd4401cc7671f083e220fe305e241436290d87581d508c404615bd0a508ace5156386edd0addbc7309d95ae261c3c184fc68b8f8bd1833126cacd184d8c07132f463d78f32f301ef06c3c187f5358dac88a861e3a9dd7effbe9f7f79b79b68aea3c86ba5d66482e258e47302b14256fd192a8851d873089162b9e59c096748eb99748818f51c23077d957b9ffe58983cfb37b10f229c4385e706dc9705dc322127cdaae038d65c10e69c4b6cb1ccf5b24677abc7d9230135be615a2cb2eb3d1fa1347b139d4402c6213877b1ced9bcb5dc297710a288cd4d8bc50eef369995527243121ad4fdcfa34fda0c9ebb0e2824504039ea335fe89f89411cf33814dc536d1b31bfd1fd75beefc5ab9371047891caa033c0c0c2d118449ce4cc7e8cba19d3a401a98139da32339104985222910498522a9303e6c4c3a20b9889651834f8561e9ad0127c80261c4299008245aed7c57fa702b804c62ce59100e8029e645006e5a032e73d34a09af852aaf50c2d1e15aa43ae63825e603d03c7c80c51cd52f98c4d22fa681b135b05ac4930618c315af3d6844ec2f8ffadf7cbcb1e37390b818162489cd095ab76de5b3f6f5db81ab4a354131b1bc11047a6b9810e90a4249104a5076ce643098273e17acafeebeefb9f6d8b8060039b42360060b1a23168c62dae76f4b6308c684c6dbc2ebf7f19f7599c0f13d223b832e23f9c0d2ce7f5b5a5d0c79d86d634ac18ab5bdc3b5f646ba6198cd4ceda3612408bc8b32d8c8b8493c61ea7e9f2e33d451e397c3ff8ca255cf5f0b6486a1bd61e6b24ed98e4e8ac238af9e55c7a6541090b7ef69943f2a20e8db384a8afc426564fee33e81487fbd4ee250fb2552f9e318af5f18503097b1555eb3ec1094ad68ebc4c6f00b189ac3f21f046d909abaf9f4456fdb93e6048a8da004c74650ce89a5a4d8e1af55b578d7d3a0d9bd719aba827e5310bea57a028e2c8b772b2c1a51f359253b110c82f0a9adedf5e0fec50691bc0276220e8f383af12761ecb1fdbdf5e1807621b89b97ee83dced78d29715ab3cd3e5a767156d61a6eb645957b41e5d3e99d6a7acd2d0b49c9e9d3e93199fca94266cedd84c97715ab68be3054566445187ce6bea305138d74a5a292f17c7725a7660e3f1672a6a3673850c9f1ed7d3671cb5e4a6d5eed98ca64c50552976c7ab174ad58a583d271ea72607b0a4efff065980199d85060000" } ' { "schema": [ { "name": "field_1", "type": "text" }, { "name": "field_2", "type": "integer" } ], "datarows": [ [ "Sample data 9", 9 ], [ "Sample data 10", 10 ] ], "total": 2, "size": 2, "status": 200 }
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Test sample queries for the PIT changes on following types of queries:
Parent issue - #2603
PIT for join query PR - #2703
JOIN Queries:
PIT for multi-query PR - #2753
PIT for pagination query - #2940
The text was updated successfully, but these errors were encountered: