This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#copy and paste into rails console to play | |
module DumbHasMany | |
extend ActiveSupport::Concern | |
module ClassMethods | |
def has_many(method, args=nil) | |
if args.nil? || !args.is_a?(Hash) | |
type = method | |
else |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jruby-1.7.4 :769 > Neo4j._query("start n=node(*) match (n) where n.username! =~ '(?i)chrISTOpher' return n").first[:n].username | |
=> "christopher" | |
u = Neo4j._query("start n=node(*) match (n) where n.subject! =~ '[a-z\s]+?at[a-z\s]+?' or n.username! =~ '[a-z]+?man[a-z]+?' return n").to_a |
NewerOlder