Focal Point
[CLOSED] WebFOCUS User ID Administration - Bulk Loading ID's

This topic can be found at:
https://forums.informationbuilders.com/eve/forums/a/tpc/f/7971057331/m/50410047

April 07, 2009, 01:16 PM
<Daniel Totten>
[CLOSED] WebFOCUS User ID Administration - Bulk Loading ID's
We are fairly new to WebFOCUS and will have many thousands of users we need to add.

What is the best way to add users in bulk - NOT manually - If you had 1,000 users to add - How would you add them?

This message has been edited. Last edited by: Kerry,
April 07, 2009, 01:35 PM
<JG>
Are you MRE/Dashboard?

If not you do not need to add users.

Even if you are use active directory / LDAP it will control it.
April 08, 2009, 06:58 AM
<Daniel Totten>
We are MRE / Dashboard - Unfortunately we have a specific authentication model we must follow -We are investigating direct SQL into the WF tables to accomoplish the bulk loading.
April 08, 2009, 08:13 AM
Laure
Check out the WebFOCUS API Developer's Reference and the WebFOCUS Web Services PDF documents IBI has. It tells you how to use their Web Services to do this- There's a section on 'Creating a New User' under the Managed Reporting Functions in the WebFOCUS Web Services document. We were succesful in updating 100% of our 900+ userids when we upgraded and implemented single-signon last summer. If you can't find the docs just let me know your email and I'll forward a copy.


Laure


Prod: WebFOCUS 7.7.03 - MRE, BID, - WindowsXP - Oracle 9i, SQLServer, DevStudio 7.7.3 - Apache Tomcat , Output: HTML, Excel 2013 and PDF
April 16, 2009, 12:28 AM
TexasStingray
quote:
Daniel Totten

If it were me I would configure MRE for either a JDBC repository (then I would use SQL INSERT), or AD/LDAP and use a VBS script file.




Scott

If its a one time load the easiest way to do it is going to be direct SQL inserts.

If it is an ongoing process this can be done via scheduled SQL dumps, Webservices (separate license), or the Managed Reporting Java API.

If the data you have is already in a DBMS it is also possible to create a view to put it in the format WebFOCUS expects, or setup the realm driver to use stored procedures and modify those stored procedures to go against your existing DBMS.

If this sounds like the route you want to go let me know and I'll see about digging up the links that talk about the DBMS structure and the existing queries.


WF 71.x, 76.x, 7701, 8.0 Beta OS: Linux, Win2k3, Win2k, Win2k8, WinXP


dlogan,

I have a request, just today to add 800+ users. So, I'm starting with the SQL inserts and can successfully insert a new user, but my next step was to add these users to a group and that's not working for me. Are there any docs on how to add a user to a group (programmatically) ?

The GROUPSUSERS table seems simple enough (columns: ID, GROUP_ID, USERID).

I see my new rows for GROUPSUSERS added SUCCESSFULLY, but the security center doesn't show any groups for the new users.

Thanks,
--wg


WF 8009m, Clustered vm Windows2008r2 reporting servers;
Web interface: tomcat;
Output: EXCEL, HTML, PDF; dbms: Oracle 10, db2 on mvs, mssql
Do the groups inserted in the GROUPSUSERS table exist in the GROUPS table?

The FEX and SQL below join the three relevant tables to create a report using left outer join for GROUPS, which should highlight the group relationship.

SET NODATA=MISSING
JOIN USERID IN UOA_GROUPSUSERS TO ID IN UOA_USERS AS J1

JOIN LEFT_OUTER GROUPID IN UOA_GROUPSUSERS TO ID IN UOA_GROUPS AS J2

TABLE FILE UOA_GROUPSUSERS 
PRINT

UOA_GROUPSUSERS.USERID
UOA_USERS.ID
UOA_USERS.DESCRIPTION
NAME

UOA_GROUPSUSERS.GROUPID
UOA_GROUPS.ID
UOA_GROUPS.DESCRIPTION
UOA_GROUPS.NAME
END 


SELECT
T1.USERID "UOA_GROUPSUSERS.USERID",
T2.ID "UOA_USERS.ID",
T2.DESCRIPTION "UOA_USERS.DESCRIPTION",
T2.NAME "UOA_USERS.NAME",

T1.GROUPID "UOA_GROUPSUSERS.GROUPID",
T3.ID "UOA_GROUPS.ID",
T3.DESCRIPTION "UOA_GROUPS.DESCRIPTION",
T3.NAME "UOA_GROUPS.NAME"
FROM
WF_REPOS.UOA_GROUPSUSERS T1
INNER JOIN WF_REPOS.UOA_USERS T2
    ON T2.ID = T1.USERID 
LEFT OUTER JOIN WF_REPOS.UOA_GROUPS T3
    ON T3.ID = T1.GROUPID
;



Francis


Give me code, or give me retirement. In FOCUS since 1991

Production: WF 7.7.05M, Dev Studio, BID, MRE, WebSphere, DB2 / Test: WF 8.1.05M, App Studio, BI Portal, Report Caster, jQuery, HighCharts, Apache Tomcat, MS SQL Server
Thanks Francis,

Yes, they exist. I didn't actually insert new groups, just inserted new users and was trying to added the new users to existing groups.

it seems to be another insert or update needed to finish the steps for adding new users thru SQL.
I have completed two steps:
1) added new users to uoa_users (successfully).
2) added these new users, from step 1 to uoa_groupsusers (succesfully).

In both cases a sequence was generated by me. I used max(seq) +1, in both inserts. Not sure that's correct.

I was hoping that someone has already resovled the steps needed to add new users, using SQL???

Thanks,
--wg


WF 8009m, Clustered vm Windows2008r2 reporting servers;
Web interface: tomcat;
Output: EXCEL, HTML, PDF; dbms: Oracle 10, db2 on mvs, mssql
all,

btw, I think I failed to mention that I first created an excel sheet with new user (name, desc, email, primgroup, status...etc) and uploaded to oracle (to the repo schema) for seed info for the new users. This new source table also contains the self-generated sequence numbers for the tables involved.

--wg


WF 8009m, Clustered vm Windows2008r2 reporting servers;
Web interface: tomcat;
Output: EXCEL, HTML, PDF; dbms: Oracle 10, db2 on mvs, mssql
Francis,

Your question was very helpful. After double checking, I see the groupID that I inserted into the groupsusers was wrong. Trying another test now, using a corrected groupID.

Thanks,
--wg


WF 8009m, Clustered vm Windows2008r2 reporting servers;
Web interface: tomcat;
Output: EXCEL, HTML, PDF; dbms: Oracle 10, db2 on mvs, mssql