def METHOD_NAME(x, unit="s"):
    if unit == "s":
        return sa.func.dateadd(sa.text("s"), x, "1970-01-01 00:00:00")
    if unit == "ms":
        return sa.func.dateadd(sa.text("s"), x / 1_000, "1970-01-01 00:00:00")
    raise com.UnsupportedOperationError(f"{unit!r} unit is not supported!")