Code Monkey home page Code Monkey logo

Comments (4)

vicanso avatar vicanso commented on August 27, 2024

In the previous version, you can use as follows:

const QL = require("influx-ql");
const ql = new QL();
ql.measurement = 'stats';
ql.addField('one', 'two', 'three');
ql.start = '1463142660s';
ql.end = '1463142720s';
ql.addCondition("myCond='40002' or myCond='40007'");
console.info(ql.toSelect());

Now I have updated a new version to enhance the condition function

const QL = require("influx-ql");
const ql = new QL();
ql.measurement = 'stats';
ql.addField('one', 'two', 'three');
ql.start = '1463142660s';
ql.end = '1463142720s';
ql.condition("myCond='40002' or myCond='40007'");
console.info(ql.toSelect());

from influx-ql.

sveip avatar sveip commented on August 27, 2024

Thanks! Would it be an idea to support conditions as key-value pairs where they value can be an array in a case like i have above?

-----Original Message-----
From: "Tree Xie" [email protected]
Sent: ‎13/‎05/‎2016 17:22
To: "vicanso/influx-ql" [email protected]
Cc: "sveip" [email protected]; "Author" [email protected]
Subject: Re: [vicanso/influx-ql] "or" operator for condition (#2)

In the previous version, you can use as follows:
const QL = require("influx-ql");
const ql = new QL();
ql.measurement = 'stats';
ql.addField('one', 'two', 'three');
ql.start = '1463142660s';
ql.end = '1463142720s';
ql.addCondition("myCond='40002' or myCond='40007'");
console.info(ql.toSelect());Now I have updated a new version to enhance condition function
const QL = require("influx-ql");
const ql = new QL();
ql.measurement = 'stats';
ql.addField('one', 'two', 'three');
ql.start = '1463142660s';
ql.end = '1463142720s';
ql.condition("myCond='40002' or myCond='40007'");
console.info(ql.toSelect());—
You are receiving this because you authored the thread.
Reply to this email directly or view it on GitHub

from influx-ql.

vicanso avatar vicanso commented on August 27, 2024

Now I have updated a new version, , you can use as follows:

const QL = require("influx-ql");
const ql = new QL();
ql.measurement = 'stats';
ql.addField('one', 'two', 'three');
ql.start = '1463142660s';
ql.end = '1463142720s';
ql.condition('myCond', ['40002', '40007']);
console.info(ql.toSelect());

from influx-ql.

sveip avatar sveip commented on August 27, 2024

Great, thanks! :-) Will try it out.

-----Original Message-----
From: "Tree Xie" [email protected]
Sent: ‎14/‎05/‎2016 15:57
To: "vicanso/influx-ql" [email protected]
Cc: "sveip" [email protected]; "Author" [email protected]
Subject: Re: [vicanso/influx-ql] "or" operator for condition (#2)

Now I have updated a new version, , you can use as follows:
const QL = require("influx-ql");
const ql = new QL();
ql.measurement = 'stats';
ql.addField('one', 'two', 'three');
ql.start = '1463142660s';
ql.end = '1463142720s';
ql.condition('myCond', ['40002', '40007']);
console.info(ql.toSelect());—
You are receiving this because you authored the thread.
Reply to this email directly or view it on GitHub

from influx-ql.

Related Issues (13)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.