Catching up on old Oracle-L:
That is a very interesting work-around.
Where is the use of @variable in a comment documented?
For those of you who are interested, we found a workaround to pass the Login UserId of the business objects user from the application to the database.
The workaround is to include a comment like:
/* User: @variable('BOUSER') */
in the beginning of the SQL statement. This when passed onto the database, expands to expose the Login User Id. So, the sql_text would show, for example, /* User: 'A999' */, if A999 is the application userid of the user that logged into the app.
-- Jared Still Certifiable Oracle DBA and Part Time Perl Evangelist