Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

CRM 2011 getting Generic SQL Error when importing a new web resource.

(0) ShareShare
ReportReport
Posted on by

Hi All,

I am getting Generic SQL Error when importing a new webresource from one environment to another.

My Error Log says:

Error: <Data ss:Type="String">Cannot insert the value NULL into column 'IsManaged', table '********_MSCRM.dbo.WebResourceBase'; column does not allow nulls. INSERT fails.

I have also tried to create a new webresource in target environment but still getting the same error. I am able to create a new entity and workflow in target environment without any issue. 

Please help.

*This post is locked for comments

  • Community Member Profile Picture
    on at
    RE: CRM 2011 getting Generic SQL Error when importing a new web resource.

    Hi Guys,

    i have checked the database and found no issue in webresource table. On tracing the error i found below error.

    Cannot insert duplicate key exception when executing non-query:

    insert into [WebResourceBase]([OverwriteTime], [OrganizationId], [DisplayName], [Description], [SolutionId], [ModifiedOnBehalfBy], [CreatedOnBehalfBy],

    [Content], [IsManaged], [LanguageCode], [WebResourceType], [CreatedOn], [ComponentState], [ModifiedBy],

    [WebResourceId],

    [ModifiedOn],

    [Name],

    [CreatedBy]

    )

    values

    ('01/01/1900 00:00:00', 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx', NULL, NULL, 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx', 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx',

    'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx', NULL, 0, 1033, 3, '08/02/2018 05:51:28', 0, 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx',

    'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx',

    '08/02/2018 05:51:28',

    'new_test11.js',

    'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx')

    Exception: System.Data.SqlClient.SqlException (0x80131904)

    : Cannot insert the value NULL into column 'WebResourceIdUnique', table '********_MSCRM.dbo.WebResourceBase'; column does not allow nulls. INSERT fails.

    Since WebResourceIdUnique field is an internal field i am unable to figure out how to proceed. Any help would be appreciated.

  • Community Member Profile Picture
    on at
    RE: CRM 2011 getting Generic SQL Error when importing a new web resource.

    Hi David,

    Thank for your response.

    I have already checked the CRM versions of each environment and both DB and CRM versions are same on both environment. My core issue is target environment is not allowing me to create a webresource.

    Regards,

    Saad

  • David Jennaway Profile Picture
    14,065 on at
    RE: CRM 2011 getting Generic SQL Error when importing a new web resource.

    I suggest you check the organisation versions of each environment (you can see this in Deployment Manager), and if there is an option to update the organisation version, then do so. This is because there may be a mismatch in the organisation and CRM versions in each environment

  • Community Member Profile Picture
    on at
    RE: CRM 2011 getting Generic SQL Error when importing a new web resource.

    Hi Adrian,

    Thanks for your response. I don't have access to target environment database but i have asked the responsible team to look in to the same.

    I have already tried creating a webresource manually in target environment but it throws the same exception.

  • Suggested answer
    Adrian Begovich Profile Picture
    1,025 Super User 2025 Season 1 on at
    RE: CRM 2011 getting Generic SQL Error when importing a new web resource.

    Hi Mohd Saad Akhtar,

    The WebResourceBase table is the area where web resources are stored in the database. If you have access to the SQL database it is worth checking this table for anything unusual. If this table is fine, then there could be a problem with the web resources. You might need to recreate the web resources in the target instance manually as a workaround.

  • Community Member Profile Picture
    on at
    RE: CRM 2011 getting Generic SQL Error when importing a new web resource.

    Anyone??

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

🌸 Community Spring Festival 2025 Challenge Winners! 🌸

Congratulations to all our community participants!

Adis Hodzic – Community Spotlight

We are honored to recognize Adis Hodzic as our May 2025 Community…

Leaderboard > Microsoft Dynamics CRM (Archived)

#1
Mohamed Amine Mahmoudi Profile Picture

Mohamed Amine Mahmoudi 83 Super User 2025 Season 1

#2
Community Member Profile Picture

Community Member 52

#3
Victor Onyebuchi Profile Picture

Victor Onyebuchi 6

Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans