locked
Custom Entity/lookup issues RRS feed

  • Question

  • I am trying to deploy our CRM Solution and facing a problem.

    I set up a test environment:

     

    WS 2003 SBS. Updates and all patches applied.

    SQL Server 2000

    MS CRM 3.0 Updates an all patches applied.

     

    Exported the entities from our production environment and imported them into the deployment/test environment. Now, with a couple of the entities, everytime we try and click on it to open up the form we get a "Query Builder error. No Attribute found". What is this?

     

    Investigating further, seems like we have a couple of lookup fields on the forms that has this problem. And it does not seem to show the attribute that is a lookup field (like it doesnt exist). If we try to create a new attribute of the same datatype (lookup), we cannot see "lookup" in the dropdown list for the datatype.

     

    Any ideas whats going on?

    Monday, August 6, 2007 6:46 PM

Answers

  • I wouldn't call it a well-known problem. I know of it from over-exuberant and unsupported hacking of xml customisation files, but I know of one occasion where it appeared to have been caused when 2 people were independently adding attributes to and customising the form of the same entity
    Thursday, August 9, 2007 3:33 PM
    Moderator

All replies

  • ahmedilyas - This might sound very basic but did you publish those entities after you imported them? I ask because you speficially said you imported them but you didn't mention that you published them.

     

    Did you delete any attributes in this round of customizations? If so there may be a mapping to the deleted attribute still hanging around.

    Monday, August 6, 2007 8:27 PM
  •  

    Did you export them all at once, or did you do multiple separate exports ? If you did multiple exports/imports (or multiple publish) you might miss the relations between the entities?

     

    regards

    Jens Chr

    Monday, August 6, 2007 9:02 PM
  •  

    Thanks for the responses.

    Yes I did publish the entities after importing them.

    I am using 1 xml file which is created by MS CRM when I export all entities.

     

    Having wierd issues overall. I have set up 2 test environments and kind of having the same problems where the first time I try to import the entities, I get a "Either the file is could not be uploaded or import failed" errors, but then next time I try it I get a "SQL Server errors occured". I have to reboot the environments, then reselect the custom entities I want to import and hope for the best for it being imported

     

    I still have issues with the lookup field and with the "no attribute" error on both test environment. This is a very serious issue.

    Tuesday, August 7, 2007 2:36 AM
  • Did you also publish etc before exporting? Are the relations intact in the test env?

    regards

    jens chr

    Tuesday, August 7, 2007 11:18 AM
  •  

    Yes I did all that too. For some reason, it now seems to work after the 50th time trying. I don't know what made it work but I need to know as this isn't a good thing happening.

     

    Thing I need to create yet ANOTHER test environment and see whats going on but don't know where to look.

    Tuesday, August 7, 2007 12:07 PM
  • The problem is likely to be with the exported xml. In the xml file. Any CRM attribute should be referenced in 2 places in the xml file; there should be an <attribute> element that contains data-type and related information, and also a <field> element that has UI information. The error you are getting is consistent with only having the <atttribute> element.

     

    I fix this by editing the xml file and adding a relevant <field> element - you can get the syntax by from other attributes of the same type.

     

    As to how/why this occurs. The most likely cause is incorrect direct editing of the xml file, though I think it can can occur if 2 people had been making concurrent modifications to the entity or attribute via the CRM customisation interface

    Thursday, August 9, 2007 8:15 AM
    Moderator
  • This sounds a little scary, is it a known problem in CRM ?

    regards

    Jens Chr

    Thursday, August 9, 2007 3:08 PM
  • I wouldn't call it a well-known problem. I know of it from over-exuberant and unsupported hacking of xml customisation files, but I know of one occasion where it appeared to have been caused when 2 people were independently adding attributes to and customising the form of the same entity
    Thursday, August 9, 2007 3:33 PM
    Moderator
  • The lookup fields are created to represent relationships between two entities. If you exported and then reimported, it could be that the entity the lookup field was supposed to reference was either corrupt or missing at the time of your import. Check to make sure that all custom entities have been moved over to the virtual environment.

    Thursday, November 1, 2007 10:50 PM