Getting Data In

filter by last six month data on last month date

abhishekdubey00
Engager

I have date field which is showing date I want only last date of every month and i want filter only last six month if i choose in time picker last 6 moth it shows last date of month like

2019-05-31 23:59:59.999999+00

2019-04-30 23:59:59.999999+00

2019-03-31 23:59:59.999999+00

2019-02-28 23:59:59.999999+00

2019-01-31 23:59:59.999999+00

2018-12-31 23:59:59.999999+00

how it will possible please suggest me
alt text

0 Karma

FrankVl
Ultra Champion

Assuming your date field is called date

...your base search...
| bin _time span=1mon
| stats latest(date) as last-date-of-month by _time
| fields last-date-of-month
0 Karma

abhishekdubey00
Engager

but its showing only may date of data i need last six month data from now last six month with only last date of every month

0 Karma

FrankVl
Ultra Champion

Can you upload a screenshot somewhere and post the link here? If you are actually searching over 6 months of data, I don't see how it would only return dates from may.

0 Karma

abhishekdubey00
Engager

I have uploaded image above please see

0 Karma

FrankVl
Ultra Champion

You're doing bin _time span=6mon. That must be span=1mon. You're searching over 6 months in total, but want to group the data monthly to get the latest(date) per month.

0 Karma
Get Updates on the Splunk Community!

Built-in Service Level Objectives Management to Bridge the Gap Between Service & ...

Wednesday, May 29, 2024  |  11AM PST / 2PM ESTRegister now and join us to learn more about how you can ...

Get Your Exclusive Splunk Certified Cybersecurity Defense Engineer at Splunk .conf24 ...

We’re excited to announce a new Splunk certification exam being released at .conf24! If you’re headed to Vegas ...

Share Your Ideas & Meet the Lantern team at .Conf! Plus All of This Month’s New ...

Splunk Lantern is Splunk’s customer success center that provides advice from Splunk experts on valuable data ...