Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update install.pgsql.sql #44

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Conversation

Antoviscomi
Copy link

@Antoviscomi Antoviscomi commented Sep 11, 2023

  • Ticket : # Fix Query failed: ERROR on LWC 3.6.5 and pgrouting_module 1.0.8
  • 2023-09-11 11:59:01 [2] pg_execute(): Query failed: ERRORE: la colonna "lg.geom" deve comparire nella clausola GROUP BY o essere usata in una funzione di aggregazione
    LINE 48: ST_AsGeoJSON(ST_Transform(lg.geom, 4326))::j...

@Gustry
Copy link
Member

Gustry commented Aug 5, 2024

Sorry @Antoviscomi for the late reply

Is this PR still needed ?
Is-it not fixed ?

@Antoviscomi
Copy link
Author

Antoviscomi commented Aug 5, 2024

Sorry @Antoviscomi for the late reply

Is this PR still needed ? Is-it not fixed ?

@Gustry I didn't read anymore about of this error since 3.6.6 or later, so i think it's fixed or now compatible with install.pgsql.sql new versions. But my pgrouting db it's configured with this PR in, so, I don't know it's still needed @nboisteault @rldhont can tell us more about

@Antoviscomi Antoviscomi closed this Aug 5, 2024
@Antoviscomi Antoviscomi reopened this Aug 5, 2024
@Antoviscomi
Copy link
Author

Antoviscomi commented Aug 5, 2024

@Gustry I reopened this because of in current install.pgsql.sql there isn't lg.geom call, but i remembered that my pgrouting db it's configured with a local install.pgsql.sql edited by me at the error time, so the error message doesn't appear anymore

@Gustry Gustry requested a review from mdouchin August 6, 2024 09:01
@Antoviscomi Antoviscomi deleted the patch-1 branch September 26, 2024 07:30
@Antoviscomi Antoviscomi restored the patch-1 branch September 26, 2024 07:30
@Antoviscomi Antoviscomi deleted the patch-1 branch September 26, 2024 07:35
@Antoviscomi Antoviscomi restored the patch-1 branch September 26, 2024 07:36
@Antoviscomi Antoviscomi reopened this Sep 26, 2024
@Antoviscomi
Copy link
Author

Antoviscomi commented Sep 27, 2024

@Gustry i've noticed that in new version of pgrouting module (1.1.2) of install.psql.sql lg.geom in not more required in GROUP BY in the

`point_interest as (
        SELECT
        'FeatureCollection' As type,
        array_to_json(array_agg(f)) As features
        FROM (
            SELECT
                'Feature' AS type,
                Concat(
                    'poi',
                    '.',
                    "id") AS id,
                ST_AsGeoJSON(ST_Transform(lg.geom, 4326))::json As geometry,
                row_to_json(
                    ( SELECT l FROM
                        (
                            SELECT MIN(s.seq) AS seq, lg.id, lg.label, lg.type, lg.description
                        ) As l
                    )
                ) As properties
            FROM pgrouting.routing_poi As lg
            JOIN source as s
                ON ST_DWithin(ST_Transform(s.geom, 2154), lg.geom, 1)
            GROUP BY s.seq, lg.id, lg.label, lg.type, lg.description
            ORDER BY s.seq
        ) AS f
    )
`

query, in LWC 3.8.x (but I'm not sure is the same for previous versions: 3.6.x and 3.7.x). Let me know

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants