I've added a field based on a formula and I've set the visibility to NO.
Then I've inserted a Format Trigger which returns TRUE if a condition is met.
If condition then return true else return false, but It always seems to be false and the field visibility remains NO.
Field Properties:
So when the flag is 6661 nothing is displayed neither for other value other than that.
When I tested with the flag set in database to other value than 128 it is correct nothing is displayed, but then I've change the flag to 128 still nothing appears Although value 1 or 2 should be displayed.
Thank you!
Related
I am trying to create a BPM that sends an email when a field is updated.
I have a condition checking if - The Field had been changed from 'any' to 'another'.
This works to fire off the email, but it also goes when the price in the sales order is initially created. How would I make it so that it only goes when the price is updated, but not originally set?
bpm image
By definition, a new record does not change from any to anything else. It's just a new record. So it's satisfying your condition block for false. If you had the logic reversed, you'd only get the email when the field were changed from something to something else... but never when a new record is created.
To handle this, you should add another condition block that checks for added rows. If that's false, point that to the existing condition block you have there for the field changing from any to another.
Add another condition as field RowMod = "U" for updated rows
Add a condition block after start that contains the following:
The Field had been changed from 0 to 'another'.
OR There is at least one added row in the OrderDtl table
Connect the false condition to your existing condition block. Remove your false condition connection and connect your true condition to the email. After that, the email will only be executed when the field is changed after being populated for the first time.
Resetting the price to zero will trigger an email, but the subsequent setting will not. If this is undesirablle, you can mitigate this by adding a UD field to track "first time populated", or enabling ChangeLog tracking and retraining to any undersirable behaviors.
In my report, i have created a xxx parameter which takes values from the report data set.
xxx parameter is not being passed to stored proc which is used to show the data for the report.
Now When the report does not have any data for other parameters, i get an error saying xxx parameter is missing a value.
I tried allowing blank values in the parameter properties.
Check that parameter's - Available Values by going to report parameters properties.
It must not be specified any values. So we should set it as None
Another way is,
Just add a blank space at Specify values - in Default values inside report parameters properties.
Third way
Ido an "if exists" statement for this to go away. It worked for me because it makes it always return a value even if that value is not need by my query.
if exists (my select query)
my select query
else
select '2'
// '2' would never be used, but it made ssrs stop giving me
// the stupid error and execute
This should help.
I created 4 reports all of them worked i have an expression in all to count rows:
=IIF(Fields!Logged30Days.Value = "yes", Count(Fields!Logged30Days.Value),0)
But today i see on all this is returning 0 when there are rows in the report it suddenly stops working how to fix this and why is it happening?
UPDATE
Now i see the expression are not working on any report, even on the earlier backup versions where they worked!
And if i do this it works but for all the rows just to show expression works ! but its not working as it did before above.How do i change this below to get desired result.
=IIF(Fields!Logged30Days.Value = "yes", count(Fields!Logged30Days.Value),count(Fields!Logged30Days.Value))
OK, it seems like all you need is the following expression:
=Sum(IIf(Fields!Logged30Days.Value = "yes", 1, 0)
All this is doing is counting the rows with a yes value for Logged30Days; it the value is not yes it's just ignored for the count.
In your case,
=IIF(Fields!Logged30Days.Value = "yes", Count(Fields!Logged30Days.Value),0)
is the same as:
=IIF(First(Fields!Logged30Days.Value) = "yes", Count(Fields!Logged30Days.Value),0)
i.e. when there is more than one row in the Scope but no aggregate specified it will just take the first row. So the expression was determined by the first row's value only. Also, when the first value was yes the Count would count all rows, even those where the value was not yes, which was also not quite what you were after either, I think.
Hi everyone I use Crystal Reports with Visual Studio 2010 and have the following issue that I can't seem to solve. I have a parameter called name, and I make it so a user chooses from a drop down list of employee names. It is an optional parameter so the user can select nothing in which case I would like the report to show ALL the employees except for the rows that have field Employee name empty. Now I think I got the second part of it down, because I put a formula in the detail section that seems to hide all the empty employees. The problem is that if I leave the parameter unselected the report ONLY shows rows with field Employee name empty. I created a formula like so:
if not (hasvalue(({?Zaduzioc}))) then True
else if
hasvalue({?Zaduzioc}) then
{Inventar_Model_ReportClass.ImeZaduzioca} in {?Zaduzioc} and
{Inventar_Model_ReportClass.Status} = "Aktivno"
Now this exact same formula works for me if I use it with a different report and parameter but that parameter has no empty values so I'm guessing it equates to something like if there are empty values show only those rows if not show everything.
The problem is I can't figure out how to tell it to show everything.
Any help would be greatly appreciated.
I managed to make it work, the problem was in the edit for the parameter I didn't set optional to true, overlooked it and as soon as I did that it all worked. So to recap for anyone with this problem: Make your parameter set optional to true, and put this in the formula for record selection:
if not (hasvalue(({?Parameter}))) then True
else if
hasvalue({?Parameter}) then
{table.column} in {?Parameter}
That should be that.
If you are selecting from a dropdown, you can add an item, Value = ALL, Description = ALL. Set your default to this value. Then in the Selection Expert, add this to your selection query:
....
AND
(IF {?Parameter} = 'ALL' THEN
{databasefield} = {databasefield}
ELSE
{databasefield} = {?Parameter})
I am creating a report in SSRS 2005 and where there should be a NULL value in the table it is returning a value ("Alle" [the tables are mostly in German]). This isn't really a problem as I think I can hide the value as explained here:
How to hide certain on SQL Reporting Services 2005
However, when I add =Replace(Fields!LengthofFunding.Value,"Alle","") to the Expression box in the field I want to hide the value for it is returning a FALSE value rather than a blank.
Can anyone let me know how I can make this field return a blank value?
I think instead of replace you can use the Iif as following:
=Iif(Fields!LengthofFunding.Value = "Alle", " " , Fields!LengthofFunding.Value )
This means if its equal to "Alle" replace with blank, else keep the original value.