Forum Discussion
Handling bi-weekly data
The requirement is not very clear. You may check if the DAX below helps.
Table =
VAR d =
TODAY ()
RETURN
FILTER (
'Table1',
[Date]
>= DATE ( YEAR ( d ) - 1, MONTH ( d ), DAY ( d ) )
&& [Date]
<= DATE ( YEAR ( d ) - 1, MONTH ( d ), DAY ( d ) )
+ 13
)
- hokiefan11138 years agoAdvocate I
v-chuncz-msft Sorry if I wasn't clear with my requirements, but I'm pulling the data from SQL Server. I don't want to hardcode the dates like I do in my existing statement, so I believe you understood what I was trying to get at. But my question is where do I use a DAX expression like the one you wrote in your post? Is that a query for an entire table? How would I integrate such a query with my existing sql statement below to pull the data:
declare @start_date datetime
declare @end_date datetime
--Date/time when we want to extract from
select @start_date = '2018-07-14 14:35'select @ened_date = '2018-07-28 14:35'
--Pull all histedits marked as Pay Adjust Paid
select * From hist_edit
where status_id = 6
and insert_ts > @start_dateand insert_ts < @end_date
order by hist_edit_id