Hello Fellow bubble developers. I have a problem working on dates to show list of customers in my app who’s birthday are current date. It doesn’t work for me when i choose current date/time.
I have a data type ‘Customer’ with data field of ‘DOB’ (stored as date). so i want to show a list of customers who’s birthday is today.
Hey @hardyfawei4real - it can be helpful to think of current date/time as timestamps (e.g. a specific second during the day).
So when organising and looking for date/times today, you’ll be better off searching for DOB >= current day:rounded down to day (12:00am) and DOB < tomorrow:rounded down to day (12:00am)
Another thing you’ll need to think about in many cases is timezone, but I don’t think that applies here.
A quick fix would be to store the birthdate as text (like “09/18”) and use:
DOB = current datetime :extract month/current datetime :extract day (in an arbitrary text)
use DOB contains if you store in the text a birthdate like “09/18/1970”
if you need absolutely to keep this field as a date then you can use advanced filter but it’s very slow and WU consuming. with this formula:
Thank you for supporting!!
I have not solve the problem though…
Now i just realized the year is what makes it not to work.
For instance, If a customer’s birthday is September 19, 1990, I expect the customer’s birth day to be today (September 19, 2024) hence customer should be listed.
But it fails since the year (the only part of the date. example: 1990) of the birthday doesn’t match with current year (2024). I still need a way to consider only the month and day ( September 19) in the search while ignoring the year part of the date.