+ Start a Discussion
MegachuckmcMegachuckmc 

Why is it so "bleeping" hard to find answers to simple questions in SF?

Sorry in advance for the venting :smileymad:
 
Trying to create a simple workflow rule to trigger an email alert - Pretty simple right? 
Wrong!
AND(ISPICKVAL( Type__c , "Shipment"), Promise_Date__c > TODAY(), Promise_Date__c <> 2009/09/09)
Error: Incorrect parameter for function <>(). Expected Date, received Number
 
No matter what format I put for the date I get this stupid message "Expected Date, received Number"
 
I've tried:
2009-09-09
09-09-2009
09,09,2009
2009,09,09
2009/09/09
09/09/2009
 
So I surround the dates in quotes:
 
"09/09/2009"
'09/09/2009'
 
Guess what!
Error: Incorrect parameter for function <>(). Expected Date, received Text
 
Tried searching in the Help section
Dates, Date formats, date formats in formulas, etc.
No help at all!
 
Tried searching on all of the different Successforce boards
Guess what!  I'm the only person that has ever received this message because it doesn't exist anywhere on any of the sites!
I did find one reference to: Expected DateTime, received Number
But that was of no help because my issue is not with Date vs. DateTime
 
So back to subject of my message... Why is it so hard to find answers to simple questions...?
 
I'm praying that it was right under my nose all of the time but I was just too tired to see it.  But until then :smileymad:
 
 
JohanLiljegrenJohanLiljegren
Totally agree!
I've experienced the issue with finding more Admin/Developer type answers from the Help & Training section in SFDC.
For example, I gave up trying to find such a simple thing as how many Custom Report Types are allowed in Enterprise Edition. I ended up calling support for an answer...
Andrea LeszekAndrea Leszek
Sorry you found the Help & Training search so frustrating. We're constantly working to index the content and tune the search engine to improve the experience. Your feedback is helpful.
 
Megachuckmc - This FAQ is a good one about date formats and describes how your Locale setting affects what date format to use, although it doesn't directly answer your question. I think the problem lies with the Not equal operator <>. If you look at the documentation  for it, it says that it evaluates expressions, whereas I think what you're entering is a literal. I found that something like this works: Promise_Date__c <> DATEVALUE("2/4/2008"). My Locale is English (United States) so I'm entering February 4, 2008 as 2/4/2008.
 
JohanLiljegren - A good help topic to know about is "App Setup Limits," which lists limits by edition for many different features such as custom report types, workflow, custom objects, etc.
 
 
JohanLiljegrenJohanLiljegren
Andrea,

Thanks for the feedback.

Your (i.e. Salesforce's) use of "know this specific keyword" approach is probably what conflicts the most with how I search for things.
To find the page you suggested I'd probably put in something like "max fields enterprise edition" or something along those lines, which gives me... well, nothing valuable...
Maybe it's me who need to adjust my internal search phrase generator? ;)
seandnzseandnz

I am new but this may help, it is to do with data types, you are choosing one value from a picklist i.e text and one value from a date range the rule is that the data types have to be the same.  Try putting your date parameter in separate brackets, here is my query that I use to get the same error message as you, but not any more.

AND (
ISPICKVAL( Policy_Status__c , "In Force"),
ISNULL( Start_Date__c ))

I hope this helps and instead of ISNULL I am guessing you will be setting the parameter as DATEVALUE or something along this line...good luck!

 

SEAN.

drewalexander.ax421drewalexander.ax421

To create a formula that evaluates a date or date/time field against a specific date, try an expression like this:

 

For Date/Time field vs. specific date:

DATEVALUE(CreatedDate)>=DATEVALUE("2010-04-19"))

 

For Date field vs. specific date:

Date__c>=DATEVALUE("2010-04-19")

 

In your example, I would try:

 

AND(ISPICKVAL( Type__c , "Shipment"), Promise_Date__c > TODAY(), Promise_Date__c <> DATEVALUE("2009-09-09"))

 

Best,

 

Drew Alexander

Manager, Customer Success Strategy & Operations

salesforce.com