1

Show Data for the most recent full week

I thought this was going to be easy (and maybe it is).

 

I am working on creating a Pyramid usage dashboard. Part of that is looking at user logins. I have a Discover that shows the total number of logins per user each week. 

 

What I am trying to do is by default have the Discover display the most recent full week.  This is week 26 so I want the Discover to default to week 25. 

 

Is this possible? Does anyone have any ideas on how to do this?

7 replies

null
    • VP Product Management
    • Ian_Macdonald
    • 5 days ago
    • Reported - view

    Hi 

    Easiest way is to use dynamic lists.

    Create a list of all the Year Weeks:

    Then filter for the Last 2:

    Then filter for the First 1:

    Then use this list in your Discover:

    Now, strictly speaking, this isn't the most recent complete week. For that you would have to check each week going backwards to find the first one with 7 date members associated with it. But I think this should give you what you want.

    Hope that helps.

    Ian

    • Ray_Buechler
    • 5 days ago
    • Reported - view

    Thanks Ian!

     

    How are you sorting the week numbers? Since it is alphanumeric the sorting is off.

    • VP Product Management
    • Ian_Macdonald
    • 5 days ago
    • Reported - view

    The Week Year sort is defined in he model and gives the correct sequence, so no sorting is required:

    Ian

      • Ray_Buechler
      • 5 days ago
      • Reported - view

       

       

      Thanks....it took me a few minutes to sort this out (no pun intended).

       

      I am using the server_logs_audit, and content_tbl_user tables in my data model to look at who and how frequently our users are logging into Pyramid. There is no week-year column (that is sorted correctly) like there is in the transactionView table.  I am using Full Week from Time Intelligence to get the year and the week and that is not sorting in the correct order.

      • VP Product Management
      • Ian_Macdonald
      • 5 days ago
      • Reported - view

       

      In your model, sort the Year Weeks by the Week Start Date column from Time Intelligence;

    • VP Product Management
    • Ian_Macdonald
    • 5 days ago
    • Reported - view

    BTW... Outside of the Pyramid Usage model shipped with the product, any access to the Repository tables are not supported. Thus there is the potential that should the repository schema change between releases, your model may fail.

      • Ray_Buechler
      • 4 days ago
      • Reported - view

       Thanks for the assistance on this. We're an OLAP shop so I do not spend a lot of time working with Pyramid data models.

       

      Understood that my data model might fail if the repository schema changes.

Content aside

  • Status Answered
  • 1 Likes
  • 4 days agoLast active
  • 7Replies
  • 37Views
  • 2 Following