Giter VIP home page Giter VIP logo

Comments (2)

bchapuis avatar bchapuis commented on May 22, 2024

Would it be possible to quote (/check for) double quote around the PostgreSQL table names in the backend?

I think so, could you provide me with a greater excerpt of the config in order to reproduce the error?

from incubator-baremaps.

bchapuis avatar bchapuis commented on May 22, 2024

I suspect the PostgreSQL layer name MUST be escaped in the SQL query defined in the ./config/layer.yaml file, especially when they contain non standard SQL characters such as capital letters or digits, because when I escape the layer name using double quotes, it doesn't print this error at startup.

Yes, it has to be escaped. Also, notice that the zoom level is supposed to be part of the table name. I tried to reproduce your case and I think it is working. Assuming that a table named 1_differential_rabbiHousing_z14 exists in the database, baremaps will be able to create tiles (at zoom level 14) that include the following layer:

id: mylayer
type: linestring
queries:
  - minZoom: 14
    maxZoom: 14
    sql: |
      SELECT id, tags, geom
      FROM "1_differential_rabbiHousing_z${zoom}"

The following exerpt (quoted from your comment) is supposed to fail:

FROM "1_differential_rabbiHousing"${zoom}

I'm not sure whereas the layer and id in the stylesheet has to represent the same object and what they do refer to?

Not necessarily, but naming things is hard... ;)

from incubator-baremaps.

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.