OK, Looks like something happen after Postgresql 8.2.6 that breaks the
AS searching.

Postgresql barfs on the use of the "lower" function in the AS query
string in searching.

So an example:
select * from tables where lower(whatever) like '%some_search_string
%'  <--Fails with something like:

ERROR: No function matches the given name and argument types. You
might need to add explicit type casts.

OK with explicit type casts, fixes the issue:
select * from tables where lower(whatever::TEXT) like
'%some_search_string%' <--works fine.


Needless to say.
I've been fumbling around looking for a place to add :TEXT (explicit
type cast) to the search string so I can update postgresql.

Thought it was here:  /vendor/plugins/active_scaffold/lib/actions/
search.rb

Would have love to do something like:
includes_for_search_columns.collect! { |x| x + "::TEXT"}  # But this
just builds the columns (relations) to search not the actual fields to
search in the query string.

Anybody no where this happens? ..I'll post if I find it first.

Thanks ALL!





-- 
You received this message because you are subscribed to the Google Groups 
"ActiveScaffold : Ruby on Rails plugin" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/activescaffold?hl=en.

Reply via email to