Function Issues timestamp_day_of_week
Options
![Michael Cafra](https://us.v-cdn.net/6037124/uploads/userpics/77HUPSI88RA8/n4XJV5YKVQSZ5.png)
Michael Cafra
Member ✭
Hi all,
I am trying to make use the timestamp_day_of_week function on a timestamp parameter in order to check the current day is a certain day. For example now (timestamp) timestamp_day_of_week = 3. This is how my original argument is structured:
[Screen Shot 2022-06-29 at 1.46.21 pm.png]In a basic setting (Using Now) it returns an error message:
message: Unable to locate func entry: epochms_dow
[Screen Shot 2022-06-29 at 1.36.48 pm.png][Screen Shot 2022-06-29 at 1.35.51 pm.png]
When testing I found this argument only works upon using a fixed database date.[Screen Shot 2022-06-29 at 1.35.26 pm.png]Which returns:[Screen Shot 2022-06-29 at 1.35.10 pm.png]I am unsure to why I am unable to use the current time as they are both of type Timestamp. Am I doing something wrong or is there an issue in the function itself?
Thanks in advance.
I am trying to make use the timestamp_day_of_week function on a timestamp parameter in order to check the current day is a certain day. For example now (timestamp) timestamp_day_of_week = 3. This is how my original argument is structured:
[Screen Shot 2022-06-29 at 1.46.21 pm.png]In a basic setting (Using Now) it returns an error message:
message: Unable to locate func entry: epochms_dow
[Screen Shot 2022-06-29 at 1.36.48 pm.png][Screen Shot 2022-06-29 at 1.35.51 pm.png]
When testing I found this argument only works upon using a fixed database date.[Screen Shot 2022-06-29 at 1.35.26 pm.png]Which returns:[Screen Shot 2022-06-29 at 1.35.10 pm.png]I am unsure to why I am unable to use the current time as they are both of type Timestamp. Am I doing something wrong or is there an issue in the function itself?
Thanks in advance.
Comments
-
Anyone on this I’d like to know the same!
-
Hi ,
Are you able to assist? Is this an error on my end or is this a Xano bug?
Thanks in advance. -
looks like a bug where the function stack filters are getting mixed with the database filters.
You can get around this by creating a variable before this statement and set it to the value now and then use the format_timestamp filter with the format w.
Then use that variable in your query. -
Thank you Sean for the work around!
[Screen Shot 2022-07-08 at 9.16.59 am.png][Screen Shot 2022-07-08 at 9.17.07 am.png]
Categories
- All Categories
- 53 ? Announcements
- 47 ? Releases
- 37 ? Welcome
- 983 ? Help! I'm a Noob
- 125 ? No-Code Front-Ends
- 633 ? Working with APIs
- 439 ? Transforming data
- 126 ? Connect Xano to ...
- 50 ?? Find an Expert
- 348 ❓Other questions
- 35 ? Security
- 22 ✂️ Snippets
- 19 ? Showcase
- 7 ?️ Xano Chatter
- 62 ? Video Tutorials
- 171 ? Request a feature
- 229 ? Report a Bug
- 19 ? Templates & Extensions
- 7 ? Feedback