Disadvantage of 'QUERY ALL RECORDS' set to YES in DATA BLOCK

Dear all,
Can any one tell me disadvantage of 'QUERY ALL RECORDS' set to YES in DATA BLOCK. I have made a datablock 'QUERY ALL RECORDS' set to YES becoz of requirement 'restrict duplicate data entry'.For your information
my datablock is multi record.
Than You

What if you have 1,000,000 records in your table and you query all records. Ouch!
restrict duplicate data entryThat is standard database functionality: primary or unique key on the table.

Similar Messages

  • SQL Query to retrieve the All records based on the Max Dates.

    Hello all,
    I am trying to retrieve the newest record based on the date field (  nextDate  ).
    Currently there are only 4 records in the MC_Maintenance table and two in the Machine table.
    Machine table
    MC_id             EquipID          
    1                      0227
    MC_id             EquipID
    2                     0228
    MC_Maintenance table
    Maint_id           MC_id             Next_maint                  
    1                      2                      08/25/2010     
    2                      2                      07/01/2010
    3                      1                      06/11/2010
    4                      1                      07/11/2010
    What I  am trying to accomplish is,
    list the two machines from the Machine table with the MAX(Next_maint) controlling the MC_Maintenance output list
    These are the records that I would like to Display.
    Maint_id           MC_id             Next_maint                  
    1                      2                      08/25/2010
    4                      1                      07/11/2010                 
    Below is the SQL Query
    SELECT
           MC.MC_ID as ID,
            MC.complete_Date as completed,
            MC.next_maint as nextDate,
            MC.maint_notes as Notes,
            MC.facility as Facility,
            M.EquipId,
            M.name as name,
            M.SerialNumber as SN,
            M.dept as dept,
            M.Freq as freq
            From  MC_Maintenance MC, Machine M
            where  MC.MC_ID =  M.MC_ID
    '           USING MAX(nextDate )
    Any ideas would help.
    TJ

    I would have thought that was a simple group by problem?
    SELECT M.EquipID, MC.MC_ID, Max(MC.next_maint)
    FROM MC_Maintenance MC INNER JOIN Machine M ON MC.MC_ID = M.MC_ID
    GROUP BY M.EquipID, MC.MC_ID

  • Query from a NTB item to retreive data block

    I have two NTB text items. first i have enter values in, then i would like to take these values to query my block (table view)
    the context of my form is:
    Office{ salesmen---->{Agencies---->{customers and so one.
    in my form I would like to allow to the user to enter the office code (from listArea) and choose the salesman code(from a LOV). (this part i got it).
    From both values office code and salesman code I want to retreive all agencies, customers products and display them on my block.
    the second is:
    If i can do that, i would like to put a checkbox(table view) in front each row, so when i'll check a row I could take some values and query another table to display a detail form on new canva for this row.
    I know I ask a lot, but you know i'm new in the oracle world
    thanks

    For your first requirement: Use a Pre-Query trigger to test if your Non-Base Table (NBT) items have values. If yes - use the SET_BLOCK_PROPERTY() built-in to add the values of these items to the default where clause of the base table block. For example:
    /** Pre-Query trigger */
    DECLARE
       vDefWhere      VARCHAR2(500) := GET_BLOCK_PROPERTY('PARENT_BLOCK',DEFAULT_WHERE);
    BEGIN
       IF ( :Control_block.C$Office_code name IS NOT NULL ) THEN
          /* Assumes there is an existing WHERE Clause */
          vDefWhere := vDefWhere|| ' AND OFFICE_CODE = :control_block.c$office_code';
       END IF;
       IF ( :Control_block.C$Sales_code IS NOT NULL ) THEN
          vDefWhere := vDefWhere||' AND SALES_CODE = :control_block.c$sales_code';
       END IF;
    END;As to the your second request, why not design your form so you have a section where you select your criteria, a section that displays the queries Parent record and then a section that displays the related Child data. Then create a relationship (see the relationship code of the BLOCK in the Forms Navigator) between the Parent block and the Child block. The relationship will handle synchronizing the Child block with the Parent block as the user navigates through the different Parent records. Your form would like something like this:
    |---------------------------------------------------|
    |  Office Code[       ]  Sales Code[       ]        |
    |                                                   |
    |--Parent Data--------------------------------------|
    | Office Code  Sales Code  Item1   Item2   Item3    |
    | [          ] [         ] [     ] [     ] [     ] ^|
    | [          ] [         ] [     ] [     ] [     ] v|
    |                                                   |
    |----Child Data-------------------------------------|
    |                                                   |
    | Child1          Child2      Child3      Child4    |
    | [             ] [         ] [         ] [     ] ^ |
    | [             ] [         ] [         ] [     ]   |
    | [             ] [         ] [         ] [     ]   |
    | [             ] [         ] [         ] [     ]   |
    | [             ] [         ] [         ] [     ] v |
    |---------------------------------------------------|When the user selects an Office and Sales Code - the Parent record will be queried. The relationship will automatically query the child records and display the results in the Child Data section of the form. If the user selects the second Parent record the relationship automatically queries the child records and displays them in the Child Data section again. This makes for an easier form to develop and maintain.
    Hope this helps.
    Craig...
    -- If my response or the response of another is helpful or answers your question, please mark the response accordingly. Thanks!

  • Execute query. Not all records retrieved.

    Hi everyone.
    I have made a screen with the data block and layout wizzards.
    When I click on the default toolbar "Execute query" it brings only 68 records and there are about 25,000!.
    I have a botton which displays a LOV of the same table and the LOV is working well, it brings all the records in the table.
    Any idea ???
    Thanks!

    If you go to the bottom of the query, does
    it get the next set of records??
    Oracle forms buffers the records it gets
    based upon the number of records buffered
    in the "block properties".
    Go to block properties. Look at Number of
    records buffered. If you want it to get
    ALL records. Set the Query ALL records switch
    to "Yes". Try it again.
    Hopefully this helps.

  • Return amount of records after query multi-record block

    Hello,
    I would like to have a restriction in my multi-record form that counts the amount of returning records (after execute_query). If the amount is >= 1000 then I have to raise an error.
    How can I implement this?
    Best regards,
    Ronny.

    It most cases forms doesn't return all rows to the user in a batch unless the block property Query-all is set to yes. But if you have sum items based on that block, you have to set it to Yes. If you can turn this flag off and change the Query Array Size (block property) to 0 or something small (like 20), you dont have to worry about how many rows the query is going to return.
    In you case, sounds like you want the user to put more constraints if rows returning > 1000 and you probably dont want the user to ever look those rows. You can do a
    select count(*) from your_table
    where --your critera
    and rownum < 1001
    before execute the query. But this select might take
    a while if you table is very big in oracle 9i.
    The easiest thing is to turn off the Query-All switch, let the forms handle the query and let the user decide whether to refine the query.

  • Form does not display all records from table

    Hi guys
    I modified one form that was based on a signle DB table. I removed certain fields from the table and added some extra fields to that table. Then based on the new table I also modified the form and removed the text items related to old fields in the table and added new text items pointing to the new fields now. II have checked all the new items properties and they have don't seem to be wrong or so. But now the problem is the form does not display all the records from the table. before it used to display all records from the table when qureied but not now. It only certain records from the table containing all new data and also old data but the form does not display other records though I don't see any obvious discrepancy. Remember that the before doing the modifications, I have table back for the old, created another table that contained new records for the new fields, and then I inserted the old records and updated the new table data in the new table with these new table values. So this way I have got my new table. Could someone help why the new modified form fails to display all records from the new table updated table though it display some of them successfully.
    Any help will be appreciated.
    Thanks

    hi
    Set the block property of "Query All Records" to "YES"
    hope it will work.
    Faisal

  • Comparing a record set

    I am trying to compare if a record set has been changed by a
    user during a forms session. The record set has over 70 columns.
    My solution is to query the record set in pre-update trigger and
    re-query the record in post-update trigger and compare for any
    change. In order to compare, I have to write over 70 IF statements.
    Is there a better way to do this?
    thanks in advance!

    May be that:
    loop
       v_name := :system.cursor_item;     
       v_r := name_in(v_name);     
       -- you check, you have name item and value
       exit when replace(v_name, 'BLOCK1.', '') = Get_Block_property('BLOCK', Last_Item);     
       next_item; 
    end loop;    

  • Retrieve All records and display in Report using CAML query in Report Builder if Parameter value is blank

    Hello Experts,
    i have created a report where i have one parameter field where user will pass parameter(e.g. EmpId). As per parameter record will fetched to report if no parameter is passed then it will display all records. I have done it by taking SqlServer Database as datasource.
    by using Following method
    Now i would like to do it by taking Sharepoint List as Datasource. For that what would be the CAML Query.
    Here is my existing CAML query.
    <RSSharePointList xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
      <ListName>Employees</ListName>
      <ViewFields>
        <FieldRef Name="Title" />
        <FieldRef Name="FirstName" />
        <FieldRef Name="LastName" />
        <FieldRef Name="FullName" />
        <FieldRef Name="UserName" />
        <FieldRef Name="Company" />
      </ViewFields>
      <Query>
        <Where>  
    <Eq> 
        <FieldRef Name="Title" />
      <Value Type="Text">    
       <Parameter Name="EmployeeId"/>    
    </Value>
    </Eq>                  
        </Where>
      </Query>
    </RSSharePointList>
    The above code is working if i am passing an employeeId to Parameter. If nothing is passed, it is Not retrieving any record.
    Please suggest
    Thank you
    saroj
    saroj

    Your problem follows the well-established pattern of using an "All" parameter filter in SSRS. There are a few approaches depending on the size of your data. The easiest one is to return all data from CAML and then filter it within SSRS, the following thread
    provides some examples,
    http://stackoverflow.com/questions/18203317/show-all-records-some-records-based-on-parameter-value.
    Other options include passing all of the possible values within the CAML query when "All" is selected, using multiple Report Files to distinguish between both CAML queries, or to use multiple datasets with some logic to show/hide the correct one.
    Dimitri Ayrapetov (MCSE: SharePoint)

  • Personnel Admin AdHoc Query not retrieving all records

    Hi, I recently added a custom info type to a copy of the SAP ad hoc query for Personnel Admin by using the menu path in SQ02>Edit>Change Infotype selection . The query is picking up the new info type and runs fine but does not retrieve all records from the table for a given personnel id. It only retrieves 1 record per id.
    Has anyone dealt with this before and have an easy/quick fix for this?

    Have other users try the query, preferably a user with end user authorization.
    I've had this issue before, I'm an IT person and I customized a Standard infoset.
    During testing, I'm only getting 1 (in my case) Insurance record per employee.
    The end user can see multiple record per employee.
    Btw, did you customize a Global or a Standard Infoset?
    Regards,
    Olekan

  • What PS table has the list of all records in a particular query tree?

    We are going through an upgrade to HCM 9.0 and need to get a list of all records in our many query trees.
    Thanks in advance
    Allen Cunningham
    DBA - Sonoma State University
    PS 9.0
    Oracle DB

    The details of query trees, like any winter tree, are stored in the PSTREENODE (PSTREENODE and PSTREELEAF for summer trees).
    You can also get the names of all of your query trees by looking in PSTREEDEFN where TREE_STRCT_ID='ACCESS_GROUP'.
    Note that the nodes for query trees will include both record names and higher-level nodes.
    Regards,
    Bob

  • How to make this work selecting advanced record set dreamweaver complains and crashes all the time

    Hi There
    I have met a person who does php and sql work but not with dreamweaver. The code I have works but dreamweaver shows me an error with my record sets and it crash all the time.
    <?php require_once('../Connections/datexdatabase.php'); ?>
    <?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;
    if($_GET['pageID']==''){
        $pageId = 1;
    }else{
        $pageId = $_GET['pageID'];
    mysql_select_db($database_datexdatabase, $datexdatabase);
    $query_rsIndex = "SELECT pages.title, pages.meta_keywords, pages.meta_description, content.header, content.`description`
    FROM pages INNER JOIN content ON pages.id = content.page_id WHERE pages.id = ".$pageId." ORDER BY content.order";
    $rsIndex = mysql_query($query_rsIndex, $datexdatabase) or die(mysql_error());
    $row_rsIndex = mysql_fetch_assoc($rsIndex);
    $totalRows_rsIndex = mysql_num_rows($rsIndex);
    ?>
    <?php do { ?>
            <?php if($row_rsIndex['header'] != 'Introduction'){ ?>
            <b><?php echo $row_rsIndex['header']; ?></b>
            <?php } ?>
            <p><?php echo$row_rsIndex['description']; ?></p>
            <?php } while ($row_rsIndex = mysql_fetch_assoc($rsIndex)); ?>
    <?php
    mysql_free_result($rsIndex);
    ?>
    I am able to join the tables in the advanced recordset but i am getting confused with "" FROM pages INNER JOIN content ON pages.id = content.page_id WHERE pages.id = ".$pageId." ORDER BY content.order";"
    mysql_select_db($database_datexdatabase, $datexdatabase);
    $query_rsIndex = "SELECT pages.title, pages.meta_keywords, pages.meta_description, content.header, content.`description`
    FROM pages INNER JOIN content ON pages.id = content.page_id WHERE pages.id = ".$pageId." ORDER BY content.order";
    My question is how can I use dreamweaver with the advanced recordset with the pageID without dreamweaver crashing 20 times a day
    Regards

    My question is how can I use dreamweaver with the advanced recordset with the pageID without dreamweaver crashing 20 times a day
    Do you get any errors in Dreamweaver when it crashes?
    What version?
    What OS?
    Have you tried trashing recreating the user config folder ( http://kb2.adobe.com/cps/405/kb405604.html#main_user_config )?
    Have you tried trashing the preferences ( http://kb2.adobe.com/cps/839/cpsid_83912.html )?
    Has anything changed on the system recently (from program installs, to system / OS updates)?
    Have you tried creating a new user account on the system to verify there is no corruption in the current user's system data?

  • Returning all records for a query

    Hi,
    still working on this library. I have the majority of it working (not pretty but it works). One problem I have run into is that when I query an authors name I would like all records for that author to be shown. However, it is only showing the final record.
                   public void Search_a()throws Exception{
              String S_author1 = JOptionPane.showInputDialog(null,"Please enter the authors name");
                   String query = ("select * from library where Author=('"+S_author1+"')");
                   ResultSet rs = db_statement.executeQuery(query);
                   while (rs.next()) {
                  String s = rs.getString("Author");
                  output.setText(rs.getString("ISBN")+"\t"+rs.getString("Title")+"\t"+ s +"\t"+ rs.getString("Publisher")+"\t"+rs.getString("Genre")+"\t"+rs.getString("Details")+"\n");
              }//end while
         }// end search_aI cannot see where the error is. I think maybe I am overwriting the previous records but thought that the inclusion of +"\n" would force each result to a new line.
    Any ideas?

    Thanks for that. Not really sure how I would implement that (new to programming) but I have managed to solve it using               output.setText(output.getText()+rs.getString("ISBN")+"\t"+rs.getString("Title")+"\t"+ s +"\t"+ rs.getString("Publisher")+"\t"+rs.getString("Genre")+"\t"+rs.getString("Details")+"\n");Thanks for the reply though.

  • Search query returning ALL records

    DW CS3 - MS Access - ASP/VBScript
    I have a search form for records to display on the same page with keywords highlighted.  The search is returning ALL records and highlighting keywords throughout rather than returning specific records with the searched word.  What am I missing?  I'm sure it's something terribly simple.....
              <input name="search" type="text" id="search" value="<%= Request.QueryString("search") %>" />
              SELECT item, item, item, item
              FROM tbl_name
              WHERE item OR item OR item LIKE %MMColParam%
              ORDER BY sql_orderby, Date DESC
              Name: MMColParam
              Type: Text
              Value: Request.Querystring("search")
              Default Value: %

    I was using the word "item" as an example for multiple columns without actually naming them - they are not the same.  I should've used this example:
    SELECT shoes, socks, hats, gloves
    FROM tbl_apparel
    WHERE shoes OR socks OR hats LIKE %MMColParam%
    ORDER BY sql_orderby, Date DESC
    In the past, I had four duplicate query parameters for four columns which worked fine.  But since I only have one search term, I thought I could eliminate three of the duplicate parameters and use just one with the OR statement.
    In the past, you questioned me on this.  You stated, "You only have one search term and so all of the parameters have the same value, but DW still wants to creates 4 parameters. If you were coding this by hand you wouldn't do it that way, but DW's one-size-fits-all code generates four seperate parms. It's nothing to worry about."

  • Query not displaying all records when execute it first tme

    Hello,
    i have an issue with the WEBI report.when i run  the report first time it's displaying only few records, but when i run the same report second time it's displaying the more records and it's correct.
    Could any one tell me why it's not displaying all records when i execute first time.
    Thanks in advance for your help.
    Regards,
    Prathap

    Which BOBJ version do you use?
    Which kind of data source are you retrieving data from?
    Regards,
    Stratos

  • Query in SQL to display count of all records but where condition is present

    Hi All,
    I have situation where I need to display count of all records all particular period but in where condition type condition has to be present :
    Please find the below sample data :
    PERIOD_ID     TYPE     MV_COUNT     IS_FLAG
    20110401     AM     1     0
    20110401     AM     1     0
    20110401     MS     29     0
    20110501     MS     1     0
    20110601     MS     14     0
    20110701     MS     2     0
    20110401     MS     1     0
    20110401     AM     2     0
    20110401     AM     69     0
    20110401     AM     2     0
    finally I need for type = MS
    i) total is_flag count for all the periods
    ii) for period=20110501 what is the mv_count
    I need to use the table single time (ie not self join outer joins )
    I have tried to use partition by clause but it will filter out the data .
    Cheers,
    Sp

    842106 wrote:
    finally I need for type = MS
    i) total is_flag count for all the periods
    ii) for period=20110501 what is the mv_count
    I need to use the table single time (ie not self join outer joins )
    I have tried to use partition by clause but it will filter out the data .
    select sum(is_flag) is_flg_count,
             sum
                 case when period = 20110501 then mv_count else 0 end
                ) mv_cnt_for_20110501
    from your_table
    where type = 'MS';

Maybe you are looking for

  • Black screen after logging in KDE (dual monitor)

    Hi everybody, I'm having a severe problem with kde 4.12.2; I'll explain my settings: 1) A screen 2560x1440 on DVI 2) A screen 1920x1080 on VGA My /etc/X11/xorg.conf is this Section "Monitor" Identifier "DVI-I-1" Option "Primary" "true" Option "Prefer

  • Load Masterdata with Infopackage and DTP..Is there any other way simplier ?

    Dear all: We are currently working under BI 2004s SP09. And we are trying to loading Masterdata from R3. For Attributes and text, we have to create Infopackage for DS, load data from R3 into PSA(Not able to into Char directly), then create transforma

  • Primary use of creating a Recurring Document in GL Master

    Dear all, What is the primary use of creating a recurring document in GL master as opposed to sample document? Will this enable the end user to post certain transactions like Rent automatically?

  • External link to webhelp, view TOC

    Hi, is it possible to automatically view the toc pane when linking from an external html file? On our intranet, a lot of pages are not compiled with robohelp, they are Word--> html pages, but we do link from those pages to the robohelp webhelp. By de

  • Smart Collections

    I installed version 4 upgrade.  The colletion name is visable and the film strip is there but no actual photos.   Help. Herb Cover