raphiniert-com / ra-data-postgrest

react admin client for postgREST
MIT License
110 stars 34 forks source link

remove {} value wrapping for cs/cd #113

Closed ruslantalpa closed 10 months ago

ruslantalpa commented 11 months ago

cs/cd operators are also useful when working with jsonb (not just arrays) so with the current handling one can only run queries like these because of the auto wrapping: SELECT '{1, 2, 3}'::integer[] @> '{2}';

if this is removed (and the lib user is required to format the value), they can now run queries like:

select '[1,2,3]'::jsonb @> '2'; select '[1,2,3]'::jsonb @> '[2,3]'; select '{1, 2, 3}'::integer[] @> '{2,3}';

because they are now in control of the value formatting.

coveralls commented 11 months ago

Pull Request Test Coverage Report for Build 7139007321


Totals Coverage Status
Change from base Build 6618423233: -0.06%
Covered Lines: 265
Relevant Lines: 276

💛 - Coveralls