How to transfer queries via http if the Receiver can handle only SQLStatements or ExpressionsGet record count in Azure DocumentDbIs there a way to configure CosmosDB to use both the SQL (DocumentDB) and MongoDB APIs?What is the mongodb connection string on a Azure Cosmos DB provisioned with a Graph API?How to ensure uniqueness of properties in Cosmos DBDocumentDB request charge when no resultsInput bindings and geo distributed cosmosdbCosmosDB Table API with odata contains filterQueries on Joins in Cosmos DB Sql APIAsp.Net Web Api — OData Query => ComosDb QueryUse Linq.Any() inside a Linq.Where() on CosmosDb

How do we know for sure a transliteration is lossless?

Are there any tricks to pushing a grand piano?

Is there a penalty for switching targets?

Can/should you swim in zero G?

Does every Ubuntu question answer apply to it's derivatives? (Xubuntu, Lubuntu, Kubuntu)

What does it take to recreate microchips like 68000 and 6502 in their original process nodes nowadays?

No interest ever. Just a fee for my end,

How slow was the 6502 Basic compared to Assembly

I've been fired, was allowed to announce it as if I quit and given extra notice, how to handle the questions?

The answer is the same (tricky puzzle!)

Power Adapter for Traveling to Scotland (I live in the US)

Use floats or doubles when writing mobile games

Minimum perfect squares needed to sum up to a target

The work of mathematicians outside their professional environment

As a girl, how can I voice male characters effectively?

How to export the cell above to pdf using the Export[] command (not using GUI)

My second game: War Card game V.1

Why is the time of useful consciousness only seconds at high altitudes, when I can hold my breath much longer at ground level?

How can three vectors be orthogonal to each other?

Persevering Through Very Difficult Periods

Should I reveal productivity tricks to peers, or keep them to myself in order to be more productive than the others?

Should I be able to see patterns in a HS256 encoded JWT?

Found a minor bug, affecting 1% of users. What should QA do?

Non-electric Laser



How to transfer queries via http if the Receiver can handle only SQLStatements or Expressions


Get record count in Azure DocumentDbIs there a way to configure CosmosDB to use both the SQL (DocumentDB) and MongoDB APIs?What is the mongodb connection string on a Azure Cosmos DB provisioned with a Graph API?How to ensure uniqueness of properties in Cosmos DBDocumentDB request charge when no resultsInput bindings and geo distributed cosmosdbCosmosDB Table API with odata contains filterQueries on Joins in Cosmos DB Sql APIAsp.Net Web Api — OData Query => ComosDb QueryUse Linq.Any() inside a Linq.Where() on CosmosDb






.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty
margin-bottom:0;









0















I started recently to use CosmosDB with the Core (SQL) API to use CosmosDB as DocumentDB. But the Interface of CosmosDB, primarily CosmosDBClient.CreateDocumentQuery() [1] and .CreateDatabaseQuery() [2] accepts only Expression or SQL statements. Now I am stuck because the query gets in as a string but has to be translated somehow and I am afraid that whatever I try will never be good enough to be considered as stable.



  • The question would be now how to handle the query that comes from a web interface and should be used from an internal sqlstatement/expression interface?

If you ask why the query is getting in as a string: We use microservices which are triggered via (e.g.:) HTTP GET. And with this GET a query should be provided, for example as Parameter ...?name=Hans&surname=Wurst Or even ODATA.



Links:



  • [1] https://docs.microsoft.com/en-us/dotnet/api/microsoft.azure.documents.client.documentclient.createdocumentquery?view=azure-dotnet

  • [2] https://docs.microsoft.com/en-us/dotnet/api/microsoft.azure.documents.client.documentclient.createdatabasequery?view=azure-dotnet









share|improve this question






























    0















    I started recently to use CosmosDB with the Core (SQL) API to use CosmosDB as DocumentDB. But the Interface of CosmosDB, primarily CosmosDBClient.CreateDocumentQuery() [1] and .CreateDatabaseQuery() [2] accepts only Expression or SQL statements. Now I am stuck because the query gets in as a string but has to be translated somehow and I am afraid that whatever I try will never be good enough to be considered as stable.



    • The question would be now how to handle the query that comes from a web interface and should be used from an internal sqlstatement/expression interface?

    If you ask why the query is getting in as a string: We use microservices which are triggered via (e.g.:) HTTP GET. And with this GET a query should be provided, for example as Parameter ...?name=Hans&surname=Wurst Or even ODATA.



    Links:



    • [1] https://docs.microsoft.com/en-us/dotnet/api/microsoft.azure.documents.client.documentclient.createdocumentquery?view=azure-dotnet

    • [2] https://docs.microsoft.com/en-us/dotnet/api/microsoft.azure.documents.client.documentclient.createdatabasequery?view=azure-dotnet









    share|improve this question


























      0












      0








      0








      I started recently to use CosmosDB with the Core (SQL) API to use CosmosDB as DocumentDB. But the Interface of CosmosDB, primarily CosmosDBClient.CreateDocumentQuery() [1] and .CreateDatabaseQuery() [2] accepts only Expression or SQL statements. Now I am stuck because the query gets in as a string but has to be translated somehow and I am afraid that whatever I try will never be good enough to be considered as stable.



      • The question would be now how to handle the query that comes from a web interface and should be used from an internal sqlstatement/expression interface?

      If you ask why the query is getting in as a string: We use microservices which are triggered via (e.g.:) HTTP GET. And with this GET a query should be provided, for example as Parameter ...?name=Hans&surname=Wurst Or even ODATA.



      Links:



      • [1] https://docs.microsoft.com/en-us/dotnet/api/microsoft.azure.documents.client.documentclient.createdocumentquery?view=azure-dotnet

      • [2] https://docs.microsoft.com/en-us/dotnet/api/microsoft.azure.documents.client.documentclient.createdatabasequery?view=azure-dotnet









      share|improve this question














      I started recently to use CosmosDB with the Core (SQL) API to use CosmosDB as DocumentDB. But the Interface of CosmosDB, primarily CosmosDBClient.CreateDocumentQuery() [1] and .CreateDatabaseQuery() [2] accepts only Expression or SQL statements. Now I am stuck because the query gets in as a string but has to be translated somehow and I am afraid that whatever I try will never be good enough to be considered as stable.



      • The question would be now how to handle the query that comes from a web interface and should be used from an internal sqlstatement/expression interface?

      If you ask why the query is getting in as a string: We use microservices which are triggered via (e.g.:) HTTP GET. And with this GET a query should be provided, for example as Parameter ...?name=Hans&surname=Wurst Or even ODATA.



      Links:



      • [1] https://docs.microsoft.com/en-us/dotnet/api/microsoft.azure.documents.client.documentclient.createdocumentquery?view=azure-dotnet

      • [2] https://docs.microsoft.com/en-us/dotnet/api/microsoft.azure.documents.client.documentclient.createdatabasequery?view=azure-dotnet






      c# azure odata azure-cosmosdb






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked Mar 28 at 16:55









      The_Holy_OneThe_Holy_One

      1212 silver badges13 bronze badges




      1212 silver badges13 bronze badges

























          1 Answer
          1






          active

          oldest

          votes


















          0
















          Where you can use the SQL API with a client library to create a document (See DocumentClient.CreateDocumentQuery Method) and create a database (See DocumentClient.CreateDatabaseQuery Method), there is a corresponding REST API to make that same call and will return items in a JSON string:



          REST: Create Document



          REST: Create Database



          As an option.






          share|improve this answer

























          • I've looked into how to query documents via REST from CosmosDB. The Query has to be a SQLStatement, so this doesn't solve the problem. docs.microsoft.com/en-us/rest/api/cosmos-db/…

            – The_Holy_One
            Mar 29 at 7:23












          Your Answer






          StackExchange.ifUsing("editor", function ()
          StackExchange.using("externalEditor", function ()
          StackExchange.using("snippets", function ()
          StackExchange.snippets.init();
          );
          );
          , "code-snippets");

          StackExchange.ready(function()
          var channelOptions =
          tags: "".split(" "),
          id: "1"
          ;
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function()
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled)
          StackExchange.using("snippets", function()
          createEditor();
          );

          else
          createEditor();

          );

          function createEditor()
          StackExchange.prepareEditor(
          heartbeatType: 'answer',
          autoActivateHeartbeat: false,
          convertImagesToLinks: true,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: 10,
          bindNavPrevention: true,
          postfix: "",
          imageUploader:
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/4.0/"u003ecc by-sa 4.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          ,
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          );



          );














          draft saved

          draft discarded
















          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55403078%2fhow-to-transfer-queries-via-http-if-the-receiver-can-handle-only-sqlstatements-o%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown

























          1 Answer
          1






          active

          oldest

          votes








          1 Answer
          1






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes









          0
















          Where you can use the SQL API with a client library to create a document (See DocumentClient.CreateDocumentQuery Method) and create a database (See DocumentClient.CreateDatabaseQuery Method), there is a corresponding REST API to make that same call and will return items in a JSON string:



          REST: Create Document



          REST: Create Database



          As an option.






          share|improve this answer

























          • I've looked into how to query documents via REST from CosmosDB. The Query has to be a SQLStatement, so this doesn't solve the problem. docs.microsoft.com/en-us/rest/api/cosmos-db/…

            – The_Holy_One
            Mar 29 at 7:23















          0
















          Where you can use the SQL API with a client library to create a document (See DocumentClient.CreateDocumentQuery Method) and create a database (See DocumentClient.CreateDatabaseQuery Method), there is a corresponding REST API to make that same call and will return items in a JSON string:



          REST: Create Document



          REST: Create Database



          As an option.






          share|improve this answer

























          • I've looked into how to query documents via REST from CosmosDB. The Query has to be a SQLStatement, so this doesn't solve the problem. docs.microsoft.com/en-us/rest/api/cosmos-db/…

            – The_Holy_One
            Mar 29 at 7:23













          0














          0










          0









          Where you can use the SQL API with a client library to create a document (See DocumentClient.CreateDocumentQuery Method) and create a database (See DocumentClient.CreateDatabaseQuery Method), there is a corresponding REST API to make that same call and will return items in a JSON string:



          REST: Create Document



          REST: Create Database



          As an option.






          share|improve this answer













          Where you can use the SQL API with a client library to create a document (See DocumentClient.CreateDocumentQuery Method) and create a database (See DocumentClient.CreateDatabaseQuery Method), there is a corresponding REST API to make that same call and will return items in a JSON string:



          REST: Create Document



          REST: Create Database



          As an option.







          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered Mar 28 at 21:08









          Mike Ubezzi MSFTMike Ubezzi MSFT

          5861 silver badge6 bronze badges




          5861 silver badge6 bronze badges















          • I've looked into how to query documents via REST from CosmosDB. The Query has to be a SQLStatement, so this doesn't solve the problem. docs.microsoft.com/en-us/rest/api/cosmos-db/…

            – The_Holy_One
            Mar 29 at 7:23

















          • I've looked into how to query documents via REST from CosmosDB. The Query has to be a SQLStatement, so this doesn't solve the problem. docs.microsoft.com/en-us/rest/api/cosmos-db/…

            – The_Holy_One
            Mar 29 at 7:23
















          I've looked into how to query documents via REST from CosmosDB. The Query has to be a SQLStatement, so this doesn't solve the problem. docs.microsoft.com/en-us/rest/api/cosmos-db/…

          – The_Holy_One
          Mar 29 at 7:23





          I've looked into how to query documents via REST from CosmosDB. The Query has to be a SQLStatement, so this doesn't solve the problem. docs.microsoft.com/en-us/rest/api/cosmos-db/…

          – The_Holy_One
          Mar 29 at 7:23




















          draft saved

          draft discarded















































          Thanks for contributing an answer to Stack Overflow!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid …


          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.

          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55403078%2fhow-to-transfer-queries-via-http-if-the-receiver-can-handle-only-sqlstatements-o%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          How to preserve electronics (computers, tablets and phones) for hundreds of years Announcing the arrival of Valued Associate #679: Cesar Manara Planned maintenance scheduled April 23, 2019 at 23:30 UTC (7:30pm US/Eastern) The network's official Twitter account is up and running again. What content…How might modern humans leave a message for 50,000 years?How would an aquatic race develop computers?How do we make computers care for human life?Keeping supplies for 1000 yearsWhat will cell phones become in 100 years?What body armor protects against a laser?Could a society attain 1800s technology if limited to using copper and bronze?Electricity power (magic) and electronicsScavenging metal resources in post-apocalypse after 100 yearsWhy would precursors create devices that can survive and still work after hundreds of years?

          155 수학 과학 기타 둘러보기 메뉴eh추가해eh문서를 완성해

          해남서초등학교 학교 연혁 학교 동문 외부 링크 둘러보기 메뉴북위 34° 34′ 21″ 동경 126° 35′ 50″ / 북위 34.5726385° 동경 126.5972670°  / 34.5726385; 126.5972670해남서초등학교eh