Date Processing

I am developing an Aging Balance Report where I need to retrieve the last date of the month for previous months, but need to retrieve the most current day value in the current month.

The great news is: I have been able to retrieve the last date for the previous months using previous community posts/
I am in a quandary regarding the best methd to retrieve the most current day value in the current month.

0 1 82
1 REPLY 1

Hey Tim,

Maybe you could create a “current_timestamp” dimension. It’s pretty handy for a lot of thinks:

dimension_group: current_timestamp {
  type: time
  timeframes: [raw, date, week, month, quarter, year, hour_of_day, day_of_week_index, day_of_month, day_of_year]
  convert_tz: yes
  sql: current_timestamp ;; #### SNOWFLAKE
#     sql: CURRENT_TIMESTAMP() ;; #### BIGQUERY
#     sql: GETDATE() ;; #### REDSHIFT
}
Top Labels in this Space
Top Solution Authors