def add_category_type_by_name(conn, category_type_name):
    if (is_conn(conn) and is_str(category_type_name)):
        cursor = conn.cursor()
        cursor.execute('SET IDENTITY_INSERT dbo.CategoriesTypes ON')
        conn.commit()
        cursor.execute('INSERT INTO dbo.CategoriesTypes (Id, Typename)                 VALUES((SELECT max(Id)+1 FROM dbo.CategoriesTypes), ?)', category_type_name)
        conn.commit()
        cursor.execute('SET IDENTITY_INSERT dbo.CategoriesTypes OFF')
        conn.commit()
        return True
    else:
        raise AttributeError('Connection object or Category Name                 was not provided')
def add_category_type_by_name(conn, category_type_name):
    if (is_conn(conn) and is_str(category_type_name)):
        cursor = conn.cursor()
        cursor.execute('SET IDENTITY_INSERT dbo.CategoriesTypes ON')
        conn.commit()
        cursor.execute('INSERT INTO dbo.CategoriesTypes (Id, Typename)                 VALUES((SELECT max(Id)+1 FROM dbo.CategoriesTypes), ?)', category_type_name)
        conn.commit()
        cursor.execute('SET IDENTITY_INSERT dbo.CategoriesTypes OFF')
        conn.commit()
        return True
    else:
        raise AttributeError('Connection object or Category Name                 was not provided')