Open
Description
Hi, again! I'm messing around with cozo again and came up with an interesting problem. I've created a web of named queries like:
allowed_users[principal, email] := ...
allowed_channels[principal, channel_id] :=
*channel{author, ...},
allowed_users[principal, author], ...
allowed_threads[principal, channel_id, thread_id] :=
*threads{channel_id, thread_id, author, ...},
allowed_users[principal, author],
allowed_channels[principal, channel_id], ...
I'd like to use these as part of implementing GET /users
, GET /channels
, GET /threads
, etc. That is, these queries will just be filters for a queries against *user
, *channel
, and *thread
. As far as I can tell, I'll just have to duplicate this text for each query. But, is there a way to save these queries like function/stored procedure?
Metadata
Metadata
Assignees
Labels
No labels