Unable to change the Product Type


You are an Administrator of ResourceOne and are changing a Product's Type. When you click on a product to edit it for performing this change, just a blank screen is seen.



The most likely causes of the issue are incorrect values in the database, or a table missing from the database.

If you want to proceed with the queries mentioned in the following section, please make sure you back up your entire database, and more precisely, the following tables which can be found in the BANK DB:
- Products

Once you execute the queries listed below, the data will be lost and will be unrecoverable. You can use the method described in the Backing Up Tables for Security KB Article for this purpose.


Input information

  • Which product needs to be updated (Product_Name)
  • The target product type that should be allocated to the product (Target_Product_Type)


Query to execute

To solve this problem, make sure you execute the following process:

  1. Get the details (original product_type_id) of the product that needs to be changed:
    select * 
    from <BANK_DB>..Products
    where Product_Name = '<Product_Name>'
  2. Display all the product types to get the target product_type_id:
    select * 
    from [CTAdmin]..Product_Types
  3. Display selected product types based on the current product type assigned to the product that needs to be changed and the product type that should be assigned:
    select *
    from [CTAdmin]..Product_Types
    where product_type_id =
    select product_type_id 
    from <BANK_DB>.dbo.Products
    where Product_Name = '<Product_Name>'
  4. Displays information of the product to compare the values with the target product types:
    select * 
    from <BANK_DB>.dbo.Products
    where Product_Name = '<Product_Name>' or product_type_id in
    select product_type_id
    from [CTAdmin]..Product_Types
    where type_name = '<Target_Product_Type>'
    Note the common attributes (Generic, Is_Service, Integrated, Active) of the target product_type_id
  5. Create a backup:
    select * 
    into Products_<BK_Todays_date_yyyymmdd>
    from <BANK_DB>.dbo.Products
  6. Replace the Product_Type_ID with the target Product_Type_ID by updating the product accordingly:
     update Products 
    set Product_Type_ID = '<Target_Product_Type>',
    Is_Service = 1 ---(optional, if applicable, refer Note below)
    where Product_Name = '<Product_Name>'
    Add the line to select (= 1) or deselect ( = 0) the identified attributes from Step 5 above


If there is a problem with the Update task, Investigate the problem and:

    1. Inform the customer about the problem identified
    2. Escalate the problem to Professional Services
      1. Inform the customer once the problem has been fixed by the PS



Contacting Support

If you want support to execute this backend modification on your behalf, please contact the Support staff and provide them with the information described in the Input information section.  A customer support representative will contact you back with the result of the execution of the aforementioned query.



Article is closed for comments.