Crystal Reports - Displaying customer records who have not bought - crystal-reports-xi

amazing experts.
I am still very new to Crystal, and only do it on the odd occasion, and seem to be going around in circles with this issue.
I work for a charity, and we would like to pull off a list of all our past donors who have not donated anything on the last 6 months.
I have tables for customer details, linked to another tables which shows their orders. They are linked based on the unique customer ID.
I have added all the customer orders, grouped by customer ID and then sported by OrderDate, and now I get stuck.
In my mind, I need to exclude anyone who has an order date that is less than 6 months old, and to do so I have tried using
{OrderDate} <= DateAdd ("m", -6, CurrentDate).
This however only seems to remove the customer orders that are less than 6 months old, not remove the customer records themselves.
I have tried using it both the "Select Expert" and also to suppress in the "Section Expert", but neither seem to be working to exclude the relevant Customer records.
I am certain there is a super easy way to do this, and I will kick myself when I know how to do it, but right now I have gone round the houses trying to find the solution.
So, if anyone out there has done this before and can help me out, i would greatly appreciate it.
Thank you all for your time!

this might solve your problem.
create a running summary field to count the number of rows return per group. if it is zero under the group section, under suppress , edit formula at put > 0
and run the report.

Related

I'm stuck on how to "match" 2 columns of date and time in Google Sheets

first timer here.
I've been stuck on creating a formula to calculate how many "leads" were created and modified on the same day with the "B2C Lead Name" being a name. I've redacted some numbers and names for obvious reason.
As you can see, row 8 and 9 for both column B and D fall on the same date. And B2C Lead Name is "Boom." On the top right corner, I've tried multiple ways I could think of to count the instances where the lead was created on Aug 30 and was also modified on Aug 30 while the Lead Name is Boom, but I haven't managed to have it work when at least my formula should've shown 3.
For context, I'm creating a report for my sales team and I've been stuck on this thing for 3 weeks, so any help on this would be extremely appreciated. And if it's not too much to ask, please also school me on why using DATEVALUE and trying to "match" those time and date columns as a criterion doesn't work?
Please let me know if you need any more details on this. Thank you!
Here's what I've been staring at for the past 3 weeks, among countless others: =ARRAYFORMULA(COUNTUNIQUEIFS(NMZHImport!$A:$A,NMZHImport!$G:$G,"*"&U30&"*",DATEVALUE(NMZHImport!$B:$B),"="&DATEVALUE(NMZHImport!$D:$D),NMZHImport!$N:$N,"<>Appointment Confirmation"))
Sheet
Please see my comment to your original post.
That said, given the data as I see it, try this untested formula:
=COUNTA(IFERROR(FILTER(A8:A, INT(B8:B)=DATEVALUE("8/30/2022"), INT(B8:B)=INT(D8:D), E8:E="Boom")))
FILTER will form a virtual array of only those entries in A8:A where the day-only date (obtained by INT) in B8:B is equal to your target date, where that date is also equal to the value in D8:D, and where the value in E8:E is "Boom".
IFERROR( ) will return null if there are no matches (which would otherwise be an error).
COUNTA will count the filtered list (if any).
If this does not work as expected, follow my suggestion in the comment I left to your original post and share a link to your sample data in a spreadsheet.

The data in my Google Sheet is not appearing in the correct cell

I am trying to create a spreadsheet to simplify our account returns. I am using a variety of named ranges to make life easier. I have created a test sheet which automatically copies the inputted cost to its appropriate category.
I am having a strange issue where the cell I am expecting to see the data in is incorrect. I am wondering if the 2 data validation lists I have created could be causing the issue. I had originally copy / pasted from an old sheet but as I wondered if some strange formatting may have been carried over which is causing the issue I have since manually entered all data to remove this as a potential cause.
https://docs.google.com/spreadsheets/d/1KC8FsVNQZfWtey5TvPDxCxvDhRrFVHdsbDJWmZu73wg/edit#gid=0
This is the test sheet in question. The cost for entries Test 9 & Test 10 should be in the Info Books and Stationary sections retrospectively but they are ending up in the wrong places.
I am not a spreadsheet expert so I apologise if I am missing something blatently obvious. A friend advised me to ask on Stackoverflow after many hours lost to this problem.
Thanks in advance for any help you may be able to give.
Use the third parameter in vlookup set to false (or zero)
=IF(VLOOKUP(companyOfPurchase,suppliersAndCategories,2, 0) = typeOfPurchase,totalOfReceipt,"")
and see if that works?

"Relationship may be needed" although relationship is set

I have two simple table in Excel 2010 - Products and Sales:
I then linked them into PowerPivot - and here created the relationship from Sales.ProductId to Products.Id - like this:
Now I'm trying to build a Pivot that for each productId in the Sales table also shows me the Category and the PurchasePrice from the ProductTable. However, here I'm stuck - because the relationship is somehow faulty. When configuring the Pivot, I get a message Relationship may be needed even if the relationship already exists. The resulting - wrong - pivot table looks like this:
though I'm actually trying to achieve this:
I know that I could create calculated columns in the Sales table of PowerPivot and pull all required data using the RELATED DAX function - but as the real world project requires a lot of joins and fields I'm hoping that there's a better solution than this workaround...
I uploaded the example file here.
Peter,
Your question was a bit more tricky than I first though and I spent quite some time digging around, but I think I found the solution after reading this article about making distinct count in related tables.
I have updated your source file (so that Sales table contains more than 1 sales per product) and uploaded it to my public Dropbox folder.
You can see that I created 4 new calculated measures to illustrate my solution and to make it a bit easier to understand (Excel 2010 terminology, in 2013 it's Calculated Field):
Sales Price Total
=SUM(Sales[SalesPrice])
Products Sold
=COUNT(Sales[ProductId])
Purchase Price per Item
=CALCULATE(SUM(Products[PurchasePrice]),Sales)
Purchase Price Total
=[Purchase Price per Item] * [Product Sold]
The key difference here is the formula for calculating purchase price per item. The reason why you should SUM the product purchase price within CALCULATE function is explained in great detail in the linked article (even though in a bit different context):
In this way, any filter active on Sales (the related table) propagates
to the lookup table.
There might be some other parts I missed, but I have tried this in couple other examples and it simply works as it should:

Find WorkItems that were assigned to X in the last 30 days

I'm trying to find all WorkItems that were assigned to a person X in the last 30 days.
The big problem I have is the "in the last 30 days"-part.
I thought about using the "ever" or "asof" keywords, but couldn't find a good answer yet.. something like WHERE [Assigned To] = 'X' AND (([Assigned To] != 'X') asof '<30daysago>').
But this is still not a bulletproof solution.
Any better ideas?
Thanks & kind regards
Simon
It appears that this is not possible using just WIQL, but you can get close.
The keyword #Today will give you today's date, then just subtract your range from it. The EVER keyword applied to [Status]='AssignedTo' and a comparison against a date 30 days in the past to [StateChangeDate] is what you'll need to accomplish this.
As close as you can get with WIQL and existing fields:
This says, from all revisions (status changes) return records where the user 'X' has ever been AssignedTo and the State has changed in the last 30 days. This will basically give you a slightly fuzzy picture of what your User has been working on in the last month.
WHERE [Microsoft.VSTS.Common.StateChangeDate] >= #today - 30
AND [System.AssignedTo] EVER 'Bennett Aaron'
ORDER BY [System.State]
Add the missing field:
You could add a custom field called AssignedDate that is captured during the New->AssignedTo workflow transition that you create in the Work Item Definition XML. You can accomplish this using the Team Foundation Server Power Tools extension to Visual Studio. This would give you exactly what you need as well as additional reporting options going forward.
TFS API
I cannot help you with this one, but I believe you could query using the TFS API.
A couple of quick gotchas I've experienced to save you time on ASOF and EVER:
AsOf won't help you by itself with this as it does not support a range of dates. It allows you to query as if it were another date. In other words, if you forgot to capture the results of a query yesterday, you can use an AsOf query to get the results that you would have gotten had it run yesterday. What I understand is that you want to query a basic date range.
EVER might not work as you expect against dates as I believe it uses the exact value of the field (timestamp portion of the date field would be included) it tests with. Just make sure the EVER keyword is used against the status field rather than a date.

In TFS how do I pull all the items that were assigned to me between certain dates in the past?

I am trying to figure out the way to pull all the items that were on my plate between certain dates. Is this possible? Could you please help me to figure out how to write a query for that? Thanks.
The best that I know how to do is to set 'Assigned To' Was Ever #Me, then manually scan the list of work items returned (setting other fields as necessary to filter the results). In the UI, at least, there isn't a way to query on historical data.
You can do this via query window as well, below is my query that i use to see what have i been working on in the past two sprints.
This will give you any tickets you worked on regardless of who they are currently assigned to (system test / uat or whatever).
You can add more clauses and have Changed Date > xxx AND ChangedDate < xxx to find what you are looking for in any given dates.

Resources