Coder Social home page Coder Social logo

Comments (7)

Algunenano avatar Algunenano commented on June 25, 2024

You are declaring an array, not a tuple.

The correct way would be:

INSERT INTO http (`@timestamp`, clientip, request, status, size) FORMAT JSONEachRow
    {"@timestamp":893964617,"clientip":"40.135.0.0","request":{"method":"GET", "path":"/images/hm_bg.jpg", "version":"HTTP/1.0"},"status":200,"size":24736}

from clickhouse.

DJRickyB avatar DJRickyB commented on June 25, 2024

from clickhouse.

Algunenano avatar Algunenano commented on June 25, 2024

It seems the documentation is wrong. Which version did you check that it was working?

https://fiddle.clickhouse.com/e60fbefc-150e-4248-ab87-78d9a0005a29

from clickhouse.

DJRickyB avatar DJRickyB commented on June 25, 2024

from clickhouse.

Algunenano avatar Algunenano commented on June 25, 2024

It doesn't work in 22.5: https://fiddle.clickhouse.com/ad77fdc9-cf61-4cf0-b5a3-2279700116d7

from clickhouse.

DJRickyB avatar DJRickyB commented on June 25, 2024

Error on processing query: Code: 26. DB::ParsingException: Cannot parse JSON string: expected opening quote:

Apologies, it looks like the copy from the documentation included a newline character. It does work in 22.5: https://fiddle.clickhouse.com/227d593c-10ad-4be6-ab8c-13c6f781c707

from clickhouse.

DJRickyB avatar DJRickyB commented on June 25, 2024

I have updated the description with the fiddle, the fixed query copy, and the last working version

from clickhouse.

Related Issues (20)

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.