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

Consider using ltree type for psql #54

Open
markelog opened this issue May 6, 2016 · 8 comments
Open

Consider using ltree type for psql #54

markelog opened this issue May 6, 2016 · 8 comments

Comments

@markelog
Copy link

markelog commented May 6, 2016

Did you consider using native tree-like structures?

@overlookmotel
Copy link
Owner

@markelog I didn't know there were native tree structures in Postgres!

Presumably, this isn't supported natively in MySQL? As Sequelize is cross-database, I wouldn't want to rely on an implementation which isn't compatible with MySQL and SQLite too.

If you'd like to submit a PR to add a description of how Postgres users can use the native tree structures instead of this module, that'd be very welcome.

Thanks very much for making me aware of this.

@overlookmotel
Copy link
Owner

Note to self: Add details of Postgres ltree structures to README.

@markelog
Copy link
Author

Presumably, this isn't supported natively in MySQL?

It is not, however, it seems you can choose to differentiate approaches between the dbs - for mysql create meta table, for the psql use native implementation

@overlookmotel
Copy link
Owner

Hi @markelog. Yes, could do as you say. However, I don't use Postgres myself and I don't have time to investigate this and make the changes. I think anyway, probably if someone is on Postgres then they could use the native implementation directly without the need for a module like this.

But I haven't looked at the Postgres native interface myself yet, so maybe you disagree? Would it benefit from an abstraction like this module?

@markelog
Copy link
Author

But I haven't looked at the Postgres native interface myself yet, so maybe you disagree? Would it benefit from an abstraction like this module?

I think so, i will talk to some people about implementing this if open to it

@LogansUA
Copy link

LogansUA commented Feb 8, 2018

@markelog Do you have any news from "some people" that you wanted to talk? Because now I really want this feature to be here or somewhere where I can use it :)

@overlookmotel
Copy link
Owner

@LogansUA Just to be clear, this module as it stands works fine on Postgres (except some problems with schemas which no-one seems to have the will to fix, and I'm not going to as I don't use Postgres). It just doesn't use the native Postgres tree type. Possibly that could be more performative, but I don't know. But, yeah, basically it's good to use right now.

@LogansUA
Copy link

LogansUA commented Feb 8, 2018

@overlookmotel Yes, i know it. I'm trying to use it right now in my current project. Just interesting is there any alternative designed for Postgres only.

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

3 participants