COGNOiSe.com - The IBM Cognos Community

IBM Cognos 10 Platform => Cognos 10 BI => Cognos Administration => Topic started by: Drisya on 11 Mar 2013 06:06:33 AM

Title: Get the list of reports in 'My Folder' of users
Post by: Drisya on 11 Mar 2013 06:06:33 AM
Hello All,

Can we get the list of reports in all users 'My Folder'. Probably from Content store!

My requirement is to create a report which displays the the list of reports in 'My Folder' for all users.

Thanks
Title: Re: Get the list of reports in 'My Folder' of users
Post by: RKMI on 11 Mar 2013 11:59:08 AM
Hi,

If you have an audit database/ audit package you can do it. You can create a report where username who has run a report from my folders. Then also create a list of reports executed from their My folders area. *Note: Audit DB will capture the reports which were executed not all the reports listed in their My folder.

Hope this helps.

Thanks,
RK
Title: Re: Get the list of reports in 'My Folder' of users
Post by: Drisya on 11 Mar 2013 11:33:13 PM
Hi,

Thanks for your reply. But the problem with Audit package is, if the object is deleted by user then also it will display in the report.
Secondly, the migration to c10 happened 2 month back, so the audit data is available for 2 months only.

Any other solution?
Title: Re: Get the list of reports in 'My Folder' of users
Post by: Rahul Ganguli on 12 Mar 2013 01:39:26 AM
You can query content store for the list of reprots in user's my folder
I have created such a query  in past

I have t search it, I will get back to you with the query soon

Regards,
Rahul
Title: Re: Get the list of reports in 'My Folder' of users
Post by: Rahul Ganguli on 12 Mar 2013 11:01:14 PM
Hi,

Attached is the query for users with My Folder content.
This query is on Oracle Content Store, you may need to change few syntax if you have other Database.

Hope this was helpful.

Regards,
Rahul
Title: Re: Get the list of reports in 'My Folder' of users
Post by: Drisya on 14 Mar 2013 03:43:22 AM
Thanks Rahul. It helps.

The query is working for me in SQL server. But it displays all the objects directly inside 'My Folder' and not the items inside folders.
I will work more on it and try to retrieve them as well.

Title: Re: Get the list of reports in 'My Folder' of users
Post by: Rahul Ganguli on 15 Mar 2013 02:59:06 AM
I will try from my end too.
This time I will try in SQL sever 2008.

Regards,
Rahul
Title: Re: Get the list of reports in 'My Folder' of users
Post by: murali999 on 22 Mar 2013 12:54:31 AM
Hi,
you can list all the reports from users MyFolders easily by using cognos SDK program.

are you having the SDK installation ?


Title: Re: Get the list of reports in 'My Folder' of users
Post by: TheBrenda on 16 Jul 2013 09:37:09 PM
stupid question, but how do i access the script? I see the paperclip but have nothing to click on. I have downloaded scripts from here before but for some reason (late night) i am now unable.
Title: Re: Get the list of reports in 'My Folder' of users
Post by: MFGF on 17 Jul 2013 02:34:36 AM
Quote from: TheBrenda on 16 Jul 2013 09:37:09 PM
stupid question, but how do i access the script? I see the paperclip but have nothing to click on. I have downloaded scripts from here before but for some reason (late night) i am now unable.

I can access it with no issues. It's fairly small, so I'm pasting the contents below. Hope this helps! :)

MF.

--List of Users with My Folder Contents
with base_query as
(select classid, cmobjects.cmid, cmobjects.pcmid, cmobjnames.name as reportname
from cmobjects , cmobjnames
where cmobjects.cmid = cmobjnames.cmid
--and classid in (10)
and cmobjnames.mapdlocaleid = 24
union
select classid, cmobjects.cmid as cmid, cmobjects.pcmid, cmobjnames.name as reportname
from cmobjects , cmobjnames
where cmobjects.cmid = cmobjnames.cmid
and  cmobjects.cmid in (select distinct cmobjects.pcmid from cmobjects)
and cmobjnames.mapdlocaleid = 24
)
select distinct OW1.name,X.directory_path,Y.directory_path2
from
(
    select base_query.cmid,
    base_query.pcmid,
    base_query.reportname,
    1 as Hlevel,classid,
    base_query.reportname as directory_path
    from base_query where reportname = 'My Folders'
) x
inner join 
(
select cmid,
pcmid,
reportname,
classid,
reportname as directory_path2
from base_query
) y on x.cmid=y.pcmid
left join CMOBJPROPS33 ow1 
    on x.PCMID=OW1.CMID
left join CMOBJPROPS33 ow2 
    on y.PCMID=ow2.CMID
order by OW1.NAME
Title: Re: Get the list of reports in 'My Folder' of users
Post by: Suraj on 17 Jul 2013 10:26:27 AM
If you use BSP Metamanager, there is simple search to find users with My Folders contents.
Title: Re: Get the list of reports in 'My Folder' of users
Post by: TheBrenda on 17 Jul 2013 05:02:01 PM
The script is really helpful, thanks. Realize I am jumping on another post, but, ... any idea how to do something like this for reportnet 1.1.?
Title: Re: Get the list of reports in 'My Folder' of users
Post by: kommireddy on 24 Jul 2013 02:32:52 PM
This is very useful script, thanks to Rahul. Is it possible to query and show reports under sub-folder under My Folders?
Title: Re: Get the list of reports in 'My Folder' of users
Post by: TheBrenda on 28 Aug 2013 07:02:15 AM
Have you tried to substitute "reportname = 'My Folders'" with your folder name?
Title: Re: Get the list of reports in 'My Folder' of users
Post by: Summer on 08 Jul 2014 10:43:11 AM
Even though this is an old post, i still want to thank you MFGF, your script is really helpful. I just need to change mapdlocaleid to work in my environment.
Title: Re: Get the list of reports in 'My Folder' of users
Post by: MFGF on 10 Jul 2014 07:31:18 AM
Quote from: Summer on 08 Jul 2014 10:43:11 AM
Even though this is an old post, i still want to thank you MFGF, your script is really helpful. I just need to change mapdlocaleid to work in my environment.

Thanks - but it isn't my script :) It was posted up by Rahul Ganguli so he is the one deserving of your thanks. He posted it as an attachment (which a few people struggled to get access to) so I simply posted the contents directly into the thread. That's the extent of my contribution here.

Cheers, and thanks (for posting up a nice thank-you) :)

MF.
Title: Re: Get the list of reports in 'My Folder' of users
Post by: AnuElza on 08 Mar 2018 10:43:15 AM
Works like a charm! :D