Close Menu
    Facebook X (Twitter) Instagram
    Monday, July 14
    X (Twitter) LinkedIn
    All about Endpoint Management
    • Home
    All about Endpoint Management
    Home»CM2012»SCCM Configmgr How to get clients maintenance window with custom dates (Past and Future )

    SCCM Configmgr How to get clients maintenance window with custom dates (Past and Future )

    Eswar KonetiBy Eswar KonetiJanuary 24, 1:47 pm2 Mins Read CM2012 5,880 Views
    Share
    Facebook Twitter LinkedIn Reddit

    Introduction:

    Maintenance windows in Configmgr help to ensure that client configuration changes occur during periods that do not affect the productivity of the organization.

    Following Operations can be performed during the Maintenance window:

    • Software update deployments
    • Compliance settings deployment and evaluation
    • Operating system deployments
    • Task sequence deployments

    More about MW https://technet.microsoft.com/en-us/library/hh508762.aspx?f=255&MSPPError=-2147217396

    Problem:

    So ,If you want to know the client maintenance window for next few days (20 days or recently occurred in the last 20 days ) ,you have no built in report and for that, you must go with custom report to find out the clients that are undergoing the changes that are deployed by your SCCM team.

    I had a requirement to create report to get client maintenance window with prompt to choose past (occurred) and future days (going to happen) or simply enter the client name to list available maintenance Windows.

    Solution:

    This blog post will help you to identify the clients have maintenance window setup for the next few days or recently occurred with some custom dates.

    What you get with this report : list clients with their collection name, Maintenance Window Name, Description (effective date),Days ahead (If –(minus) ,it was past date ,else future date )

    After you run this report, it will prompt you to choose Past (-10) and Future (10) .Past and Future is considered from Current date.

    For Ex: Today is 24-Jan-2017 ,I have client PC001 in collection ABC with MW set 21-Jan-2017 and PC002 in collection CDE with MW set 28-Jan-2017 .So I choose Past as 3 days and future 10 days ,I should get all clients from ABC and CDE collections as their MW fall under past (2) and future date (10) .

    If I choose past as 1 day and future 3 days ,I won’t get anything in the report as there is no client that has MW between 1 <--->3 from current date.

    The logic used in the SQL is: Maintenance Window date should be <future date and >past date from the current Date as shown in below snippet.

    clip_image001

    How does the report look like ?

    image

     

    As usual, download the RDL file from TechNet Gallery here ,upload to your SSRS folder ,change the data source and run the report.

    configmgr maintenance Window Next available Reports SCCM Service Window SQL SQL query SSRS
    Share. Twitter LinkedIn Email Facebook Reddit

    Related Posts

    SCCM SQL Report – Compare Installed Apps on TWO Different Computers

    July 13, 10:35 am

    Optimize Your Intune Workflow with a Powerful Browser Extension

    March 22, 10:39 am

    Migrate Microsoft 365 Updates from SCCM/MECM to Intune for Co-Managed Devices

    February 11, 9:50 pm

    6 Comments

    1. R.J. on October 15, 2019 12:14 AM

      Hi Eswar,

      did you see my comment on this from a few days ago?

      regards, roland

      Reply
      • Eswar Koneti on October 15, 2019 8:07 PM

        Hi,
        No,i could not see it. can you please post it here ?

        Thanks,
        Eswar

        Reply
    2. Roland on October 10, 2019 5:52 PM

      Hi,

      I'd like to add to an existing report just the next available maintenance window in the form of "from-to" in one column (as software center shows it).
      So basically, the closest MW from getdate().
      Can you help me here?

      cheers, roland

      Reply
      • Eswar Koneti on October 15, 2019 8:16 PM

        Hi,
        This is possible. I will take a look at it this week and update the blog post.

        Thanks,
        Eswar

        Reply
    3. Ryan Maider on February 23, 2017 4:52 AM

      This is a nice report and I wish we could build of it but, it uses the v_ServiceWindow StartTime field which only returns future dates of MW that are scheduled for the future if you currently have old MW that are reoccurring they will not show.

      Reply
      • Eswar Koneti on March 9, 2017 11:13 PM

        you can use the SQL view to build custom reports.

        Regards,
        Eswar

        Reply

    Leave a ReplyCancel reply

    This site uses Akismet to reduce spam. Learn how your comment data is processed.

    Sign Up

    Get email notifications for new posts.

    Author

    I’m Eswar Koneti ,a tech enthusiast, security advocate, and your guide to Microsoft Intune and Modern Device Management. My goal? To turn complex tech into actionable insights for a streamlined management experience. Let’s navigate this journey together!

    Support

    Awards

    Archives

    © Copyright 2009-2024 Eswar Koneti, All rights reserved.

    Type above and press Enter to search. Press Esc to cancel.