How to check if filefield has a value or not by Rules I have a cck file field "pic" users can attach up to 3 images to. I would like to set a Rule with the condition depending on whether user has uploaded at least one image or not. 

I set the condition "Saved content's field 'field_pic' has value" + "negate"  But no matter the field has a value or not (a file has been attached or not) the debug says "Condition "Updated content's field 'field_pic' has value" evaluated to FALSE."

I also tried this code below but again always the condition is FALSE.

return array(
  0 =&gt; array('fid' =&gt; 0, ),
);


How can I set the condition to check if the cck file field has at least one file or not?
I believe that "has value" needs to return TRUE or FALSE. You need to do the assessment yourself, because the value that it should have might not necessarily be a one or a zero (I would use this rule if I wanted to evaluate if a field has the value of 5, say: If yes, return true.)

You can either put in a value in the text input (5) which it will match for you and return true/false, or you can use PHP to evaluate it and return true or false yourself.