Socket
Socket
Sign inDemoInstall

@zeit/cosmosdb-query

Package Overview
Dependencies
Maintainers
15
Versions
21
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@zeit/cosmosdb-query

![CircleCI](https://circleci.com/gh/zeit/cosmosdb-query.svg?style=svg&circle-token=9e222857e204b02378b95ed119a319c0e17223d2)


Version published
Weekly downloads
911K
increased by66.89%
Maintainers
15
Weekly downloads
 
Created
Source

cosmosdb-query

CircleCI

This module is experimental, vulnerable and slow. Not intended to be used on production.

const query = require('@zeit/cosmosdb-query')

const collection = [
  { id: 'foo' },
  { id: 'bar' }
]

const docs = query('SELECT * FROM c WHERE c.id = @id')
  .exec(collection, [{ name: '@id', value: 'foo' }])
console.log(docs) // [ { id: 'foo' } ]

q = query('SELECT * FROM c WHERE c.id = 1')
if (!q.containsPartitionKeys(['/key'])) {
  throw new Error('query doesn\'t contain partition keys')
}

TODO

  • Aggregate functions
  • BETWEEN keyword
  • TOP operator
  • VALUE keyword
  • JOIN keyword
  • IN keyword
  • Built-in functions
  • Object constant
  • Array constant
  • Coalesce operator
  • User-defined functions

FAQs

Package last updated on 02 Sep 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc