Using a different connection based on certain criteria

For particular administrative needs, we managed data by projects on separate database.
Those projects data are on a particular database based on the company division and/or the country of the project.
A user may have access to two projects that are on different database.
We have 30 SqlServer 'Project' databases with the same schema, and a corporate database that contains security tables (with a Project-Database relation table).
We are presently using Webi on BO 2.0.
In order to access the right database via the Universe and Reports, we defined 30 generic users (ex: uDB1,
uDB2, uDB3, ...) and add 30 access restrictions in the Universe based on the generic user.
With a custom application and thru the API, we execute a Webi report with the generic user based on the
database name in which the real user is logged in.
That way, with the help of the access restriction in the BO universe, the data comes from the right database.
We don't let users create their own report.
Instead, we have created a template with a few fields from the universe.
Users, thru the generic user account, can execute the template, add or remove a few fields, and save as
another report name.
But with that strategy, any users that have access to the same database could modify the reports of each
other, because they all log thru the same generic account.
So we set the security in order to not let a user modify his own report.
But this is resulting in having a few iteration of the same report (Ex: Report_A_v1, Report_A_v2,
Report_A_v3,...) each time a real user wants to modify his own report.
We are in the process of moving to BO 3.1 in a few weeks.
We were told that we may be able to resolve our problem with Stored Procedure.
Instead of having generic accounts, we should be able to have real users accounts and, with security table where we store on which database is store a project, we should be able to create stored procedure dynamically to access the right database.
Has anyone faced a similar problem and found a solution ?

For an SQL query on a database use a View Object. First, you will need to create a new Entity object to represent each table in the database you need to use in the queries. Once you have created your view objects with their correct SQL queries, you need to specify how they are related. Example:
RootView is all elements with ParentId of null.
OtherView is all elements with ParentId not null.
RootToOtherLink is a view link which links RootView.Id to OtherView.ParentId. You can specify this in the dialog. You will want to select all accessors available to make your life easier later, but make sure to name them something you will recognize, like "RootToOtherDestination".
You will also need OtherToOther Link which links OtherView.Id to OtherView.ParentId. This starts the recursive nature of the hierarchical relationship.
Once you have this set up, you will need to create an Application Module so that you have a data control you can bind your tree to. Set up the data model in a hierarchical fashion using your link.
This will create a data control on the Data Controls pane you can drag onto your .jspx page. A menu will show up from which you can select tree component. This will take you to the tree binding dialog. Here is where all your work so far will pay off. You want to click the green plus button to add your RootView. Then, with the RootView selected you will want to hit the green plus again to select your destination accessor, such as "RootToOtherDestination" as mentioned earlier. This will show the OtherView as a child of the RootView. Finally, with OtherView selected you will want to hit the green plus again and select your other destination accessor, such as "OtherToOtherDestination". Select the attributes you want to have available to your tree at the bottom of the dialog and click ok.
Your tree will show up. If you want to customize the way it looks or especially the attributes it displays in a node, those can be edited in the <af:tree> tag on your .jspx page.

Similar Messages

  • Opening a new form using a different connect string

    Hi All
    I have the following requirement. I want to open an new form (when button pressed) using a different connect string. I am planning to use open form so that the new form has its own session. But I donot want the new form to connect to the same database. How do I pass the database that I want to connect using open form.
    Rgds
    Arvind Balaraman

    The only way to change the connection is to execute the built-in LOGIN and connect to the desired database. You cannot pass this through the OPEN_FORM built-in.
    Example:
    LOGOUT;
    LOGON(uname, upass || '@' || conn_str);
    However, be aware that this will impact the first form too. This is expected behavior.
    See Oracle Bug 5004661 or the Forms Online Help for more details.
    http://www.oracle.com/webapps/online-help/forms/10g/state?navSetId=_&navId=3&vtTopicFile=designing_forms/multform_db/at0505.html

  • I cannot get ipod to start, Logo for power is the only one that appears but it will not recharge either by using pC or dock. I have used two different connecting wires but no difference in response

    I cannot get Ipod to start. The only logo that comes up is the power needed but in spite of connecting the ipod to PC and using two different connection leads the ipod does not respond. I also tried to power it using a i station 7 but no difference. I tried all the usual pressing of both menu and play buttons. Is it fixable?

    Thanks for your tip. I tried leaving the ipod in the I -Station  7 overnight and then reconnected it to my PC> It asked if i wanted to reset to factory settings. I did this and then the Apple logo came back on .After that a very sad looking logo of an ipod came on with  www.apple.com/support/ipod underneath. I feel that either burial or cremation is my option now for this old ipod.

  • Returning Different Results Based on Input Criteria

    I have a complex nested select statement. Based on selection criteria I want to return different results. Say for instance I had an input parameter Called Products which could contain a Yes/No Flag. If the Flag was Yes then I would want the "top" select, statement to be The following:
    Select Product, Time_ID, Amt
    From
    My Complex Nested Select
    But if Product was set to "No", I would want the following:
    Select Time_ID, Amt
    From
    My Complex Nested Select
    I know, or course that I can have two COMPLETE set of SQL which are invoked based upon testing the value of the PRODUCT Parameter, but If I duplicate the "inner nested select" then I have 2 sets of select staments to maintain. Is there an alternative to this? Could I make the inner portion which does not change a function of some sort so that my code would look something like this?
    Select Product, Time_ID, Amt
    From
    Execute myNestedSelectFunction
    But if Product was set to "No", I would want the following:
    Select Time_ID, Amt
    From
    Execute myNestedSelectFunction
    This would atleast ensure that I only have to go one place to maintain the logic of the "static Nested Select" statement.
    Just want to make sure I do not have a real viable alternative to "duplicating code"
    Thanks

    Hi,
    Look in TFM for PIPELINED functions which will allow you to:SELECT Product, Time_ID, Amt FROM TABLE(myPipelinedFunctionReturningSelectResult()) T;
    SELECT Time_ID, Amt FROM TABLE(myPipelinedFunctionReturningSelectResult()) T;There are samples if you look on AskTom too.
    Regards,
    Yoann.

  • How do you lookup multiple values in different columns based on variable criteria?

    Essentially, I'd like to be able to do a Vlookup but instead of searching for one value only, search for multiple values in separate columns. A smaller version of my current spreadsheet as an example...
    Attack Type ->
    Fire
    Water
    Grass
    Fire
    1/2x
    2x
    1/2x
    Water
    1/2x
    1/2x
    2x
    Grass
    2x
    1/2x
    1/2x
    Fire/Water
    1/4x
    1x
    1x
    Fire/Grass
    1x
    1x
    1/4x
    Grass/Water
    1x
    1/4x
    1x
    The headers are the attack types and the list of types to the left are the receiving Pokemon. Fire does half damage (1/2x) to fire types, Water does double damage (2x) to fire types, etc. I'd like to be able to search for specific damages for each type. For example, I'd like to find a Typing that recieves half (1/2x) damage from Fire-type attacks but also recieves double (2x) from Grass-type attacks. I do want more than just two search criteria though seeing as the actual table is much, much larger.
    I've tried assigning number values to each damage multiplier and then merging all of them together for a specific typing and doing a VLOOKUP based on checkboxes determining what damage multiplier I want in a few specific types, the rest being filled in to the standard of 1x but the result isn't correct most of the time.

    Hi Mitchell,
    VLOOKUP can be set for accept either an 'exact match' or a 'close match'.  Your 17 digit 'number' is actually a 17 character text string (Numbers can handle numbers to a precision of only 15 places). Provided all 17 digits are present, sorting should be the same as for numerical values—the leftmost character is the most significant.
    As a text string, your 'number' is sorted/evaluated alphabetically. A 'close match' accepts the 'largest value that is less than or equal to the search value'.
    If your search term is 000200000 (a 9 character string), several 'wrong' answers will fit the 'close match' criteria, including all of those listed below:
    000200000 (the 'correct' match)
    0000xxxxx (x may be any of the three acceptable values)
    0001xxxxx (x may be any of the three acceptable values)
    The main problem here is that digits in a number (or characters in a text string) have decreasing significance related to their distance from the beginning of the string/number. You want a search in which each character has the same significance as each of the others when compared to the search key. To do that, you need to compare each character in the search string with the character in the same position in the similar string for each type of Pokemon, then take a count of the matches or a sum of the differences.
    Here's one approach:
    Column A contains labels.
    Column B, the 17 digit search term, created in whatever manner you wish, and the similar 17 digit string for each of the characters.
    Columns C through S contains a formula that detines, using subtraction, the difference between each digit of the search term and the corresponding digit of each character's profile.
    Column C uses SUM() to calculate the total of columns C to S for each row.
    T1 uses =MIN(T) to calculate "least different" profile.
    Column A is a Header column; Row 1 is a Header row.
    Formulas:
    C2, and filled right to S2, then down to the last row of data:
    =ABS(MID($B$1,COLUMN()-2,1)-MID($B2,COLUMN()-2,1))
    T1: =MIN(T)
    T2, and filled down column T: =SUM(C2:S2)
    The conditional formatting rule set for all body cells in column T is shown below the table.
    This may be enough to get you started. Formulas can be tweaked to produce results more closely matching what you're looking for, if necessary.
    Regards,
    Barry

  • Allocation of material based on certain criteria

    Hi guys:
    one of the requirement is that to allocate inventory i.e parts allocated to sales orders based on following crirteria
    --> Priority Code assigned to customer ,
    -->Line item requested Ship date --( Oldest requested ship date first )
    --->Sales order number ---ie lowest sales ordr numbers first.
    All the above criteria work when backorders > available quantity and we need to satisfy all the customers.
    Any suggestions
    lot of MM and integratiion involved , how to handle this requirement in SAP?
    thanks
    sweth

    Sweth,
    To add to expert Mario's answer, there is a much more comprehensive suite of tools in APO for availability checking, including more standard controls upon how the order is/is not confirmed upon initial entry, and how existing confirmations may be re-sequenced.  Implementation of APO Global Available To Promise is not trivial, but it can help you avoid the use of the enhancements mentioned in his post.
    http://help.sap.com/saphelp_scm70/helpdata/EN/04/5e7237412a5249e10000009b38f842/frameset.htm
    Best Regards,
    DB49

  • How to not display certain items based upon certain criteria (Edit Form)

    I have a Edit form which was created from an interactive report I generated.
    There are 10 item fields which are listed which can be changed.
    Sometimes I want to see just 9 of the fields on the form based on what the value is of another field in the record.
    When I display the fields on the Interactive report I can filter this out by using a case statement, but how
    do I do this with the edit form as the query is not there.
    Thanks for your time in advance,
    Anon

    Use Conditions to control whether the item appears or not.
    In the item definition is a Conditions section where a large number of different types of condition can be used to determine whether the item is rendered. These include comparisons of the value of the item, or another item, items being null, and a lot of other options. Conditions are widely used throughout APEX&mdash;sometimes in subtle or noninuitive ways&mdash;so it's worthwhile studying how they're used.

  • Using two different datasource driver into a transaction

    Hi all,
    i have two database : one under Informix and another under Oracle.
    Well, well, i have declared two datasources in my apllicationserver ( Sun ONE 7).
    I have to use a session EJB to write into the two databases some data and i have to open an UserTransaction to deal with it.
    The flow is :
    - open the UserTransaction
    - Get the connection from the first datasource
    - launch the INSERT query in Informix
    - Get the connection from the second datasource
    - launch the INSERT query in Oracle
    My doubt is : Will the transaction work fine even if i have to use two different connection from two different datasources ?
    Using only one database the transaction work fine.
    Cheers.
    Stefano

    Hi,
    This will work correctly if you use XA drivers (XADataSource instances).
    You can check the vendor docs to see what exact classes you need to deploy for each database.
    Beware of the pitfall: if you don't use XA drivers then commit might very well appear to work, but rollback won't.
    Also, don't forget to close the connections.
    Hope that helps,
    Guy
    Atomikos TransactionsJTA - visit our new JTA forum at http://www.atomikos-support.com

  • ZSH using a different PS1 depending on hostname? [SOLVED]

    SOLVED
    Mikachu on irc.freenode.net #zsh gave me a good solution:
    case $HOST in
    TARDIS)
    hostcolor=blue
    CentzonTotochtin)
    hostcolor=cyan
    Highwind)
    hostcolor=white
    hostcolor=gray
    esac
    PS1="%{$fg[$hostcolor]%}%B%m%b%u%{$reset_color%}:%{$fg[green]%}%2~%{$fg[magenta]%}%%%{$reset_color%} "
    #PS1 thanks to Mikachu on irc.freenode.net #zsh
    /SOLVED
    A little background
    I've got around to setting up git in my home directory (leaving a '*' in ~/.git/info/exclude, and using 'git add -f $FILE') to make sure all my machines are using the same dotfiles, but I use a different PS1 based on what machine I'm using.  I'd love to have a single .zshrc I could drop into the git repo and use for all machines, as opposed to say, zsh evaluating a seperate '~/.PS1' I set up by hand on each machine.
    But getting to the point:
    My PS1 is this:
    PS1="%{$fg[cyan]%}%B%m%b%u%{$reset_color%}:%{$fg[green]%}%2~%{$fg[magenta]%}%%%{$reset_color%} "
    the only difference between the .zshrc on each machine is that the hostname is given a different color, so that the machine 'TARDIS' might have the hostname in PS1 as blue, machine 'Centzon' might have the hostname as cyan, and if the .zshrc is on any other host, the hostname in PS1 is just grey.  I'm not sure how to go about this with .zshrc, but here's a rough idea:
    eval hostname
    if hostname=TARDIS
    PS1="%{$fg[blue]%}%B%m%b%u%{$reset_color%}:%{$fg[green]%}%2~%{$fg[magenta]%}%%%{$reset_color%} "
    if hostname=Centzon
    PS1="%{$fg[cyan]%}%B%m%b%u%{$reset_color%}:%{$fg[green]%}%2~%{$fg[magenta]%}%%%{$reset_color%} "
    else
    PS1="%{$fg[grey]%}%B%m%b%u%{$reset_color%}:%{$fg[green]%}%2~%{$fg[magenta]%}%%%{$reset_color%} "
    Has anyone come up with something like this?  If not, how would I do something like this in ZSH?
    Last edited by 094TQ5 (2011-11-08 00:31:42)

    Well, there are different ways of achieving this.
    Solution 1:
    You can create a new output type which will be triggered and call a same driver program and the new smart form. I am sure you can customize as to what Purchasing document type will trigger which output type. Get in touch with someone in the function team to get this configured.
    Solution 2:
    No Customizing, let the configuration be the same, but in the driver program change the value of  "TNAPR-FONAM" immediately after the form entry_neu to the new form name based on the Purchasing document type.

  • How do I use a different browser then safari?  I have several sites safari won't connect to.

    How do I use a different browser then safari?  I have several sites safari won't connect to.

    I can connect to Bank of America's site just fine. Can you connect to the site or is it that you can't perform certain functions on the website? Do you know that there is a Bank of America App available?
    Bank of America for iPad for iPad on the iTunes App Store
    Bank of America Mobile Banking for iPad®
    If you download another web browser for the iPad, you use it just like you use Safari. Tap on the app icon to launch the browser and then use it like any other web browser.

  • HT5622 How do I change the Apple id against a certain telephone number?  I have two iPhones and wish to use a different Apple id for each and confused as to how I do this?

    How do I change the Apple id against a certain telephone number?  I have two iPhones and wish to use a different Apple id for each and confused as to how I do this?

    Create a new Apple ID for the second phone. If you are setting the phones up as new phone enter the ID you want to use on each phone.
    If both phones are already signed in to one Apple ID then use the settings app to change Apple IDs on one phone.
    Settings > iTunes and App Store > tap on the Apple ID > sign out > sign in with alternate Apple ID.
    Note that if you have downloaded apps with the original Apple ID on the phone with the new Apple ID, those apps will still be associated with the old Apple ID and will require the old ID and password in order to update them.

  • TS3297 i can no longer connect to itunes. a message comes up "we could not complete your itunes request. The itunes store is temporarily unavailable. please try again later. but when i use a different acct. it goes through right away . why did this start

    i can no longer connect to itunes. a message comes up "we could not complete your itunes request. The itunes store is temporarily unavailable. please try again later. but when i use a different acct. it goes through right away . why did this start happening?

    I don't know - but I am having the same problem and have not had any useful help from Apple Support.  Everything they told be to do has been done and it hasn't fixed the problem.

  • Using once created prepared statement with different connections in Oracle

    Can I use same statement cash using different connections in Oracle
    For example I have a prepared statement p1. After its using i close connection (return it to the pool)
    Next time I want use p1 statement using another connection.
    Question : When I creat p1 in second time ,is it returned from cash or created as a new statement. And what I should do to use once prepared statement using differend connections.
    Thaks.

    As far as I know a PreparedStatement lives and dies with the Connection that created it. So, you cannot use a PreparedStatement with other Connection instances than the one that created it.
    You will have to recreate the PreparedStatement for each time you open a connection, or use the same PreparedStatement and NOT close the Connection in between. The last suggestion can be risky though, if you never close the connection...
    Jakob Jenkov
    www.jenkov.com

  • JDev10g: Using a Tree component based on different queries.

    Hello,
    I've been doing some research on how to implement a tree component in ADF which I got working. However I need to implement a tree component that uses several different queries.
    The parent node would be one query, the child/leaf nodes would be based on another query but still related to the parent.
    For Example: 'select parent_nodes from mydatabase' then 'select child_nodes from mydatabase where child_nodesID = parent_nodesID'
    This will ultimately have to branch down more levels but I'm not sure exactly how to achieve this. I'm thinking I have to create new View Objects but I'm not sure exactly how to do that either.
    Thank you in advance.

    For an SQL query on a database use a View Object. First, you will need to create a new Entity object to represent each table in the database you need to use in the queries. Once you have created your view objects with their correct SQL queries, you need to specify how they are related. Example:
    RootView is all elements with ParentId of null.
    OtherView is all elements with ParentId not null.
    RootToOtherLink is a view link which links RootView.Id to OtherView.ParentId. You can specify this in the dialog. You will want to select all accessors available to make your life easier later, but make sure to name them something you will recognize, like "RootToOtherDestination".
    You will also need OtherToOther Link which links OtherView.Id to OtherView.ParentId. This starts the recursive nature of the hierarchical relationship.
    Once you have this set up, you will need to create an Application Module so that you have a data control you can bind your tree to. Set up the data model in a hierarchical fashion using your link.
    This will create a data control on the Data Controls pane you can drag onto your .jspx page. A menu will show up from which you can select tree component. This will take you to the tree binding dialog. Here is where all your work so far will pay off. You want to click the green plus button to add your RootView. Then, with the RootView selected you will want to hit the green plus again to select your destination accessor, such as "RootToOtherDestination" as mentioned earlier. This will show the OtherView as a child of the RootView. Finally, with OtherView selected you will want to hit the green plus again and select your other destination accessor, such as "OtherToOtherDestination". Select the attributes you want to have available to your tree at the bottom of the dialog and click ok.
    Your tree will show up. If you want to customize the way it looks or especially the attributes it displays in a node, those can be edited in the <af:tree> tag on your .jspx page.

  • Hi. I have temporarily moved away from home. I am using a different internet connection, and I have lost my bookmarks. How do I get them back?

    Hi. I have temporarily moved away from home. I am using a different internet connection, and I have lost my bookmarks. How do I get them back?

    Generally speaking, your bookmarks are private to your computer, and if you set up multiple Firefox profiles on your computer, to the one profile.
    Your bookmarks might be available to you at another location if you used the Sync service. In order to connect a new computer to the Sync service when you aren't near your old computer, you need a recovery key. https://support.mozilla.org/en-US/kb/share-bookmarks-tabs-and-more-your-other-computers#w_what-if-im-not-near-my-first-computer
    If you didn't use Sync or can't access your account, someone with access to your old computer could email you your bookmarks. Since there is a range of different ways to do that and the best choice might depend on what you can expect the person you ask to be able to do... could they start up Firefox in your profile and follow menu steps to export a file? Could they drill down into a hidden folder on the system, zip a file, and mail that to you? Etc.

Maybe you are looking for

  • IMovie 08 version 7.1 not responding - spinning rainbow

    Hello, It seems like there are a lot of people reporting that after the update to iMovie 7.1 - they can't use iMovie with their pre-existing data (pictures/movies/projects/preferences). Here are some steps to see if you have the same problem that I h

  • Change to payment card not saved

    I changed the credit card used to pay for my subscription on 20 July from Visa to Amex, but my subscription renewed on 23 July against the Visa. I have a £1 authorisation from "Ayden UK Ltd" showing on my Amex on 20 July so I know the details were ac

  • What is the class for creating the excel sheet in the java

    please say the class for creating the excel sheet in java (servlets,jsp)

  • Strange blue color

    Hello shooting many events, I frequently have problems rendering strong blue colour. The blue comes from these new LED lights. In Aperture it gets magenta and is seperated from the natural looking surrounding by a unnaturally looking harsh border. I

  • Password for Rawshooter Premium people

    I didn't get a password to license my free version of Lightroom 1.0. What should I do?