Report that only displays employees directly reporting to the manager running the report
Hello I'm running Obi 11g and I'm creating a dashboard for managers and I'm having difficulty finding a way to create a report for the dashboard that shows only the employees directly reporting to the manager running the dashboard / report.
I've done a little research and I'm guessing this is going to be done by session variables? but i'm not sure how. If there was a way I can pull the executing user's username I could just say employee.username = session.username and then run the query accordingly but is there a way to this?
Any help would be appreciated greatly. Thanks.
sql oracle oracle11g datamodel
add a comment |
Hello I'm running Obi 11g and I'm creating a dashboard for managers and I'm having difficulty finding a way to create a report for the dashboard that shows only the employees directly reporting to the manager running the dashboard / report.
I've done a little research and I'm guessing this is going to be done by session variables? but i'm not sure how. If there was a way I can pull the executing user's username I could just say employee.username = session.username and then run the query accordingly but is there a way to this?
Any help would be appreciated greatly. Thanks.
sql oracle oracle11g datamodel
add a comment |
Hello I'm running Obi 11g and I'm creating a dashboard for managers and I'm having difficulty finding a way to create a report for the dashboard that shows only the employees directly reporting to the manager running the dashboard / report.
I've done a little research and I'm guessing this is going to be done by session variables? but i'm not sure how. If there was a way I can pull the executing user's username I could just say employee.username = session.username and then run the query accordingly but is there a way to this?
Any help would be appreciated greatly. Thanks.
sql oracle oracle11g datamodel
Hello I'm running Obi 11g and I'm creating a dashboard for managers and I'm having difficulty finding a way to create a report for the dashboard that shows only the employees directly reporting to the manager running the dashboard / report.
I've done a little research and I'm guessing this is going to be done by session variables? but i'm not sure how. If there was a way I can pull the executing user's username I could just say employee.username = session.username and then run the query accordingly but is there a way to this?
Any help would be appreciated greatly. Thanks.
sql oracle oracle11g datamodel
sql oracle oracle11g datamodel
edited Nov 21 '18 at 16:45
K. Layton
asked Nov 20 '18 at 21:55
K. LaytonK. Layton
728
728
add a comment |
add a comment |
3 Answers
3
active
oldest
votes
This is Oracle. It offers a function named USER that returns ... well, current user. So, your query might utilize it as
where employee.username = user
user returns with the value 'FUSION_RUNTIME' no matter who I'm logged into.
– K. Layton
Nov 20 '18 at 23:02
user variable will return schema name.. so hence it returns with the value 'FUSION_RUNTIME' no matter who is logged into. because everyone is using the same schema.
– AmeyaN99
Nov 21 '18 at 4:22
I see; sorry, I hoped that it'll help.
– Littlefoot
Nov 21 '18 at 7:52
add a comment |
Since this may be an Oracle product but not and Oracle database query, you will need sth more OBI-specific:
VALUEOF(NQ_SESSION.USER)
Anyway you can show me an example query? I'm getting an invalid table name for this one.
– K. Layton
Nov 20 '18 at 23:08
Not sure what you mean or what your problem is since you aren't being very precise about it. What I described is standard functionality which exists in exactly this form since almost 20 years.
– Chris
Nov 21 '18 at 14:46
I think its more because. I misunderstood exactly what I was trying to say or my research could have been completely wrong and it through people off on my question. I'm writing a SQL query in a data set for a data model. I want to pull the current username of whoever runs the report that uses this data model. I've tried usersys_context('USERENV','CURRENT_USER')i've also tried SESSION_USER and it all comes back with fusion or fusion_runtime
– K. Layton
Nov 21 '18 at 16:00
"I'm writing a SQL query in a data set for a data model." That's BI Publisher and not OBIEE. While BIP may be integrated, it's still a totally different technology.
– Chris
Nov 21 '18 at 16:23
Ah I see. Sorry about that I'm still just starting out in Oracle and someone incorrectly(apparently) told me I was in OBIEE. That actually explains a lot of troubles with my searches as well. Thanks for the clarification. I'll remove the obiee tag then.
– K. Layton
Nov 21 '18 at 16:45
|
show 1 more comment
I found what I was looking for
SELECT fnd_global.user_name FROM DUAL
This posts the username instead of the schema.
add a comment |
Your Answer
StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53402186%2freport-that-only-displays-employees-directly-reporting-to-the-manager-running-th%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
3 Answers
3
active
oldest
votes
3 Answers
3
active
oldest
votes
active
oldest
votes
active
oldest
votes
This is Oracle. It offers a function named USER that returns ... well, current user. So, your query might utilize it as
where employee.username = user
user returns with the value 'FUSION_RUNTIME' no matter who I'm logged into.
– K. Layton
Nov 20 '18 at 23:02
user variable will return schema name.. so hence it returns with the value 'FUSION_RUNTIME' no matter who is logged into. because everyone is using the same schema.
– AmeyaN99
Nov 21 '18 at 4:22
I see; sorry, I hoped that it'll help.
– Littlefoot
Nov 21 '18 at 7:52
add a comment |
This is Oracle. It offers a function named USER that returns ... well, current user. So, your query might utilize it as
where employee.username = user
user returns with the value 'FUSION_RUNTIME' no matter who I'm logged into.
– K. Layton
Nov 20 '18 at 23:02
user variable will return schema name.. so hence it returns with the value 'FUSION_RUNTIME' no matter who is logged into. because everyone is using the same schema.
– AmeyaN99
Nov 21 '18 at 4:22
I see; sorry, I hoped that it'll help.
– Littlefoot
Nov 21 '18 at 7:52
add a comment |
This is Oracle. It offers a function named USER that returns ... well, current user. So, your query might utilize it as
where employee.username = user
This is Oracle. It offers a function named USER that returns ... well, current user. So, your query might utilize it as
where employee.username = user
answered Nov 20 '18 at 22:09
LittlefootLittlefoot
23.4k71533
23.4k71533
user returns with the value 'FUSION_RUNTIME' no matter who I'm logged into.
– K. Layton
Nov 20 '18 at 23:02
user variable will return schema name.. so hence it returns with the value 'FUSION_RUNTIME' no matter who is logged into. because everyone is using the same schema.
– AmeyaN99
Nov 21 '18 at 4:22
I see; sorry, I hoped that it'll help.
– Littlefoot
Nov 21 '18 at 7:52
add a comment |
user returns with the value 'FUSION_RUNTIME' no matter who I'm logged into.
– K. Layton
Nov 20 '18 at 23:02
user variable will return schema name.. so hence it returns with the value 'FUSION_RUNTIME' no matter who is logged into. because everyone is using the same schema.
– AmeyaN99
Nov 21 '18 at 4:22
I see; sorry, I hoped that it'll help.
– Littlefoot
Nov 21 '18 at 7:52
user returns with the value 'FUSION_RUNTIME' no matter who I'm logged into.
– K. Layton
Nov 20 '18 at 23:02
user returns with the value 'FUSION_RUNTIME' no matter who I'm logged into.
– K. Layton
Nov 20 '18 at 23:02
user variable will return schema name.. so hence it returns with the value 'FUSION_RUNTIME' no matter who is logged into. because everyone is using the same schema.
– AmeyaN99
Nov 21 '18 at 4:22
user variable will return schema name.. so hence it returns with the value 'FUSION_RUNTIME' no matter who is logged into. because everyone is using the same schema.
– AmeyaN99
Nov 21 '18 at 4:22
I see; sorry, I hoped that it'll help.
– Littlefoot
Nov 21 '18 at 7:52
I see; sorry, I hoped that it'll help.
– Littlefoot
Nov 21 '18 at 7:52
add a comment |
Since this may be an Oracle product but not and Oracle database query, you will need sth more OBI-specific:
VALUEOF(NQ_SESSION.USER)
Anyway you can show me an example query? I'm getting an invalid table name for this one.
– K. Layton
Nov 20 '18 at 23:08
Not sure what you mean or what your problem is since you aren't being very precise about it. What I described is standard functionality which exists in exactly this form since almost 20 years.
– Chris
Nov 21 '18 at 14:46
I think its more because. I misunderstood exactly what I was trying to say or my research could have been completely wrong and it through people off on my question. I'm writing a SQL query in a data set for a data model. I want to pull the current username of whoever runs the report that uses this data model. I've tried usersys_context('USERENV','CURRENT_USER')i've also tried SESSION_USER and it all comes back with fusion or fusion_runtime
– K. Layton
Nov 21 '18 at 16:00
"I'm writing a SQL query in a data set for a data model." That's BI Publisher and not OBIEE. While BIP may be integrated, it's still a totally different technology.
– Chris
Nov 21 '18 at 16:23
Ah I see. Sorry about that I'm still just starting out in Oracle and someone incorrectly(apparently) told me I was in OBIEE. That actually explains a lot of troubles with my searches as well. Thanks for the clarification. I'll remove the obiee tag then.
– K. Layton
Nov 21 '18 at 16:45
|
show 1 more comment
Since this may be an Oracle product but not and Oracle database query, you will need sth more OBI-specific:
VALUEOF(NQ_SESSION.USER)
Anyway you can show me an example query? I'm getting an invalid table name for this one.
– K. Layton
Nov 20 '18 at 23:08
Not sure what you mean or what your problem is since you aren't being very precise about it. What I described is standard functionality which exists in exactly this form since almost 20 years.
– Chris
Nov 21 '18 at 14:46
I think its more because. I misunderstood exactly what I was trying to say or my research could have been completely wrong and it through people off on my question. I'm writing a SQL query in a data set for a data model. I want to pull the current username of whoever runs the report that uses this data model. I've tried usersys_context('USERENV','CURRENT_USER')i've also tried SESSION_USER and it all comes back with fusion or fusion_runtime
– K. Layton
Nov 21 '18 at 16:00
"I'm writing a SQL query in a data set for a data model." That's BI Publisher and not OBIEE. While BIP may be integrated, it's still a totally different technology.
– Chris
Nov 21 '18 at 16:23
Ah I see. Sorry about that I'm still just starting out in Oracle and someone incorrectly(apparently) told me I was in OBIEE. That actually explains a lot of troubles with my searches as well. Thanks for the clarification. I'll remove the obiee tag then.
– K. Layton
Nov 21 '18 at 16:45
|
show 1 more comment
Since this may be an Oracle product but not and Oracle database query, you will need sth more OBI-specific:
VALUEOF(NQ_SESSION.USER)
Since this may be an Oracle product but not and Oracle database query, you will need sth more OBI-specific:
VALUEOF(NQ_SESSION.USER)
answered Nov 20 '18 at 22:36
ChrisChris
1,4392712
1,4392712
Anyway you can show me an example query? I'm getting an invalid table name for this one.
– K. Layton
Nov 20 '18 at 23:08
Not sure what you mean or what your problem is since you aren't being very precise about it. What I described is standard functionality which exists in exactly this form since almost 20 years.
– Chris
Nov 21 '18 at 14:46
I think its more because. I misunderstood exactly what I was trying to say or my research could have been completely wrong and it through people off on my question. I'm writing a SQL query in a data set for a data model. I want to pull the current username of whoever runs the report that uses this data model. I've tried usersys_context('USERENV','CURRENT_USER')i've also tried SESSION_USER and it all comes back with fusion or fusion_runtime
– K. Layton
Nov 21 '18 at 16:00
"I'm writing a SQL query in a data set for a data model." That's BI Publisher and not OBIEE. While BIP may be integrated, it's still a totally different technology.
– Chris
Nov 21 '18 at 16:23
Ah I see. Sorry about that I'm still just starting out in Oracle and someone incorrectly(apparently) told me I was in OBIEE. That actually explains a lot of troubles with my searches as well. Thanks for the clarification. I'll remove the obiee tag then.
– K. Layton
Nov 21 '18 at 16:45
|
show 1 more comment
Anyway you can show me an example query? I'm getting an invalid table name for this one.
– K. Layton
Nov 20 '18 at 23:08
Not sure what you mean or what your problem is since you aren't being very precise about it. What I described is standard functionality which exists in exactly this form since almost 20 years.
– Chris
Nov 21 '18 at 14:46
I think its more because. I misunderstood exactly what I was trying to say or my research could have been completely wrong and it through people off on my question. I'm writing a SQL query in a data set for a data model. I want to pull the current username of whoever runs the report that uses this data model. I've tried usersys_context('USERENV','CURRENT_USER')i've also tried SESSION_USER and it all comes back with fusion or fusion_runtime
– K. Layton
Nov 21 '18 at 16:00
"I'm writing a SQL query in a data set for a data model." That's BI Publisher and not OBIEE. While BIP may be integrated, it's still a totally different technology.
– Chris
Nov 21 '18 at 16:23
Ah I see. Sorry about that I'm still just starting out in Oracle and someone incorrectly(apparently) told me I was in OBIEE. That actually explains a lot of troubles with my searches as well. Thanks for the clarification. I'll remove the obiee tag then.
– K. Layton
Nov 21 '18 at 16:45
Anyway you can show me an example query? I'm getting an invalid table name for this one.
– K. Layton
Nov 20 '18 at 23:08
Anyway you can show me an example query? I'm getting an invalid table name for this one.
– K. Layton
Nov 20 '18 at 23:08
Not sure what you mean or what your problem is since you aren't being very precise about it. What I described is standard functionality which exists in exactly this form since almost 20 years.
– Chris
Nov 21 '18 at 14:46
Not sure what you mean or what your problem is since you aren't being very precise about it. What I described is standard functionality which exists in exactly this form since almost 20 years.
– Chris
Nov 21 '18 at 14:46
I think its more because. I misunderstood exactly what I was trying to say or my research could have been completely wrong and it through people off on my question. I'm writing a SQL query in a data set for a data model. I want to pull the current username of whoever runs the report that uses this data model. I've tried user
sys_context('USERENV','CURRENT_USER') i've also tried SESSION_USER and it all comes back with fusion or fusion_runtime– K. Layton
Nov 21 '18 at 16:00
I think its more because. I misunderstood exactly what I was trying to say or my research could have been completely wrong and it through people off on my question. I'm writing a SQL query in a data set for a data model. I want to pull the current username of whoever runs the report that uses this data model. I've tried user
sys_context('USERENV','CURRENT_USER') i've also tried SESSION_USER and it all comes back with fusion or fusion_runtime– K. Layton
Nov 21 '18 at 16:00
"I'm writing a SQL query in a data set for a data model." That's BI Publisher and not OBIEE. While BIP may be integrated, it's still a totally different technology.
– Chris
Nov 21 '18 at 16:23
"I'm writing a SQL query in a data set for a data model." That's BI Publisher and not OBIEE. While BIP may be integrated, it's still a totally different technology.
– Chris
Nov 21 '18 at 16:23
Ah I see. Sorry about that I'm still just starting out in Oracle and someone incorrectly(apparently) told me I was in OBIEE. That actually explains a lot of troubles with my searches as well. Thanks for the clarification. I'll remove the obiee tag then.
– K. Layton
Nov 21 '18 at 16:45
Ah I see. Sorry about that I'm still just starting out in Oracle and someone incorrectly(apparently) told me I was in OBIEE. That actually explains a lot of troubles with my searches as well. Thanks for the clarification. I'll remove the obiee tag then.
– K. Layton
Nov 21 '18 at 16:45
|
show 1 more comment
I found what I was looking for
SELECT fnd_global.user_name FROM DUAL
This posts the username instead of the schema.
add a comment |
I found what I was looking for
SELECT fnd_global.user_name FROM DUAL
This posts the username instead of the schema.
add a comment |
I found what I was looking for
SELECT fnd_global.user_name FROM DUAL
This posts the username instead of the schema.
I found what I was looking for
SELECT fnd_global.user_name FROM DUAL
This posts the username instead of the schema.
answered Nov 21 '18 at 16:14
K. LaytonK. Layton
728
728
add a comment |
add a comment |
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53402186%2freport-that-only-displays-employees-directly-reporting-to-the-manager-running-th%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown