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

Rename len() to size() for compatibility with openCypher #2218

Closed
sapalli2989 opened this issue Oct 16, 2023 · 4 comments · Fixed by #2220
Closed

Rename len() to size() for compatibility with openCypher #2218

sapalli2989 opened this issue Oct 16, 2023 · 4 comments · Fixed by #2220

Comments

@sapalli2989
Copy link
Contributor

sapalli2989 commented Oct 16, 2023

Currently Kuzu uses len() to get the length of a list (and strings). openCypher names this function size(), which is also the standard in Neo4j.

So I guess the suggestion is to just rename function len -> size.

Related

@andyfengHKU
Copy link
Contributor

Hi @sapalli2989, this make sense to me. Will make the change soon.

@sapalli2989
Copy link
Contributor Author

That was fast :-). With the risk of repeating myself, but in this case I gladly do it: Much appreciated!

@dezren39
Copy link

hi the docs still reference len, how do i update the docs? it would be nice if every page had a link to the markdown so that it's easier to fix things

@acquamarin
Copy link
Collaborator

acquamarin commented Nov 26, 2023

Hi,
Here is the URL to the list functions documentation: https://github.com/kuzudb/kuzu-docs/blob/main/docs/cypher/expressions/list-functions.md
Internally, we implement size() as an alias of len(), so you can simply add another function called size() which is an alias of len()

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 a pull request may close this issue.

4 participants