Select Query Error In "Find" Function

Hi,

We have set all words "Opportunity" into "Quotation" in CRM's Translations.

The problem happened when we are trying to find a quotation (opportunity) by using "Find" function in the user screen. After we selected "Quotation" (translated from Opportunity) from the finder list, and typed the keyword of the quotation, then we pressed "Find" button to start searching. An error message immediately showed up:

An unexpected event has occurred: SQL Code: 208
Exception: SQL Error

After we checked in the ewaresql log file, we found out that the cause is:

select * from Quotation WITH (NOLOCK) where Oppo_OpportunityId = 118 Invalid object name 'Quotation'

We are confused with the select query from "Quotation" table, which doesn't exist in the CRM database.

Is there anyone can help us on this problem? Is it caused by translation?

  • 0

    David

    Translations are used through out the system to dynamically control the generation of string values based on the currentuser. Most of the usage of translations are obvious because this controls the captions in the User Interface. BUT some of the usage is behind the scenes and as you have discovered controls the generation of the SQL that is sent from CRM to the database.

    For example see this article

    community.sagecrm.com/.../how-do-i-add-the-id-from-a-custom-table-table-as-an-search-select-advanced.aspx

    In this article I discuss setting up the translations for a search select advanced field against a new custom entity.

    family=SS_Entities, code='Vacancy', capt_us='Vacancy'

    family=SS_SearchTables, code='Vacancy', capt_us='vVacancy'

    family=SS_ViewFields, code='Vacancy', capt_us='Vaca_Description'

    family=SS_IdFields, code='Vacancy', capt_us='Vaca_VacancyId'

    You can see that the SS_SearchTables translation e.g. capt_us includes the view (or table) that is to be used.

    I think you need to restore the translations to what they originally were and start again changing the captions to what you need.

  • 0

    Hi Jeff,

    Thank you for the suggested solution. We will try your suggestion.

    Regards,

    David.

  • 0

    Hi Jeff,

    we found the problem. It's because of the "SS_SearchTables" family has been changed. After we amended the value, the "Find" function can work properly again.

    Thanks a lot.