If you read my post External table authentication and row-wise initialization in OBIEE , in Part1 - External table authentication I'm using external table for authentication of the user, group, displayname and loglevel.
I'm using b_ext_tab_auth_all block:
select username, groupname, displayname, loglevel
from HR.OBIEE_EXT_TAB_AUTH
where username=':USER'
and password=':PASSWORD'
The table OBIEE_EXT_TAB_AUTH has loglevel column number datatype in the database and when you import it to a repository it has double datatype:
![](https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgNjPPdwrKU6JKVvu01x4yT6FWQqKGLmLc_KVraJ_9_tp4Kj3taKhsnpk10tVCLP95ZTnJLbkKf5HBa7a7napkEOwySfJ-5uPQ3aPlqPA4OnmB-z2i9MSjLWSN-jy4qZaBNyyNg0dqJG5I/s320/picture410.JPG)
Logon with some user (UserC, which has loglevel 5 in the database) and make a simple request and see NQQuery.log.
You'll see that the log in the NQQuery.log does not exist.
Try to put first in the column in the report VALUEOF(NQ_SESSION.LOGLEVEL) to see what is populated:
![](https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgqPVwFNoys3LvPdox1F-GoHuY6nN3qWvxNa_hqcNxlJs5DiVsGzqLDYpi69l6todGzknc_SsHON35T6JSHX0EmJzjRDZv1HBLL0n2wmxUxv7Oo4TO49hSAxcTCE8SkCM5Y1naDNxam_As/s320/picture411.JPG)
Ok, this is because decimal is populated and LOGLEVEL need to have integer as input to work properly.
Solution:
Leave datatype of imported table to DOUBLE and do a explicit TO_NUMBER(loglevel) conversion:
select username, groupname, displayname, to_number(loglevel)
from HR.OBIEE_EXT_TAB_AUTH
where username=':USER'
and password=':PASSWORD'
Now it works and you'll get log in the NQQuery.log.
*Note
If you just change datatype of imported table from DOUBLE to INT and leave block without change:
select username, groupname, displayname, loglevel
from HR.OBIEE_EXT_TAB_AUTH
where username=':USER'
and password=':PASSWORD'
it does not work, you can't see logs in NQQuery.log.
If you are using character for LOGLEVEL column in the database then you need to put TO_NUMBER(loglevel) also.
I'm using b_ext_tab_auth_all block:
select username, groupname, displayname, loglevel
from HR.OBIEE_EXT_TAB_AUTH
where username=':USER'
and password=':PASSWORD'
The table OBIEE_EXT_TAB_AUTH has loglevel column number datatype in the database and when you import it to a repository it has double datatype:
Logon with some user (UserC, which has loglevel 5 in the database) and make a simple request and see NQQuery.log.
You'll see that the log in the NQQuery.log does not exist.
Try to put first in the column in the report VALUEOF(NQ_SESSION.LOGLEVEL) to see what is populated:
Ok, this is because decimal is populated and LOGLEVEL need to have integer as input to work properly.
Solution:
Leave datatype of imported table to DOUBLE and do a explicit TO_NUMBER(loglevel) conversion:
select username, groupname, displayname, to_number(loglevel)
from HR.OBIEE_EXT_TAB_AUTH
where username=':USER'
and password=':PASSWORD'
Now it works and you'll get log in the NQQuery.log.
*Note
If you just change datatype of imported table from DOUBLE to INT and leave block without change:
select username, groupname, displayname, loglevel
from HR.OBIEE_EXT_TAB_AUTH
where username=':USER'
and password=':PASSWORD'
it does not work, you can't see logs in NQQuery.log.
If you are using character for LOGLEVEL column in the database then you need to put TO_NUMBER(loglevel) also.