Focal Point Banner


As of December 1, 2020, Focal Point is retired and repurposed as a reference repository. We value the wealth of knowledge that's been shared here over the years. You'll continue to have access to this treasure trove of knowledge, for search purposes only.

Join the TIBCO Community
TIBCO Community is a collaborative space for users to share knowledge and support one another in making the best use of TIBCO products and services. There are several TIBCO WebFOCUS resources in the community.

  • From the Home page, select Predict: WebFOCUS to view articles, questions, and trending articles.
  • Select Products from the top navigation bar, scroll, and then select the TIBCO WebFOCUS product page to view product overview, articles, and discussions.
  • Request access to the private WebFOCUS User Group (login required) to network with fellow members.

Former myibi community members should have received an email on 8/3/22 to activate their user accounts to join the community. Check your Spam folder for the email. Please get in touch with us at community@tibco.com for further assistance. Reference the community FAQ to learn more about the community.


Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [SOLVED!] IBIMR_user in DBA section of MFD

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[SOLVED!] IBIMR_user in DBA section of MFD
 Login/Join
 
Guru
posted
I want to use &IBIMR_user in my DBA area, like
USER=X, ACCESS=R, RESTRICT=VALUE_WHERE, NAME=SYSTEM, VALUE=somefieldinmydatabase = '&IBIMR_USER';

But, it doesn't get evaluated, and the literal "&IBIMR_user" gets passed to my database. If I add ".EVAL" onto it, that just gets added to the literal and it still doesn't get evaluated. What the heck am I doing wrong here?

02/15/2016 - WORKS!!!

I found on another thread, where you have to put a line "VARIABLE NAME=&&FOCSECUSER, USAGE=A50, $" in the top of the MFD, right before the SEGMENT line. Then, in the DBA part, I have
VALUE=myfield eq '&&FOCSECUSER' and now it gets evaluated and sent to the DBMS, and my report runs a million times faster.

This is the coolest...forum...ever!

This message has been edited. Last edited by: Mike in DeLand,


Webfocus 8
Windows, Linux
 
Posts: 258 | Location: Palm Coast, FL | Registered: February 05, 2010Report This Post
Virtuoso
posted Hide Post
I think CNCTUSR is set to the same value as IBIMR_user. Try using something like this and see if that works.

-SET &&USERID = CNCTUSR('A50');
-SET &&USERID = TRUNCATE(&&USERID);


WebFOCUS 8206, Unix, Windows
 
Posts: 1853 | Location: New York City | Registered: December 30, 2015Report This Post
Master
posted Hide Post
Mike

You don't want to use &IBIMR_user variable because that gets set by the client through the Custom Settings. What this means is that anything that does not come in through the client won't have that value set. In version 8.0.08 things like Report Caster don't come in through the client (IBI has mentioned that in the future they will change this, because your Site Profile also doesn't run when using ReportCaster, but I don't know which version that change has/will occur). RC connects directly to the Reporting server so the variable &IBIMR_user never gets set.

The current recommended variable to use according to the IBI documentation is &FOCSECUSER which gets set by the Reporting Server. this is recommended over the GETUSER and CNCTUSR subroutines

Also I wouldn't put your value in quotes. I would use .QUOTEDSTRING instead. I always use .QUOTEDSTRING when evaluating my variables. Its cleaner and handles issues like what your experiencing

  
USER=X, ACCESS=R, RESTRICT=VALUE_WHERE, NAME=SYSTEM, VALUE=somefieldinmydatabase = &FOCSECUSER.QUOTEDSTRING;



Eric Woerle
8.1.05M Gen 913- Reporting Server Unix
8.1.05 Client Unix
Oracle 11.2.0.2
 
Posts: 750 | Location: Warrenville, IL | Registered: January 08, 2013Report This Post
Guru
posted Hide Post
I'll try focsecuser, thanks.

I tried CNTCUSER, but it doesn't get passed to the DBMS, and I think that slows down my processing since webfocus has to filter out what I want after the DBMS returns all the records. I hard-coded a value just to be sure it got through to the DBMS, and it did.


Webfocus 8
Windows, Linux
 
Posts: 258 | Location: Palm Coast, FL | Registered: February 05, 2010Report This Post
Guru
posted Hide Post
quote:
Originally posted by eric.woerle:
Mike

You don't want to use &IBIMR_user variable because that gets set by the client through the Custom Settings. What this means is that anything that does not come in through the client won't have that value set. In version 8.0.08 things like Report Caster don't come in through the client (IBI has mentioned that in the future they will change this, because your Site Profile also doesn't run when using ReportCaster, but I don't know which version that change has/will occur). RC connects directly to the Reporting server so the variable &IBIMR_user never gets set.

The current recommended variable to use according to the IBI documentation is &FOCSECUSER which gets set by the Reporting Server. this is recommended over the GETUSER and CNCTUSR subroutines

Also I wouldn't put your value in quotes. I would use .QUOTEDSTRING instead. I always use .QUOTEDSTRING when evaluating my variables. Its cleaner and handles issues like what your experiencing

  
USER=X, ACCESS=R, RESTRICT=VALUE_WHERE, NAME=SYSTEM, VALUE=somefieldinmydatabase = &FOCSECUSER.QUOTEDSTRING;



Well, FOCSECUSER doesn't work either. I can -TYPE it at the top of my code and see that it displays the logged-on user, but in the MFD it's still just getting passed as a literal "FOCSECUSER" instead of the substituted value.


Webfocus 8
Windows, Linux
 
Posts: 258 | Location: Palm Coast, FL | Registered: February 05, 2010Report This Post
Master
posted Hide Post
did you use .QUOTEDSTRING as I suggested?


Eric Woerle
8.1.05M Gen 913- Reporting Server Unix
8.1.05 Client Unix
Oracle 11.2.0.2
 
Posts: 750 | Location: Warrenville, IL | Registered: January 08, 2013Report This Post
Master
posted Hide Post
As I think about it, you may need to use global variables in MFD files. So if .QUOTEDSTRING still isn't working add:

SET &&FOCSECUSER = &FOCSECUSER

to the edasprof.


Eric Woerle
8.1.05M Gen 913- Reporting Server Unix
8.1.05 Client Unix
Oracle 11.2.0.2
 
Posts: 750 | Location: Warrenville, IL | Registered: January 08, 2013Report This Post
Guru
posted Hide Post
Still no luck. I did what you said and the darn amper variable still doesn't get evaluated when Webfocus passes the sql statement to my DBMS.
I can't believe such a simple thing is so hard to accomplish.


Webfocus 8
Windows, Linux
 
Posts: 258 | Location: Palm Coast, FL | Registered: February 05, 2010Report This Post
  Powered by Social Strata  

Read-Only Read-Only Topic

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [SOLVED!] IBIMR_user in DBA section of MFD

Copyright © 1996-2020 Information Builders