Skip to main content

All Questions

Tagged with
0 votes
1 answer
574 views

How to write SQL Query in Azure cosmos DB to find search pattern of any user

Below is a sample item from azure cosmos DB container, I'm trying to write sql to get below expected output but unable to get it, can you help to write correct sql please. your help is greatly ...
Hussain's user avatar
  • 29
0 votes
1 answer
228 views

Cosmos DB NoSQL - Make a SQL SELECT Query that nests documents, where documents are flat in the database

I'm looking for a SELECT query that, given a familyID, uses a Subquery (https://learn.microsoft.com/en-us/azure/cosmos-db/nosql/query/subquery) that can get me an array result of Families with nested &...
Kevin Hernandez's user avatar
7 votes
1 answer
2k views

Select * Except particular properties in Cosmos DB with SQL API

Consider the following, I have a document that looks something like this: "id": 2 "properties": { "desired": { "Property1": 10, "...
Jeppe Christensen's user avatar
1 vote
2 answers
74 views

Extract value from one table if their values match the 2nd table

Background: I have two tables within a CosmosDB database that hold key:value documents within their containers. T1 and T2 T1 Id: 111 ems_featurecategory: 1234 ems_name: "win" T2 ...
Lynn's user avatar
  • 4,388
0 votes
1 answer
1k views

Hierarchical Queries in cosmos db(document db) SQL API

I need to query a container in cosmos db which has hierarchical links. Let' say we have table employees: EMP_ID MANAGER_ID NAME 120 110 JOHN 110 100 MIKE 100 NULL PAM If I query for EMP_ID 100, ...
g. arshad's user avatar
0 votes
1 answer
406 views

Query Azure Cosmos DB collection based on item status

In Azure Cosmos DB on Azure I have a collection with the following structure: [ { "id": "1", "status": "wait", "order": { "orderId": "P1000", "orderPositionId": "...
JCoordes's user avatar
  • 197
1 vote
1 answer
59 views

Making a new property from the parents property name through SQL on a noSQL type document

PROBLEM I am trying to write a SQL query to make a subproperty of a property part of a "new" property within that respective subproperty. For example a sample document looks like this: [ { ...
nrvaller's user avatar
  • 353
1 vote
1 answer
50 views

Filter datetime value within a JSON collection of a collection inside CosmoDB using SQL

Using Microsoft CosmoDBs SQL like syntax. I have a collection of entries that follow a schema like this (simplified for this post) {"id":"123456", "activities": { "activityA": { ...
user2695105's user avatar
0 votes
1 answer
362 views

Unable to see data after data migration from SQL Server to Azure Cosmos db

I used Azure Data Factory to migrate data from SQL Server to Azure CosmosDB. In Data Factory, it shows the status is Ready and succeeded (100%). Retry attempt is 1. But I am not able to see any data ...
superninja's user avatar
  • 3,321
2 votes
1 answer
5k views

DocumentDB vs. SQL Database

I have a question regarding the usage of a DocumentDB or SQL-Database. E.g. I have categories which can have multiple child categories and so on. Every category can have multiple attributes and every ...
F. Huber's user avatar
  • 169
0 votes
1 answer
148 views

DocumentDB: Possible to nest queries?

I want to check the partner.ids which are in a 30km radius of the user's position, and with these information I want to check which products these partners offer. Can I nest queries with DocumentDB ...
John Brunner's user avatar
  • 2,862