search cancel

Trying to create a new subfolder in ITCM Explorer Queries Folder, click OK in Create New Folder dialog, the dialog is prompted again and no folder is created.

book

Article ID: 215906

calendar_today

Updated On:

Products

CA Client Automation - IT Client Manager

Issue/Introduction

Trying to create a new subfolder in ITCM Explorer Queries Folder, click OK in Create New Folder dialog, the dialog is prompted again and no folder is created.

Logs Shows: 

TRC_AMMGR.log

130521-10:23:20.5036210L|012308|00002a88|AMManager |CDb             |CDb.cpp             |000374|DETAIL | Execute SQL command
130521-10:23:20.5036729L|012308|00002a88|AMManager |CDb             |DbImpl_Ado.cpp      |000649|INFO   | CDb_Ado::ExecSQL() enter - INSERT INTO am_object_folder (folder_domain_id,folder_id,folder_name,object_type,folder_parent_id,folder_filter,folder_id_type) VALUES (1432887161,8,'prueba',13,0,0,1)
130521-10:23:20.5071941L|012308|00002a88|AMManager |DbImpl_Ado      |DbImpl_Ado.cpp      |002311|NOTIFY | evalSQLInfo sqlstate: 01000 native error: 3621 0xe25
130521-10:23:20.5072342L|012308|00002a88|AMManager |DbImplAdo       |DbImpl_Ado.cpp      |002345|NOTIFY | evalSQLInfo description: The statement has been terminated. source: Microsoft SQL Server Native Client 11.0
130521-10:23:20.5073393L|012308|00002a88|AMManager |DbImplAdo       |DbImpl_Ado.cpp      |002358|NOTIFY | evalSQLInfo class: 0 state: 1 server: GPT-DMI-02\DMG
130521-10:23:20.5074004L|012308|00002a88|AMManager |DbImpl_Ado      |DbImpl_Ado.cpp      |002311|NOTIFY | evalSQLInfo sqlstate: 23000 native error: 2627 0xa43
130521-10:23:20.5074288L|012308|00002a88|AMManager |DbImplAdo       |DbImpl_Ado.cpp      |002345|NOTIFY | evalSQLInfo description: Violation of PRIMARY KEY constraint 'XPKam_object_folder'. Cannot insert duplicate key in object 'dbo.am_object_folder'. The duplicate key value is (1432887161, 8). source: Microsoft SQL Server Native Client 11.0
130521-10:23:20.5074552L|012308|00002a88|AMManager |DbImplAdo       |DbImpl_Ado.cpp      |002358|NOTIFY | evalSQLInfo class: 14 state: 1 server: GPT-DMI-02\DMG
130521-10:23:20.5075412L|012308|00002a88|AMManager |CDb             |DbImpl_Ado.cpp      |002644|NOTIFY | Error Message: ADO Version 10.0 - COM Error: ErrorCode:-2147217873,WordErrorCode:3119, IDispatch error #3119, Violation of PRIMARY KEY constraint 'XPKam_object_folder'. Cannot insert duplicate key in object 'dbo.am_object_folder'. The duplicate key value is (1432887161, 8)., Microsoft SQL Server Native Client 11.0, (null)
130521-10:23:20.5121969L|012308|00002a88|AMManager |amLog           |                    |000000|INFO   | UnUsed Pool Size is 2 less than the Max pool Size 5

Environment

Release : 1403

Component : DESKTOP MANAGEMENT SUITE

Resolution

Problem is due to  folder_id in table ncprofil (profilid=255) has been reset.

1. Take full backup of MDB first . 

2. Stop the Caf: Caf stop

3. Login to SQL using Administrator user and execute below command. 

 SQL Query to set the correct value for counter folder_id in table ncprofil :

Execute Below Query Against MDB. 


UPDATE ncprofil
SET profilln=(select max(folder_id) from am_object_folder where folder_domain_id=(select domain_id from ca_n_tier where domain_uuid=(select set_val_uuid from ca_settings where set_id=1)))
WHERE profilid=255

4. Caf start . 
5. Now open explorer and try to create folder under queries .