You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
norbertbede
Looking for alternative content search by rest API (unnacented, fuzzy/similarto)
CarlosRuiz:
actually in ODataUtils there are 5 method operators coded: contains, startwith, endswith, tolower and toupper
you can use those operators in a $select query
Improvement
it would be good if we can find a way to add more operators via plugin for example add the operator unaccent in this case
the reason I suggest to do it in plugin (instead of directly in the core) is because the unaccent is not standard (f.e. oracle vs postgres) and there can be several implementations
something like adding an interface to add operators in other plugins like
define the operator:
unaccent
define the DB method:
unaccent(column)
define the parameter method:
unaccent(parameter)
The text was updated successfully, but these errors were encountered:
We would like to implement this concept - this is something absolutely missing/dealbreaker.
I would like to ask you in help with implementation design advice.
Is it enough to write some comments in developer language which methods/classes, should be extended.
Hi @norbertbede - if is a function that is supported by odata I would recommend to integrate it in the rest-core.
I see in odata for example these functions that we don't have implemented:
substringof
indexof
replace
substring
trim
concat
round
floor
ceiling
If not in that list - then is better to discuss what is the function required.
The problem with unaccent (which I think is what you're needing) is that there is a different implementation for that in postgresql (requiring an extension), another for oracle, and another for java, and it can be messy when combining two of those.
So, to allow adding new functions via plugin, I suppose that adding one of the functions above can give an overview about the work required - maybe is simply implementing some OSGi service or interface to add things to the arrays SUPPORTED_PARAM_METHODS and SUPPORTED_METHODS and find a way to get the corresponding conversion to SQL.
https://mattermost.idempiere.org/idempiere/pl/xyten9e763nqmdnku1x7o6j1na
norbertbede
Looking for alternative content search by rest API (unnacented, fuzzy/similarto)
CarlosRuiz:
actually in ODataUtils there are 5 method operators coded: contains, startwith, endswith, tolower and toupper
you can use those operators in a $select query
Improvement
it would be good if we can find a way to add more operators via plugin for example add the operator unaccent in this case
the reason I suggest to do it in plugin (instead of directly in the core) is because the unaccent is not standard (f.e. oracle vs postgres) and there can be several implementations
something like adding an interface to add operators in other plugins like
The text was updated successfully, but these errors were encountered: