• Neetu Bansal
  • NEWBIE
  • 70 Points
  • Member since 2013

  • Chatter
    Feed
  • 1
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 0
    Questions
  • 6
    Replies

 

I am not getting the correct way putting date in below SOQL statement 

 

SELECT id, CreatedDate  FROM Sales_Order__c where CreatedDate < 2013-01-11

 

could some one help please 

 

Thanks 

 

error :

INVALID_FIELD:
recordtype__c FROM Sales_Order__c where CreatedDate < 2013-01-11
^
ERROR at Row:1:Column:877
value of filter criterion for field 'CreatedDate' must be of type dateTime and should not be enclosed in quotes

  • May 20, 2013
  • Like
  • 0

I'm new to development and I've written a trigger to update the Account with a field when a) the field is blank and b) a Contact is created or updated and contains a value in a corresponding field.  The idea being to maintain the data in two places.  However, I'm getting an exception which references "kugadd" which I assume is from the Kugamon package we have installed.  Can anyone help?

 

Here is my trigger:

 

trigger OnAccountContactCategory on Contact (before insert, before update) {

    List<Id> AccountsToUpdate = new List<Id>{}; 
    // Find account to update
    for(Contact c: Trigger.new){
        if (c.Categorycontact__c != Null && c.AccountId != Null)  {
              AccountsToUpdate.add(c.AccountId);
        }
        // Pull field data from account
      List<Account> accts = new List<Account>([SELECT Id, Category__c FROM Account WHERE Id IN :AccountsToUpdate]);
        // Update account    
      for(Account a: accts) {
         if (a.Category__c == Null) {
                a.Category__c = c.Categorycontact__c;
              update a;
         }
      }
   }
}

 

Here is the emailed exception (I removed the IDs themselves):

 

 

OnAccountContactCategory: execution of BeforeUpdate

caused by: System.DmlException: Update failed. First exception on row 0 with id [ACCOUNT ID]; first error: CANNOT_INSERT_UPDATE_ACTIVATE_ENTITY, kugadd.AccountAfterInsertAfterUpdate: execution of AfterUpdate

caused by: System.DmlException: Update failed. First exception on row 0 with id [CONTACT ID]; first error: SELF_REFERENCE_FROM_TRIGGER, Object (id = [CONTACT ID]) is currently in trigger OnAccountContactCategory, therefore it cannot recursively update itself: []

(kugadd)
: []

Trigger.OnAccountContactCategory: line 15, column 1

 

Thoughts?  Thanks!

Need to delete all contact with no case attached to it and created before 12/31/12 How Can i do that non programmatically or programatically

  • May 20, 2013
  • Like
  • 0

 

I am not getting the correct way putting date in below SOQL statement 

 

SELECT id, CreatedDate  FROM Sales_Order__c where CreatedDate < 2013-01-11

 

could some one help please 

 

Thanks 

 

error :

INVALID_FIELD:
recordtype__c FROM Sales_Order__c where CreatedDate < 2013-01-11
^
ERROR at Row:1:Column:877
value of filter criterion for field 'CreatedDate' must be of type dateTime and should not be enclosed in quotes

  • May 20, 2013
  • Like
  • 0

Job Applications is a custom object with a lookup relationship to the custom object Positions, A

developer would like to modify the Position fields displayed in the console mini view when a job

application record is viewed in the console detail view. What would a developer customize to

accomplish this?

 

A. the mini page layout of the position page layout

B. the related objects on the job application page layout

C. the related objects on the position page layout

D. the mini page layout on the job aplication layout

 

A developer wants to build an application on force.com platform. The data model that the users need access to applications, and the application business logic have been considered. The report and dashboard requirements have not been considered, which is true?

 

A. Data model may not be support the business logic

B. Dashboard may not be visible to management users

C. Developer will not be able to load data

D. Data model may not support the required reports

 


CreatedDate is a Date/time data type field.


What formula returns the number of days since the record was created?

 

A. TODAY() - DATEVALUE(CreatedDate)

B. CreatedDate - TODAY()

C. TODAY() - (CreatedDate)

D. NOW() - DATEVALUE(CreateDate)


When performing or updating with Data Loader, the comma delimited file must contain a column with what values?

 

A. Logical names of records

B. Profile names of record owners

C. Force.com Record IDs and Value of Record

D. Created time and date of records


A developer needs to support multiple currencies for a custom object in an application? Multi-currency has been enabled, what does the developer need to know to support the application?

(2 answers)

 

A. Must input currency ISO Field

B. Admin can add additional currencies once set up

C. Roll up summary fields will calculate incorrectly if children have multiple currencies

D. Track Currency changes automatically.


Job Applications is a custom object with a lookup relationship to the custom object Positions.

A developer would like to modify the Position fields displayed in the console mini view when a job application record is viewed in the console detail view.

What would a developer customize to accomplish this?

 

A. The mini page layout of the position page layout

B. The mini page layout on the Job application page layout

C. The related objects on the job application page layout

D. The related objects on the position page layouts