1

influxDB and curl

Referred to this link and managed to insert 1 row into influxDB Insert line in InfluxDB using CURL

  1. Have ensured that my csv does not contain carriage returns
  2. Have ensured that there is a separate row for each data point/ measurement

Sample CSV: test A=0,B=0,C=0.02,D=0 test A=0,B=0,C=0.02,D=0

Curl command: curl -i -XPOST http://localhost:8086/write?db=mydb --data-binary @data3.csv

Any clues please? Thanks

1
  • Running into issues while doing bulk insert {"error":"unable to parse 'teststat A=0,B=0,C=0.02,D=0.1\rteststat A=0,B=0,C=0.02,D=0.1\rteststat A=0.1,B=0.2,C=0.02,D=0.1\rteststat A=0,B=0,C=0.02,D=0.1\rteststat A=0.2,B=0,C=0.02,D=0.1\r': invalid number"} Commented Oct 9, 2017 at 1:40

1 Answer 1

1
'teststat A=0,B=0,C=0.02,D=0.1\rteststat A=0,B=0,C=0.02,D=0.1\rteststat A=0.1,B=0.2,C=0.02,D=0.1\rteststat A=0,B=0,C=0.02,D=0.1'

Should be

'teststat A=0,B=0,C=0.02,D=0.1\nteststat A=0,B=0,C=0.02,D=0.1\nteststat A=0.1,B=0.2,C=0.02,D=0.1\nteststat A=0,B=0,C=0.02,D=0.1\n'

replace the \r with \n

Sign up to request clarification or add additional context in comments.

1 Comment

any way to push data without re-specifying "tags" every line?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.