message: Add alias "to_timestamp" for "epoch_ms" (similar to Postgres)
diff: @@ -9,12 +9,14 @@ using namespace std;
  namespace duckdb {
  +template<int DIVISION>
  static void epoch_function(DataChunk &input, ExpressionState &state, Vector &result) {
  assert(input.column_count() == 1);
  string output_buffer;
  UnaryExecutor::Execute<int64_t, timestamp_t, true>(input.data[0], result, input.size(), [&](int64_t input) {
  auto ms_per_day = (int64_t)60 * 60 * 24 * 1000;
  + input *= DIVISION;
  auto date = Date::EpochToDate(input / 1000);
  auto time = (dtime_t)(std::abs(input) % ms_per_day);
  if (input < 0) { // for dates before 1970 time goes backwards
  @@ -34,8 +36,12 @@ static void epoch_function(DataChunk &input, ExpressionState &state, Vector &res
  void EpochFun::RegisterFunction(BuiltinFunctions &set) {
  ScalarFunctionSet epoch("epoch_ms");
  - epoch.AddFunction(ScalarFunction({LogicalType::BIGINT}, LogicalType::TIMESTAMP, epoch_function));
  + epoch.AddFunction(ScalarFunction({LogicalType::BIGINT}, LogicalType::TIMESTAMP, epoch_function<1>));
  set.AddFunction(epoch);
  + // to_timestamp is an alias from Postgres that converts the time in seconds to a timestamp
  + ScalarFunctionSet to_timestamp("to_timestamp");
  + to_timestamp.AddFunction(ScalarFunction({LogicalType::BIGINT}, LogicalType::TIMESTAMP, epoch_function<1000>));
  + set.AddFunction(to_timestamp);
  }
  } // namespace duckdb
  