lib/variable_precision_date.rb
# This will parse a `variable_precision_date` from the database.
#
# @api private
# @param [String] sql_string
# @return [VariablePrecisionDate]
This will parse a `variable_precision_date` from the database.
This will parse a ` variable_precision_date ` from the database .
def parse_sql(sql_string)
      decoded = DECODER.decode sql_string
      return new(nil, :none) if decoded.blank?
      value = parse_sql_date decoded[0]
      return new(nil, :none) if value.blank?
      precision = parse_sql_precision decoded[1]
      new value, precision
    end
def parse_sql ( sql_string ) decoded = DECODER . decode sql_string return new ( nil , :none ) if decoded . blank? value = parse_sql_date decoded [ 0 ] return new ( nil , :none ) if value . blank? precision = parse_sql_precision decoded [ 1 ] new value , precision end
This will parse a `variable_precision_date` from the database.
This will parse a ` variable_precision_date ` from the database .
None
VariablePrecisionDate
sql_string
None
api
None