Pivot table and link to account record logs user out of OnDemand

All,
I have created a simple accounts report using a pivot table. I would like the user to be able to drill down on the detail account record. I followed the instructions in Doc ID 454434.1 that describes how to do this without using an action link.
From the example, I created the following URL and inserted it in the account name column under data format using custom text format. The account id is also included, but hidden in the report layout.
http://"@[html]"<a target=_top href=https://secure.crmondemand.com/OnDemand/user/AccountDetail?OMTHD=AccountDetailNav&OMTGT=AccountDetailForm&AccountDetailForm.Id="@">"@"</a>
The link is available in the finished report, but when I run the report from shared custom analyses and click on the link it logs me out of the application and returns me to the sign in page.
Any suggestions are greatly appreciated.
Thanks in advance,
Dan

Here's an attempt to post the entire url again:
"http://"@[html]"<a target=_top href=https://secure.crmondemand.com/OnDemand/user/AccountDetail?OMTHD=AccountDetailNav&OMTGT=AccountDetailForm&AccountDetailForm.Id="@">"@"</a>"

Similar Messages

  • Table for link between Accounting document and Billing document

    Which is the table for link between Accounting document and Billing document ?
    Thanks & Regards

    Ø Go to SE16N, enter table BSAD
    Ø In the Reference Field (VBELN) enter the Billing Document no. 
    Tips:
    Ø Make sure that only those billing documents will be considered whose accounting documents actually exists
    Ø No Accounting documents will be displayed for Credits, Free of charge orders and those acc. Documents which have been cancelled.

  • Using logged user detail from one table ,then use another table to link more details for same user ?

    Table 'user' fields:
    UserID* (Primary Key)
    Address
    FirstName
    LastName
    Email
    UserName
    Password
    UserLevel
    RegDate
    Table 'transaction' fields:
    transactionID* (Primary Key)
    MonthID
    UserID (Foreign Key)
    UserName
    transactionDate
    transactionType
    transactionAmount
    OpeningBalance
    Balance
    Desired output table (for the logged user):
    transactionDate
    transactionType
    transactionAmount
    OpeningBalance
    Balance
    My advance recordset details is like this :
    <?php
    if (!function_exists("GetSQLValueString")) {
    function GetSQLValueString($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "")
    if (PHP_VERSION < 6) {
    $theValue = get_magic_quotes_gpc() ? stripslashes($theValue) : $theValue;
    $theValue = function_exists("mysql_real_escape_string") ? mysql_real_escape_string($theValue) : mysql_escape_string($theValue);
    switch ($theType) {
    case "text":
    $theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
    break;
    case "long":
    case "int":
    $theValue = ($theValue != "") ? intval($theValue) : "NULL";
    break;
    case "double":
    $theValue = ($theValue != "") ? doubleval($theValue) : "NULL";
    break;
    case "date":
    $theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
    break;
    case "defined":
    $theValue = ($theValue != "") ? $theDefinedValue : $theNotDefinedValue;
    break;
    return $theValue;
    mysql_select_db($database_bankusers, $bankusers);
    $query_Recordset1 = "SELECT transactions.UserName, transactions.transactionDate, transactions.transactionType, transactions.transactionAmount, transactions.OpeningBalance, transactions.EndBalance, users.FirstName, transactions.transactionID FROM transactions, users WHERE users.UserName = transactions.UserName ORDER BY transactions.UserName, transactions.transactionID DESC";
    $Recordset1 = mysql_query($query_Recordset1, $bankusers) or die(mysql_error());
    $row_Recordset1 = mysql_fetch_assoc($Recordset1);
    $totalRows_Recordset1 = mysql_num_rows($Recordset1);
    ?>
    This enables me to pull all the records from both tables but not specific to the logged user.
    This is my problem. I would like the record to be pull is for the right user.
    I am not sure if the the problem is to do with Session variable MM_UserName as I have no idea how to include it in the advanced recordset box but i am not sure there is no missing session start on this page.  Your help or suggestion will be much appreciated.

    I am getting this error on the browser :
    You have an error in your SQL syntax; check the manual that corresponds  to your MySQL server version for the right syntax to use near 'ORDER BY  transactions.UserName, transactions.transactionID DESC' at line 1
    Here is my full code :
    <?php require_once('Connections/bankusers.php'); ?>
    <?php @session_start(); ?>
    <?php
    if (!isset($_SESSION)) {
      session_start();
    $MM_authorizedUsers = "";
    $MM_donotCheckaccess = "true";
    // *** Restrict Access To Page: Grant or deny access to this page
    function isAuthorized($strUsers, $strGroups, $UserName, $UserGroup) {
      // For security, start by assuming the visitor is NOT authorized.
      $isValid = False;
      // When a visitor has logged into this site, the Session variable MM_Username set equal to their username.
      // Therefore, we know that a user is NOT logged in if that Session variable is blank.
      if (!empty($UserName)) {
        // Besides being logged in, you may restrict access to only certain users based on an ID established when they login.
        // Parse the strings into arrays.
        $arrUsers = Explode(",", $strUsers);
        $arrGroups = Explode(",", $strGroups);
        if (in_array($UserName, $arrUsers)) {
          $isValid = true;
        // Or, you may restrict access to only certain users based on their username.
        if (in_array($UserGroup, $arrGroups)) {
          $isValid = true;
        if (($strUsers == "") && true) {
          $isValid = true;
      return $isValid;
    $MM_restrictGoTo = "loginuser.php";
    if (!((isset($_SESSION['MM_Username'])) && (isAuthorized("",$MM_authorizedUsers, $_SESSION['MM_Username'], $_SESSION['MM_UserGroup'])))) {  
      $MM_qsChar = "?";
      $MM_referrer = $_SERVER['PHP_SELF'];
      if (strpos($MM_restrictGoTo, "?")) $MM_qsChar = "&";
      if (isset($_SERVER['QUERY_STRING']) && strlen($_SERVER['QUERY_STRING']) > 0)
      $MM_referrer .= "?" . $_SERVER['QUERY_STRING'];
      $MM_restrictGoTo = $MM_restrictGoTo. $MM_qsChar . "accesscheck=" . urlencode($MM_referrer);
      header("Location: ". $MM_restrictGoTo);
      exit;
    ?>
    <?php
    if (!function_exists("GetSQLValueString")) {
    function GetSQLValueString($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "")
      if (PHP_VERSION < 6) {
        $theValue = get_magic_quotes_gpc() ? stripslashes($theValue) : $theValue;
      $theValue = function_exists("mysql_real_escape_string") ? mysql_real_escape_string($theValue) : mysql_escape_string($theValue);
      switch ($theType) {
        case "text":
          $theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
          break;   
        case "long":
        case "int":
          $theValue = ($theValue != "") ? intval($theValue) : "NULL";
          break;
        case "double":
          $theValue = ($theValue != "") ? doubleval($theValue) : "NULL";
          break;
        case "date":
          $theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
          break;
        case "defined":
          $theValue = ($theValue != "") ? $theDefinedValue : $theNotDefinedValue;
          break;
      return $theValue;
    mysql_select_db($database_bankusers, $bankusers);
    $query_Recordset1 = "SELECT transactions.UserName, transactions.transactionDate, transactions.transactionType, transactions.transactionAmount, transactions.OpeningBalance, transactions.EndBalance, users.FirstName, transactions.transactionID FROM transactions, users WHERE users.UserName = transactions.UserName AND users.UserName = $MM_UserName ORDER BY transactions.UserName, transactions.transactionID DESC";
    $Recordset1 = mysql_query($query_Recordset1, $bankusers) or die(mysql_error());
    $row_Recordset1 = mysql_fetch_assoc($Recordset1);
    $totalRows_Recordset1 = mysql_num_rows($Recordset1);
    ?>
    <!DOCTYPE HTML>
    <html>
    <head>
      <title>user summary</title>
      <meta name="description" content="website description" />
      <meta name="keywords" content="website keywords, website keywords" />
      <meta http-equiv="content-type" content="text/html; charset=windows-1252" />
      <link rel="stylesheet" type="text/css" href="style/style.css" title="style" />
    </head>
    <body>
      <div id="main">
        <div id="header">
          <div id="logo">
            <div id="logo_text">
              <!-- class="logo_colour", allows you to change the colour of the text -->
              <h1><a href="index.php">ModelOnline<span class="logo_colour">Bank</span></a></h1>
              <h2>Your. Bank. On. Demand.</h2>
            </div>
          </div>
          <div id="menubar">
            <ul id="menu">
              <!-- put class="selected" in the li tag for the selected page - to highlight which page you're on -->
              <li class="selected"><a href="indexoriginal.php">Home</a></li>
              <li><a href="register.php">REGISTER</a></li>
              <li><a href="login.php">lOGIN</a></li>
              <li><a href="aboutus.php">ABOUT US</a></li>
              <li><a href="contactus.php">Contact Us</a></li>
              <li><a href="cookies.php">Cookies</a></li>
              <li><a href="accessibility.php">Accessibility</a></li>
              <li><a href="security.php">Security</a></li>
            </ul>
          </div>
        </div> <div align="center" class="bankservices"><a href="http://www.modelonlinebank.com/bankproducts.php#one">Current Accounts</a> | <a href="http://www.modelonlinebank.com/bankproducts.php#two">Savings Accounts</a> | <a href="http://www.modelonlinebank.com/bankproducts.php#three">Mortgages</a> | <a href="http://www.modelonlinebank.com/bankproducts.php#four">Insurance</a> | <a href="http://www.modelonlinebank.com/bankproducts.php#five">Credit Cards</a> | <a href="http://www.modelonlinebank.com/bankproducts.php#six">Investments</a></div>
        <div id="site_content">
          <div class="sidebar">
            <!-- insert your sidebar items here -->
            <<h3>Latest News</h3>
            <h4>Personal Banking</h4>
            <h5>January 1st, 2014</h5>
            <p>Current Accounts,Saving Accounts,Range of Credit And Debit cards to suit all your needs. We have your interest in mine.<br />
            <a href="#">Read more</a></p>
    <p></p>
            <h4>Corporate Banking</h4>
            <h5>February 5th, 2014</h5>
            <p>We help you achieve your goals by providing numerous funding options.Provide Risk management of your finances and look for strategic and finance options to promote business.<br /><a href="#">Read more</a></p>
            <h3>Useful Links</h3>
            <ul>
              <li><a href="#">Credit card</a></li>
              <li><a href="#">Debit card</a></li>
              <li><a href="#">Loans</a></li>
              <li><a href="#">Insurance</a></li>
            </ul>
            <h3>Search</h3>
            <form method="post" action="#" id="search_form">
              <p>
                <input class="search" type="text" name="search_field" value="Enter keywords....." />
                <input name="search" type="image" style="border: 0; margin: 0 0 -9px 5px;" src="style/search.png" alt="Search" title="Search" />
              </p>
            </form>
          </div>
          <div id="content">
            <!-- insert the page content here -->
            <h1>Welcome <?php echo $row_Recordset1['FirstName']; ?>,to your control panel.</h1>
            <p><a href="logout.php">Logout</a> </p>
            <p>Summary of Last Transaction on our system:
             </p>
            <form name="form1" method="post" action="">
              <table border="0">
                <tr>
                  <th bgcolor="#D6D6D6">Date</th>
                  <th bgcolor="#D6D6D6">Transaction Type</th>
                  <th bgcolor="#D6D6D6">Transaction Amount</th>
                  <th bgcolor="#D6D6D6">Previous Balance</th>
                  <th bgcolor="#D6D6D6">Balance</th>
                </tr>
                <tr>
                  <td><?php echo $row_Recordset1['transactionDate']; ?></td>
                  <td><?php echo $row_Recordset1['transactionType']; ?></td>
                  <td><?php echo $row_Recordset1['transactionAmount']; ?></td>
                  <td><?php echo $row_Recordset1['OpeningBalance']; ?></td>
                  <td><?php echo $row_Recordset1['EndBalance']; ?></td>
                </tr>
              </table>
            </form>
    <p><a href="monthly.php">View Monthly Statement</a></p>
            <p><a href="paysomeone.php">Pay Someone</a></p>
            <p><a href="standingorder.php">Standing Orders</a></p>
            <p><a href="directdebit.php">Direct Debits</a></p>
            <p><a href="contactus.php">Customer Services</a></p>
            <p> </p>
            <p> </p>
    </div>
        </div>
        <div id="content_footer"></div>
        <div id="footer">
          Copyright &copy; Sundeep gurroby BCS PGD<a href="http://www.html5webtemplates.co.uk"></a>
        </div>
      </div>
    </body>
    </html>
    <?php
    mysql_free_result($Recordset1);
    ?>

  • HT203200 i have a windows 7 laptop, and my itunes account wont log in, it is logged in on internet explorer on the website but when i come to log in on the itunes software on the laptop it comes up with error (-51) i defo have the right password, help!

    i have a windows 7 laptop, and my itunes account wont log in, it is logged in on internet explorer on the website but when i come to log in on the itunes software on the laptop it comes up with error (-51) i defo have the right password, help!

    fighter19lisa wrote:
    that only makes it say its synced, when its not.
    No, it does not.  It transfers purchases from the iDevice to the computer.  The computer must be authorized for the Apple ID that the content was acquired with.
    fighter19lisa wrote:
    my playlists wont show up on the phone.
    Are they selected to sync?  Is Manually Manage content on the device selected?
    fighter19lisa wrote:
    i had to change my password for my aol account again and i still cannot get my email on my phone to even work
    What does that have to do with syncing content to the device?  FYI, nothing.

  • Pivot tables and charts error: Please load datasource first

    hi all,
    i am getting a error: please load data source first in rtf template , only for pivot table and charts(note: normal tables and fields i can insert )
    Please help me with this.
    Thanks and Regards
    Prakhar

    Well... if you think and try long enough, you may find the solution .
    The core problem is to reference to queried values not shown in the table/chart. And there IS a solution.
    Just use...
    NoFilter(RelativeValue([measure prior year_1];([year/month]);-12))
    ... instead of
    RelativeValue([measure prior year_1];([year/month]);-12)
    NoFilter enables RelativeValue to reference to values not present in a table or chart, but available in the report .
    From there on, you can define e.g. the starting point of the category axis of a chart by defining a local filter without losing values to be referenced .

  • MS Excel 2011 pivot tables and Lion

    Hi,
    I run quite a lot of spreadsheets with pivot tables in MS Excel 2011. With the most recent version of Snow Leopard and all the patches from Microsoft it seemed to be working quite well. The minute after the upgrade to Lion, when I tried to refresh a pivot table Excel crashed, and it is crashing on every single file that I have. I also created new files from scratch, ran a new pivot table, and the second time I open the file it would crash upon refresh.
    Apart from being extremely annoying, there seems to be no way around it for the time being; I really hope that with the next release of Office 2011 they fix it. Anyone has similar experiences or ideas?
    Thanks,
    Claudio

    This is absolutely a problem after insalling Lion!  Office 11 was a great improvement over office 08 to handle pivot tables and now pivot tables are basically useless on Office 11, running Lion.  I confirm that munipulating pivot tables in Excel 11 causes excel to crash every time.

  • A renter used my Apple TV to access Netflix, and now I can't log him out.  Besides calling the renter to ask him to fix this, how do I fix this?

    A renter used my Apple TV to access his Netflix movies, and now I can't log him out.  Besides calling the renter to ask him to fix this using his Netflix.com account, how do I fix this?

    There is no option in Apple TV to log out of Netflix.  The internet tells me to go to netflix.com to "Disconnect from All Devices".  I can't because I'm unable to log in to a renter's Netflix account.
    Why is there no option to log out when using Apple TV?  I can't ask my next renter to reset my Apple TV each time.
    jd

  • Linking multiple tables and Trying to insert records into Detail

    Hello,
    I have been struggling with this one for years...
    Work Order, Employee Labor, and Materials.  I then create a group headers using the Location field from the Work Order table.  I then create another Group, suppress the group name, and insert several fields from the Work Order table (work order number, wo description, status and completion date into Group 2 section.  Multiple rows of info are displayed.  I then enter some Employee Labor fields from the Labor table into the Details section (employee name, labor hours, pay rate, etc.).  I get several lines of employee labor transaction information grouped below each row of work order info from the Group 2 section.  So far, so good.
    Now I attempt to bring a field into the Details section from the 3rd table (Materials).  The moment I introduce the record, the rows of employee labor are duplicated over and over.  In fact, there are multiple duplicate labor transaction rows (over and over).
    What am I doing wrong???  I've tried every combination of Linking Order that I can think of...  I need help.
    Please reply.
    ps.  Let me know if I need to attach a screen shot.
    Thank you
    Robert

    hi Robert,
    this is a common issue when you add several details tables to a report. once you add the fields, then the sql generated will include those parent tables and you get a multiplier of records.
    my recommendation to you would be to use a subreport for the materials table instead.
    go to the Insert menu, choose Subreport and create a new subreport using the Wizard then add your current connection but this time only add the materials table. in the Linking tab, choose your Work order and then add the subreport to the Work order group header. now in the subreport add some fields from your materials table onto the subreport canvas.
    what this is essentially doing is a subquery to the database and returning all associated materials records based on a filter for the work order.
    the main report should not include any materials records and you can also remove this table from the database expert for the main report.
    i hope this helps,
    jamie

  • BI - ABAP To pick the field from One table and link with 2nd table

    Hello, I am stuck to write the correct abap code. Requirement is that My Client BMW  California require the below:
    <b>1.</b>  list of invoices (BELNR) that a has tcode = FB01 and FBVB" from Table BKPF.  Account Number field (BELNR) is there in 0fiap_4 Data source
    <b>2.</b> Now Link the above invoice Number (BELNR)  that a has tcode = FB01 and FBVB" from Table BKPF to BMW Custom Table I_BMW_WI. - Field "PAT ID" which is the cocatenation of OBJNR (Object Number), Invoice Number and Purchase Year.  where PICK only thos PAT ID where "TYPEID"  Value = "BMW" in table I_BMW_WI.
    To solve Number 1 Please fix my abap code and help me to write the Code to Solve Number 2 and Link #1 AND #2.
    Please help me soon
    Code # 1
    case I_datasource.
    WHEN '0FI_AP_4'.
    loop at C_t_data into l_s_DTFIAP_3.
    l_tabix = sy-tabix.
    clear I_BMW_WI.
    if sy-subrc = 0.
    select single * from BKPF into I_BKPF where BELNR = l_s_DTFIAP_3-BELNR.
    LOOP AT I_BKPF into I_FINAL WHERE
    Code below is not working
    (I_BKPF-TCODE = ‘FV50’) OR (I_BKPF-TCODE = ‘FB01’)
    I_FINAL-BELNR = I_BKPF-BELNR
    modify I_FINAL.
    endloop
    modify C_t_data from l_s_DTFIAP_3  index l_tabix.
    endif.
    endloop.
    endcase
    Code # 2 -
    Please help with templates.
    Thanks
    Soniya Kapoor

    Hi,
    Ad Code #1
    First of all the key for BKPF consists of:
    BUKRS, BELNR and GJAHR so I think you should use all key fields in your SELECT statement:
    select single * from BKPF into I_BKPF
    where BUKRS = l_s_DTFIAP_3-BUKRS and
          BELNR = l_s_DTFIAP_3-BELNR and
          GJAHR = l_s_DTFIAP_3-GJAHR.
    And why do you test SY-SUBRC after CLEAR ?
    Your IF statement should be after SELECT...
    And last but not least when you are using SELECT SINGLE you always get only one record so what is the purpose of LOOP statement ?
    Try following code:
    case I_datasource.
    WHEN '0FI_AP_4'.
      loop at C_t_data into l_s_DTFIAP_3.
        l_tabix = sy-tabix.
        select single * from BKPF into I_BKPF
          where BUKRS = l_s_DTFIAP_3-BUKRS and
                BELNR = l_s_DTFIAP_3-BELNR and
                GJAHR = l_s_DTFIAP_3-GJAHR.
        if sy-subrc = 0.
          if (I_BKPF-TCODE = ‘FV50’) OR
             (I_BKPF-TCODE = ‘FB01’).
            I_FINAL-BELNR = I_BKPF-BELNR
            modify I_FINAL.
          endif.
          modify C_t_data from l_s_DTFIAP_3 index l_tabix.
        endif.
      endloop.
    endcase.
    regards
    Krzys

  • OIM11gR2 - API - how to create accounts and link them to an oim user

    hi,
    my problem is the following:  I would like to import a lot(1000+) of different service accounts to my oim system and link them to oim users.
    at the moment, the information which service-account belongs to which person is stored in a textfile.
    I use this API code to create accounts:
    ProvisioningService service=getClient().getService(ProvisioningService.class);
    ApplicationInstanceService service=getClient().getService(ApplicationInstanceService.class);
    ApplicationInstance appInstance=service.findApplicationInstanceByName("LinuxServer001");
    FormInfo formInfo=appInstance.getAccountForm();
    String formKey=String.valueOf(formInfo.getFormKey());
    AccountData accountData=new AccountData(formKey,null,null);
    Account account=new Account(appInstance,accountData);
    account.setAccountType(Account.ACCOUNT_TYPE.Primary);       
    service.provision(userKey, account);
    this works fine! the account is displayed in the section  "user accounts", but the status of the created account is "Provisioning".
    when I reconcile this linux server, oim doesn't establish a link between the service account on the target system and the created account! why?
    how can i solve my problem? which information is missing, to establish a link between an existing account on a target system and an api created account?
    thank you!
    br,
    max

    Thanks, Brian, for your support! - It's working.
    It's hard to understand why NI did not pass this parameter to the top of the call chain...
    I also needed some time to understand the syntax of the string passed to the subaddress node:
    The name of the worksheet needs to be framed by single quotation marks and the following cell address must preceeded by an exclamation point (!).
    A working link pointing to cell "A1" of "Worksheet 1" looks like:
    'Worksheet 1'!A1
    Maybe also of interest: If you want to point the link to a worksheet inside the document itself, the parameter "address" (URL of link - href) can be left empty.
    Thanks and Regards,
    Ingo

  • Link from Account record to specific report

    Hi,
    I have created a single account overview report. Now I want to link from specific account records to that report (embedded analytics).
    I have set up the web link but need to change either the link or the report so that it is generated only for the specific account record from where I have clicked the link.
    Ideas are highly appreciated.
    Thanks!
    Søren

    Søren,
    I have a document that details how to link a report to a webapplet so for each account record you get a report based upon that account. I'm happy to send it to you, but do not want to be spammed, so email me at alex.neill@ (use Homepage details on my profile)
    regards
    alex

  • Pivot table and Firefox 3.6,

    Hi,
    I have find a issue in pivot table,
    I have made a very simple pivot table, with filter region enabled.
    I’m using jdeveloper 11g release 1.
    When you execute it in firefox 3.6 you can't move the columns or rows. If you look at the error console of firefox you find an error in javascript:
    Error: x5.ownerDocument.getBoxObjectFor is not a function
    Archivo de origen: http://127.0.0.1:7101/UsoCanalesRelacion-ViewController-context-root/afr/partition/gecko/default/opt/core-SHEPHERD-PS1-9296.js
    Línea: 6166
    If I execute it in explorer 8, it works fine.
    Is a bug???
    A bad configuration of firefox??
    Thanx

    You hit the drag and drop bug in FF3.6. D&D in ff3.6 together with adf rich faces does not work right now :-(
    Timo

  • How to get orphan records in Wf_notifications table and how to purge records in WF notifications out table

    Hi Team,
    1) I need Query to get the orphan records in the wf_notification tables to purge them.
    2) Same way I need to purge unwanted records in WF NOTIFICATION OUT table.Can you please let me know the process to get unwanted records in
    WF NOTIFICATION OUT table and the process to purge them.
    Thanks in Advance!
    Thanks,
    Rakeesh

    Hi Rakeesh,
    Please review notes:
    11i-12 Workflow Analyzer script for E-Business Suite Workflow Monitoring and Maintenance [Video] (Doc ID 1369938.1)
    bde_wf_data.sql - Query Workflow Runtime Data That Is Eligible For Purging (Doc ID 165316.1)
    What Tables Does the Workflow Purge Obsolete Data Program (FNDWFPR) Touch? (Doc ID 559996.1)
    Workflow Purge Data Collection Script (Doc ID 750497.1)
    FAQ on Purging Oracle Workflow Data (Doc ID 277124.1)
    Thanks &
    Best Regards,

  • Project related tables and link for services in Network Activity

    Dear Experts,
        My requirement is I need a table for services in Network activity before release of Network and link for services to another table(Project related before PR).
    Ex : Network             Activity           Service         
            XXX                     XX                   12345
          So I need Service  field, which is updating in ESLL was unable to link with another table to get the Project Number. So please help me .
    Regards,
    Srikanth.

    Dear sushrut sheth,
    thank for the reply
    I looked in AFVC before to post the Issue but in this table the Activity is only updating but not the individual service items
    I required the table which is updating the individual service line items

  • Query a table and exit when first record found

    I want to query a table and just want to know if any rows matching my query criteria exist in the table. I just want to find one row, irrespective of order and stop the query right there. How do I do that?

    The most efficient way would be either to use rownum = 1 as part of the condition in your second query, but, as written, both will return multiple rows. Your first will need to have an additional predicate and rownum = 1 in addition to the exists.
    Assuming that the predicate can use an index, then the most efficient approach would be either:
    SELECT 1 FROM table
    WHERE <conditions> and
          rownum = 1or possibly:
    SELECT 1 FROM dual
    WHERE EXISTS (SELECT 1 FROM table
                  WHERE <conditions>)Both will do a range scan on the applicable index, stopping when the find the first matching entry. To my mind, the first is clearer in intent.
    To illustrate the error in your first query, consider:
    SQL> SELECT * FROM t;
            ID DESCR
             1 One
             2 Two
             3 Three
             4 Four
             5 Five
             1 One
             2 Two
             3 Three
             4 Four
             5 Five
    SQL> SELECT * FROM t
      2  WHERE id = 1 and
      3        rownum = 1;
            ID DESCR
             1 One
    SQL> SELECT * FROM t
      2  WHERE EXISTS (SELECT 1 FROM t
      3                WHERE id = 1);
            ID DESCR
             1 One
             2 Two
             3 Three
             4 Four
             5 Five
             1 One
             2 Two
             3 Three
             4 Four
             5 FiveJohn
    Edited by: John Spencer on Oct 2, 2009 12:06 PM
    Added queries from t

Maybe you are looking for