Advise on DB links in APEX

Hi,
I have installed apex on my test system in the same database where my original data resides and application is working fine.
Now for production my org dont want to install apex on the same db(server 1). They want me to install apex on separate db server (server 2) and refer it(server 1) using Database links from server2.
They dont want me to build any table related to apex or application logic in the original database(server1).
please advise ,What is the best way to do that...
Do i need to recreate the whole application using db links.
or is there any way to redirect to original db server(server1) from application server(server2).
Please help.
Thansk
Harinder

Hi ,
I want to execute the function using db link.
DB link is working fine for other tables.
create or replace synonym new_code for user.new_code@db;
select new_code from dual;
ORA-04052: error occurred when looking up remote object User.NEW_code@db
ORA-00604: error occurred at recursive SQL level 1
ORA-06544: PL/SQL: internal error, arguments: [55916], [], [], [], [], [], [], []
ORA-06553: PLS-801: internal error [55916]
ORA-02063: preceding 2 lines from db
Please advise.
Regards
Hsac

Similar Messages

  • Adding more Values to the Column Link in Apex

    Hi,
    Is there any possibility of adding extra or more values to the column link in Apex. I already have 3 Column Name and Values linked to a different report.
    Eg:-
    Column Link:
    Link Text : #COUNT#
    Name       Value
    DATE #DATE#
    PRICE #PRICE#
    COST #COST#
    I want to add one more Name like 'ID' and corresponding and Value #ID#.
    Please Help...
    Thanks in Advance..
    Edited by: user13561710 on Jan 10, 2011 9:20 AM
    Edited by: user13561710 on Jan 10, 2011 12:34 PM

    Thanks Varad,
    But it didn't worked, The page has option to link only 3 values.
    My Target is 'Page in this Application" not a URL.
    I used your format and if you apply changes and come back the whole thing is dissappeared and even the link to page in application is inactive.
    Is there any other way???
    Thanks
    Edited by: user13561710 on Jan 10, 2011 10:49 AM
    Edited by: user13561710 on Jan 10, 2011 12:35 PM

  • Need to wipe hard drive to restore to previous date from time machine back up.  Unclear how to do this.  Please advise or provide link to this procedure on website.  Thanks.

    Need to wipe hard drive to restore to previous date from time machine back up.  Unclear how to do this.  Please advise or provide link to this procedure on website.  Thanks.

    See Pondini's TM FAQs for starters.

  • How do you close a database link in Apex?

    How do you close a database link in Apex that is referenced in an interactive report on Page 1? I want to make sure the database link is closed before a user navigates to another page in the Apex application.
    Lets assume the database link is referenced in the region source for Page 1 as follows:
    Page 1 - Employee Listing
    Region Source:
    select ename, job, hiredate
    from scott.emp@link1
    Any suggestions are appreciated.
    Ms. H

    John,
    I figured out how to eliminate the ORA-02020 and ORA-02081 errors. The solution is reference below:
    1. Create an interactive report in a page.
    2. Add the SQL statement in the region source as listed below:
    SELECT ENAME, JOB, HIREDATE
    FROM SCOTT.EMP@DBLINK
    WHERE (UPPER(ENAME) LIKE '%' || UPPER(:P1_TEXT_SEARCH)||'%')
    Conditional Display
         Condition Type:
    PL/SQL Expression
         Expression 1
         :P1_TEXT_SEARCH IS NOT NULL
    3. Add a search button and text search field as items on the page.
    4. Create a process in the page to check the cursor and catch an exception as listed below:
         Name: CHECK_CURSOR
         Sequence: 30
         Point: On Submit - After Computations and Validations
         Type: PL/SQL Anonymous Block
         PL/SQL Process:
         FOR C1 IN (SELECT ENAME, JOB, HIREDATE
         FROM SCOTT.EMP@DBLINK
    WHERE (UPPER(ENAME) LIKE '%' || UPPER(:P1_TEXT_SEARCH)||'%'))
         LOOP
         IF C1.ENAME IS NOT NULL
              THEN
              HTP.P('Employee Name: '||C1.ENAME||' ');
              END IF;
         END LOOP;
         EXCEPTION
              WHEN NO_DATA_FOUND
              THEN
              APEX_APPLICATION.G_PRINT_SUCCESS_MESSAGE := 'No Data Found Error';
              WHEN OTHERS THEN
              APEX_APPLICATION.G_PRINT_SUCCESS_MESSAGE := 'Unexpected Error';
    Conditional Processing
    When Button Pressed (Process After Submit When This Button is Pressed)
         P1_SEARCH_DATA
    5. Create a process in the page to close the database link as listed below:
         Name: CLOSE_DBLINK
         Sequence: 40
         Point: On Submit - After Computations and Validations
         Type: PL/SQL Anonymous Block
         PL/SQL Process:
         COMMIT;
         EXECUTE IMMEDIATE 'ALTER SESSION CLOSE DATABASE LINK DBLINK';
    Conditional Processing
    When Button Pressed (Process After Submit When This Button is Pressed)
         P1_SEARCH_DATA
    6. Apply changes, run the page, and conduct a test.
    I hope this solution is helpful to others.
    Ms. H

  • Database link in Apex

    Hi,
    I have a problem with Database link in my application.
    Is their any way to Drop the Database link in APEX.
    Thank You,
    Edited by: Jahnavi on Nov 2, 2009 1:09 PM

    Jahnavi:Does this query creates a new connection every time I press the button? It depends on whether the local connection that handles your page request already has a connection open to the remote database. If a remote connection is open then the connection is re-used.
    Why would you want to terminate the database link ?
    Varad

  • Interactive report conditional display of link column - apex 4

    I create an interactive report
    select object_id,
           object_name,
           case
            when mod(rownum, 2) = 0
            then 'block'
            else 'none'
           end  display_link
    from user_objects
    where rownum <= 10in the Link Column for the report I selected one of the edit icons and put the following in the link attributes
    style="display:#DISPLAY_LINK#"I also edited the object_id and set the Column Link and selected an edit icon and put the same style in the link attributes.
    The link under the column displays correctly but the link for the report does not seem to substitute the #DISPLAY_LINK# from the report. Any Ideas?

    Here's how I've done this:
    SELECT ORG_ID,
           CLEARER_NAME,
           LEGAL_NAME,
           MARGINING_ACCOUNT,
           RULE_GROUP_DESCR,
           VIOLATION_COLOR,
           VIOLATION_LEVEL,
           CASE MARGIN_IND
            WHEN 'Y' THEN '&nbsp'
            ELSE '<a href="#" title="Ignore This Alert"><img src="/i/ice/images/hide.png" alt="Ignore"></a>'
           END AS IGNORE_LINK,
           ....This takes care of either showing (or not showing) the link.
    IN order to process when it is present, not that the address is "#" This will cause your cursor to change to a hand (or whatever your pointer is) when the mouse floats over the link. The actual transfer to the next page, I handle with jQuery/JavaScript.
    Create a Dynamic Action.
    Event: Click
    Selector Type: jQuery Selector
    jQuery Selector: 'aalt'
    Event Scope: Live
    (note that the jQuery Selector is finding the alt attribute that I set on my link in the SELECT above . Tweak as needed.
    This "Action" for this DA will be to "execute JavaScript code"
    Normally, I would set some values into Page Items and then create a branch to pass this values to the next page. I am doing the same thing in the following code. I am getting the values off of the row wherein the user clicked on the link. I am setting these values from the row into the page item values. Then, I am submitting the page. All the "htmldb_Get" business is just stuff that I have to do to get the page item values into the session (so that I can pass them to the next page).
    var clickedRow = this.triggeringElement.parentNode.parentNode.parentNode;
    var ruleGroupDescr = $(clickedRow).children('td[headers="RULE_GROUP_DESCR"]').html();
    var ajaxRequest = new htmldb_Get(null, $x('pFlowId').value, null, 0); 
    gReturn = ajaxRequest.get();
    $s('P31_RULE_GROUP_DESCR', ruleGroupDescr );
    ajaxRequest = null; 
    var clearerName = $(clickedRow).children('td[headers="CLEARER_NAME"]').html();
    var ajaxRequest = new htmldb_Get(null, $x('pFlowId').value, null, 0); 
    gReturn = ajaxRequest.get();
    $s('P31_CLEARER_NAME', clearerName );
    ajaxRequest = null; 
    apex.submit("IGNORE");Finally, just create a branch to the next page and set the items on the next page to the ones on this page that are being set in the above script. Note that in my example, I have set the request to "Ignore" when I submitted; so, I set the condition of my branch to be Request = IGNORE.
    Hope this helps,
    -Joe

  • Websheets: create link to APEX application in same workspace

    Hi all,
    I'm trying some things with websheets in APEX 4.0.2 and I'm getting quite satisfied about it.
    Let's assume I have this situation:
    app_id 110 : database application with alias MAIN
    app_id 120 : database application with alias SEC
    app_id 130 : websheet application
    They all use the same authentication function, which works fine.
    App 110 and 120 use the same authentication cookie and there are links between these two applications. No problem at all.
    Now, I want to include links to and from the websheet application.
    The link to the websheet is easy: ws?p=130:HOME:&SESSION. So far so good and no log-in required.
    A link from inside the websheet application to a database application is something else.
    I've already found how to use markup syntax to link to another page in the same websheet
    [[HOME | Home link]]and to an external website
    [[http://www.oracle.com | Oracle]]But I can't find the syntax to link to a database application in the same workspace as the websheet.
    I could use
    [[http://<myserver>.<mydomain>/apex/f?p=MAIN:HOME | Home application]]But this is not working flexible. I want to leave out everything before f?p
    If I would install these three applications on antother server, my link won't work anymore.
    Also, I can't find a way to include the session id. &SESSION. isn't working. So with the above syntax, I would have to re-login in my database application.
    Then I tried this
    [[f?p=MAIN:HOME | Home application]]But this isn't working at all. The websheet shows me the create page wizard and fills in the name of the page: f?p=MAIN.
    Can anyone help me out on this?
    Am I expecting to much from websheets at the moment, is this a missing feature or am I doing something wrong?
    Thanks in advance!
    Regards,
    Bart

    Hi,
    Sorry originally I thought you were linking to websheets not from, I don't think websheets have the same capability as a database application, so i don't think apex picks up on substitution strings. Im not sure how processing with websheets work, but I think its very minimal.
    Ive tried it myself, is there a reason you need the session? If I leave the session blank I can get back to the database application, I cant vouch if you're starting from your websheet but I imagine that apex will fill it in for you as its an apex url.
    Cheers
    Huia
    Edited by: Hoppy on 05-Jan-2012 14:48

  • URGENT Printing a BI publisher report from a column link in APEX

    I am developing an APEX report with a column link that will call a BI publisher report, the case is the link column in the APEX report will pass the item number to the BI publisher query.
    At the moment this is what I am doing:
    1- Create a hidden item on top of page zero. (e.g. PARAM1_VALUE)
    2- Create a report query and a report layout (For BI Publisher) in the Shared Components. (e.g ITEM_REPORT)
    3- Include the state session in the report query and reference that item in the query. (e.g. SELECT * FROM items where item_number = :PARAM1_VALUE)
    4- Create an APEX report displaying orders with the item number as a link column.
    5- In the Link column I set the report URL request to be "PRINT_SERVER=ITEM_REPORT".
    6- In addition I set the PARAM1_VALUE to be #ITEM_NUMBER# on the link.
    When I press on the link the BI publisher report prints but it doesn't display anything except the Headers, my understanding is that PARAM1_VALUE is not set with the item_number value when I press on the link and thus the query returns no results as when I remove the condition from the query i can see the report printing.
    Please help as this is urgent

    I opened the session and it is there with a proper value, it appears that whenever I enable the inclusion of session state in my shared components query the query returns no rows even if I am not using the item in the query.
    So if my query is "SELECT * FROM items" it will display nothing, the only way to get the report data back is to untick the inclusion of the session state and remove any reference to the item from my query, then I will get the report with all my data (which is NOT what I am trying to do).
    Thanks alot
    Khaled Jamoos

  • Database links in APEX - Inconsistent

    I have just set up a database link to our main Oracle DB from an APEX DB using the object browser in APEX
    The link works fine for retrieving data in some circumstances, a report is displayed with no problems and dynamic lookup lists work fine.
    However when I create a form and include an "Automated Row Fetch" there is a "PLSQL invalid error". My guess is there is some problem with privileges, I have little experience with this so was hoping for some help
    Regards
    - Sol

    Sol,
    I believe you can create a local view on the remote table and build the form on that view. See this and similar posts for hints: Use a database link in an Automated Row Fetch process? .
    Scott

  • Link to APEX app

    DB: Oracle 10.2.0.4.0
    APEX: 3.2.1.00.10
    My APEX app will be accessed from a non-APEX app, which already has authenticated the user. Since the user doesn't need to be presented with a login page again, I'm assuming that I need to create a Public page with a Hidden Item that will be populated with a hashed check value provided in the URL to the page. The value will then be "decrypted" by calling a Java stored procedure in the database to reveal the UserName and their Role. Once the UserName and Role has been determined, a page process will check a table to make sure that the username and role is valid. However, I still need some sort of authentication in APEX because the app is not actually public...we don't want anyone to access the app, just users that already have an account on a remote DB.
    Most of the examples I've seen on the forum are for apps that have their own table of usernames and passwords, but in my case each user that will be accessing this app already has their own Oracle UserId/password in another database. Would an authentication function need to include a query to the dba_users@remoteDB table to get the pwd for this userid? How to setup some custom authentication scheme that would automatically log them into my APEX app?

    Hi Dishoom,
    what you need to do is create a custom authentication / page sentry function which checks if your user is logged in. If everything is all right you let him proceed, otherwise the login-page is displayed automatically.
    Something like this: Link: [http://jastraub.blogspot.com/2008/03/ntlm-http-authentication-and.html] just not NTLM but your custom check.
    Have fun,
    Peter

  • BLOB content download link on apex report

    Hi Guys,
    I have a simple form where user can attach file and save the records. I iterate through wwv_flow_files and get the file and save it to a custom table which has BLOB column. On another report page i display uploaded file details. What i need is, there must be a column with download link when user clink the link appropriate file should be downloaded. How can i do this ?
    Really appreciate if someone can assist me on this.
    Thanks Guys.

    See About BLOB Support in Forms and Reports.
    There's an OBE tutorial that followed the introduction of declarative BLOB support in 3.1 as well. (An earlier version but it is still relevant to APEX 4.x.)
    (Please make an effort to consult the documentation and thoroughly search the forum for previous coverage of a topic. This is a much discussed question.)

  • Linking between ApEx applications without having to re-login

    Hi all,
    Application Express 2.1.0.00.39
    Oracle Database 10g Express Edition Release 10.2.0.1.0 - Product
    This is talked about all over the forums but I'm fairly new to this and can't seem to get it to work. e.g.
    Re: handling of authentication between applications
    shared session
    So I have three apps 103, 101, 102. App 103 has a tree which contains links to apps 101, 102. When I click these links however, I am required to log into each of the applications separately.
    Other posts say to ensure I'm using the same cookie and to add "&SESSION" to my link URLs.
    So here's my tree query in app 103 which generates the links:
    select "ID" id,
    "PID" pid,
    "NAME" name,
    'http://127.0.0.1:8080/apex/f?p=' || id || ':1' link,
    null a1,
    null a2
    from "#OWNER#"."ORHA_APP_HRCHY"
    When I add "&SESSION" to the end of the query I get:
    Bad Request
    The HTTP client sent a request that this server could not understand.
    What is the correct URL?
    I believe I'm sharing a cookie because all three apps have an autogenerated login process:
    wwv_flow_custom_auth_std.login(
    P_UNAME => :P101_USERNAME,
    P_PASSWORD => :P101_PASSWORD,
    P_SESSION_ID => v('APP_SESSION'),
    P_FLOW_PAGE => :APP_ID||':1'
    Or maybe that's wrong?
    I'm using database account authentication. Maybe that's the problem?
    Thanks,
    Craig

    Well it appears for one thing I missed the "."
    Re: Use SESSION variable in URL from HTML region
    Changing my tree query to the following seems to generate the appropriate url:
    select "ID" id,
    "PID" pid,
    "NAME" name,
    'http://127.0.0.1:8080/apex/f?p=' || id || ':1:&SESSION.' link,
    null a1,
    null a2
    from "#OWNER#"."ORHA_APP_HRCHY"
    But it still asks me to login to each...

  • Column Links in Apex Reports

    I am using version 4.0 of APEX.  My question concerns linking to other APEX pages from a report.  In APEX we link to another page, which may be a form or another report, by using a column in the report as a link column.  Any column may be used to transfer values from any other column.  This works fine, but the disadvantage is that whichever column is used as the link column has a heading which identifies the column's purpose but may not identify the purpose of the transition to another page.  In Oracle Forms, we could use buttons as a column of the multi-row screen (i.e. same as APEX report), and the button's label identified the purpose for the transition.
    Is there any way to create a column in an APEX report  to serve the same purpose as the button in Oracle Forms?

    Doug wrote:
    I am using version 4.0 of APEX.  My question concerns linking to other APEX pages from a report.  In APEX we link to another page, which may be a form or another report, by using a column in the report as a link column.  Any column may be used to transfer values from any other column.  This works fine, but the disadvantage is that whichever column is used as the link column has a heading which identifies the column's purpose but may not identify the purpose of the transition to another page.  In Oracle Forms, we could use buttons as a column of the multi-row screen (i.e. same as APEX report), and the button's label identified the purpose for the transition.
    Is there any way to create a column in an APEX report  to serve the same purpose as the button in Oracle Forms?
    When discussing "reports" it is essential to indicate whether this means a standard report or an interactive report in order to receive an appropriate response.
    It is possible to create a link column that is distinct from report data columns. In standard reports, this is done using the Add Column Link option from the Tasks menu in the right sidebar of the Report Attributes page. In interactive reports, define a Link Column on the Report Attributes page.
    To provide further information about links to users in both cases, specify an HTML title attribute for the link in the Link Attributes property of the link definition. This will be rendered as a tooltip when the cursor hovers over the link in visual browsers, and as an audio cue on navigation to the link when using a screen reader.

  • Column links in apex

    hello,
    I have a report in apex. the report shows first name, last name and telephone number.
    I wish to add another column - a link to other page to change the telephone number. but I want the link to be shown only for people who alredy have phone number.
    for example:
    first name: last name: telephone: link:
    Jon White
    Bill Smith 11111 edit(as link)
    I know how to add a column link, and I can write in the Link Text #telephone# but then the result will be:
    first name: last name: telephone: link:
    Jon White
    Bill Smith 11111 11111(as link)
    Do you know how can I do it?
    (btw I use apex 2.1)

    Try with a query like this.
    select fist_name,
    last_name,
    telephone,
    decode(telephone,NULL,' ','Edit') edit
    from emp;
    in the url: replace the page number (27) and the page items as you need.
    Mario.
    Edited by: mario1977 on Aug 15, 2012 3:05 PM

  • Broken image links on APEX 3.0 in Oracle 10g XE? Here's the solution

    You're on Oracle 10g XE and you've just upgraded your APEX from 2.0 to 3.0. You log into APEX Admin and there's tons of broken image links. You look into the Oracle documentation for APEX and it instructs you to copy the Images folder into your htmldb directory if you're using Oracle 10g standard, etc. But you're using Oracle 10g XE and there is no Images folder anywhere to be seen!
    HERE'S THE SOLUTION:
    http://daust.blogspot.com/2006/03/where-are-images-of-application.html
    Excerpt from the website:
    In OracleXE these resources (Images) are stored directly in the database, using the Oracle XMLDB feature. You can access the resources and modify them directly by using the WebDAV feature of the XMLDB.
    (1) With Internet Explorer, just go to File > Open > http://127.0.0.1:8080/i (check "open as webfolder")
    Then, copy the contents of your apex/images folder into this webfolder. It will take about 10 minutes. When it's done, refresh your Apex 3.0 website and lo and behold! Images! :)
    Be sure to thank Dietmar Aust for his solution to this problem, provided on his website: http://daust.blogspot.com/2006/03/where-are-images-of-application.html

    Another option: Try the Oracle Database XE and Application Express 3.0.1 install guide.
    C.

Maybe you are looking for