-1

Can you guyz help me to query for all the opportunities that are in between stages 0-5 and has closed date Greater than today.

Thanks

closed as off-topic by jkraybill, crmprogdev, Chris Duncombe, Mohith Shrivastava, Boris Bachovski May 29 '15 at 5:52

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "Questions on problems in code you've written must describe the specific problem and include valid code to reproduce it. For help writing short, self-contained syntactically-valid examples, see: SSCCE.org" – jkraybill, crmprogdev, Chris Duncombe, Mohith Shrivastava, Boris Bachovski
If this question can be reworded to fit the rules in the help center, please edit the question.

  • 2
    Ravi -- as a matter of etiquette on this community; showing effort on your part is appreciated rather than just asking folks to 'do the work for you' – cropredy May 28 '15 at 21:52
3

What did you mean by between stages 0-5? The following just uses the standard first 5 stages, if you meant other values just edit the conditions:

[SELECT StageName, CloseDate FROM Opportunity WHERE (StageName = 'Prospecting' OR StageName = 'Qualification' OR StageName = 'Needs Analysis' OR StageName = 'Value Proposition' OR StageName = 'Id. Decision Makers') AND CloseDate > TODAY];
  • I meant stages of an oppurtunity like prospect, and so on – Ravi May 28 '15 at 16:31
  • Then you should be fine, like I said I just used the standard first 5 stages – Brian Mansfield May 28 '15 at 16:32

Not the answer you're looking for? Browse other questions tagged or ask your own question.