locked
Search Records in CRM 2011 RRS feed

  • Question

  • Hi,

    I am using CRM 2011. i have created a custom security role for the sales team. and Lead entity has user owned key value.when,sales user having role "custom security role" trying to search a record for lead using search bar, then it will search with only those record for which they have the right to access it. but i want to search the value with all the records within the database.

    Please suggest me, how i can achieve this.

    Thanks!!!


    Make sure to "Vote as Helpful" and "Mark As Answer",if you get answer of your question.

    Monday, April 14, 2014 10:04 AM

All replies

  • The default search functionality will search for all records that the user has access to.

    There is no way to change that default functionality.

    Therefore I dont understand your request. You want to limit the users to which records they are the owner of, but they should be able to search for all records?

    This cant be accomplished without giving them access to the full entity records..


    Rune Daub Senior Consultant - Dynateam CRM http://www.dynateam.dk

    Monday, April 14, 2014 10:10 AM
  • Thanks for the reply RuneDaub.

    When Sales user going to create a new Lead record, before that i want to check that kind of lead record is already exist (Created by someone else) or not. right now sales guy entering duplicate records.

    This is my issue.



    Make sure to "Vote as Helpful" and "Mark As Answer",if you get answer of your question.

    Monday, April 14, 2014 10:25 AM
  • OK.. so what you will want to do.. is limit their access rights to the records.. Then you cant do this based on the user context.

    But you can create a plugin that runs on create of the lead record and have that record run in the context of a specific system user, that can see all Leads.

    Then that plugin can test for duplicates.


    Rune Daub Senior Consultant - Dynateam CRM http://www.dynateam.dk

    Monday, April 14, 2014 11:18 AM
  • There are no OOB way to do what you want... Only custom plugin.

    Rune Daub Senior Consultant - Dynateam CRM http://www.dynateam.dk

    Monday, April 14, 2014 11:19 AM
  • Hi Kamal,

    have you tried using duplicate detection? following article is for CRM 4 but applies to CRM 2011 as well..

    http://blogs.msdn.com/b/crm/archive/2007/11/20/duplicate-detection-rules-defined.aspx

    with this open you can set up your rules and id user tries to create duplicate record they will be prompted with information from existing record..

    one other way to do it using plug in 

    a. write plug in on retrivemultiple to retrieve more or less data as per your requirement

    b. write plug in on pre-create (or pre validation) stage to validate data and if it is duplicate the throw error from plug in with relevant error message.


    MayankP
    My Blog
    Follow Me on Twitter

    Monday, April 14, 2014 11:29 AM
    Answerer
  • Thanks Rune and Mayank for the reply. 

    Plugin or Duplicate detection rules works when i going to save the record.But here i have around 12 mandatory field in lead, so it is not the right way to enter 12 field values and if is shows duplicate then discard the changes. That means waste of efforts.

    That is why i want to search the record on change of like "Name" field, so it will compare it with all existing lead names, if it's find the matching record then OK.


    Make sure to "Vote as Helpful" and "Mark As Answer",if you get answer of your question.

    Monday, April 14, 2014 12:02 PM
  • you can also implement Java script on client side which should run on change of Name event..

    so as soon as user enter name relevant java script should query CRM and if duplicated found prompt user with this information.

    this way it is really instant and user will get result as soon as they come out of name field in Lead form.


    MayankP
    My Blog
    Follow Me on Twitter

    Monday, April 14, 2014 4:54 PM
    Answerer