Method: Sequel::Postgres::JSONBaseOp#extract

Defined in:
lib/sequel/extensions/pg_json_ops.rb

#extract(*a) ⇒ Object

Returns a JSON value for the object at the given path.

json_op.extract('a') # json_extract_path(json, 'a')
json_op.extract('a', 'b') # json_extract_path(json, 'a', 'b')
[View source]

283
284
285
# File 'lib/sequel/extensions/pg_json_ops.rb', line 283

def extract(*a)
  self.class.new(function(:extract_path, *a))
end