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

Try out asGeoJSON function from slick-pg library #3702

Open
misaugstad opened this issue Oct 22, 2024 · 0 comments
Open

Try out asGeoJSON function from slick-pg library #3702

misaugstad opened this issue Oct 22, 2024 · 0 comments

Comments

@misaugstad
Copy link
Member

Brief description of problem/feature

I never really understood where to find the documentation of what functions are available from the slick-pg library, but I finally found them! And as I was scanning through to search for something else that I wanted, I saw the asGeoJSON function! I'm pretty sure that we are creating geoJSON manually in some places, or using other libraries. We should try to do it directly from slick-pg! It will likely be faster to do this on the db side, and could simplify our code! Here's the documentation:
https://github.com/tminglei/slick-pg/tree/slick2/core/src/main/scala/com/github/tminglei/slickpg/geom#geometry-outputs

And if you look one directory up, it has all the documentation divvied up by data type! There are likely places where I've resorted to writing plain SQL instead of using Slick because I couldn't figure out how to do it using Slick, and we can probably convert some of those to Slick after looking through this!

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

No branches or pull requests

1 participant