I'm having trouble calling a custom SQL function f...
# exposed
a
I'm having trouble calling a custom SQL function from my code with exposed. The SQL that I want to run is
SELECT app.some_function(2)
I see this so I put this on my table:
Copy code
val functionName = CustomStringFunction("app.some_function", stringParam("2"))
How would I call this? (I suspect I am not doing this correctly at all...)
MyTable.functionName
<-- Like that?
c
Using
functionName
like so:
Copy code
MyTable.slice(functionName).selectAll()
generates SQL:
Copy code
SELECT app.some_function('2') FROM MYTABLE
Is that the output you wanted or were you specifically interested in a SELECT without FROM statement?
a
There's no from in my case, but maybe it wouldn't be so bad for me to associate my function with a table? The actual function in this case creates pagination instances of the table for n number of months. My goal here is to set up a chrome job that calls it every month...