While this topic may be very old, i figured i may as well respond to it just in case someone else happens to look for this.
https://gist.github.com/Speljohan/5124955 Drop that code in your project, and you'll be able to use the symbol additions like so: Model.all(:column.similar => '[0-9]') Model.all(:column.ilike => '%hello%') Den fredagen den 2:e juli 2010 kl. 16:09:50 UTC+2 skrev Kim: > > I'd like to use postgreSQL's "SIMILAR TO" feature for the sake of > interpreting character classes, like "[a-c]*". > > I found the ever so handy > results = Model.all(:column.like => 'regex') > > but haven't found a similar similarto option. > > Do I need to just hand create the query, or is there a shortcut > like .like for calling it using the .all method? > > Thanks! > -kim. -- You received this message because you are subscribed to the Google Groups "DataMapper" group. To unsubscribe from this group and stop receiving emails from it, send an email to datamapper+unsubscr...@googlegroups.com. To post to this group, send email to datamapper@googlegroups.com. Visit this group at http://groups.google.com/group/datamapper?hl=en. For more options, visit https://groups.google.com/groups/opt_out.