Counting Records based on Time

Hi,
This is my Records
Date Rolls
09-oct-12 08:00:00 10
09-oct-12 08:00:50 20
10-oct-12 07:00:00 5
10-oct-12 10:00:00 10
Morning 8 to next morning 8 o'lcock to be taken as single day.
Output:
09-oct-12 35 (10+20+5)
10-oct-12 10
Pl. help How to achieve this.
Thanks
Kavi

When you wish a "skewed offset" definition of a day, you can subtract the required number of hours and then trunc to whole days.
Like this:
SQL> with data as (
  2     select to_date('09-10-2012 08:00:00','DD-MM-YYYY HH24:MI:SS') thedate, 10 rolls from dual union all
  3     select to_date('09-10-2012 08:00:50','DD-MM-YYYY HH24:MI:SS') thedate, 20 rolls from dual union all
  4     select to_date('10-10-2012 07:00:00','DD-MM-YYYY HH24:MI:SS') thedate,  5 rolls from dual union all
  5     select to_date('10-10-2012 10:00:00','DD-MM-YYYY HH24:MI:SS') thedate, 10 rolls from dual
  6  )
  7  select to_char( trunc(data.thedate - interval '8' hour)
  8                , 'DD-MM-YYYY HH24:MI:SS' ) theday
  9       , sum(rolls) rolls
10    from data
11   group by trunc(data.thedate - interval '8' hour)
12   order by theday
13  /
THEDAY                   ROLLS
09-10-2012 00:00:00         35
10-10-2012 00:00:00         10

Similar Messages

  • Count records based on detail row containing a null date field

    i need to count the no of rows where a date field is null and print the result in each group footer. the formula isnull works well in details section  but not when I create a running total to count records where evaluate condition is based on a formula and when i test isnull(field) ?
    works in detail section:
    Global NumberVar numOpen;
    if (IsNull({db.DateField}))
    then numOpen := numOpen + 1;
    does not work in group footer?
    IsNull({db.DateField})

    Abhilash Kumar wrote:
    Well, what database are you reporting off and how did you insert a NULL value to the date column?
    In my case, I have worked with Oracle, Access, and now SQL.,
    and have used several different versions of Crysal (but never XI)
    I/we don't put anything into the date...  the field is simply empty and I use 
    IsNull({datefield})
    also for numbers (&currency)
    IsNull({numberfield})
    For text fields I now use
    IsNull({textfield}) or {textfield} not equal ""
    as SQL is a little funny about the empty text fields. Sometimes one works and sometimes the other so I use both.
    Debi

  • Count records based on 3 columns

    I am using oracle 9i. Actually i need to count the resources based on three columns like Workgroup, month and task.
    Totally six columns in a table like tasktype, resource, workgroup, Workdate, Task, Month. Records and outputs are given below.
    Example:
    tasktype, resource, workgroup, Workdate, Task, Month,
    R, Abhishek, MC Consultant, 1/8/09 12:00AM, Non-Billable, 1
    R, Abhishek, MC Consultant, 1/9/09 12:00AM, Non-Billable, 1
    R, Abhishek, MC Consultant, 1/26/09 12:00AM, Non-Billable, 1
    R, Abhishek, MC Consultant, 2/2/09 12:00AM, Billable, 2
    R, Abhishek, MC Consultant, 2/3/09 12:00AM, Billable, 2
    R, Aboo, MC Consultant, 1/5/09 12:00AM, Billable, 1
    R, Aboo, MC Consultant, 1/6/09 12:00AM, Billable, 1
    R, Badri, MC Consultant, 2/20/09 12:00AM, Billable, 2
    R, Badri, MC Consultant, 2/21/09 12:00AM, Non-Billable, 2
    R, Betsy, Contractor, 1/2/09 12:00AM, Billable, 1
    R, Betsy, Contractor, 1/5/09 12:00AM, Billable, 1
    R, Bhavani, Contractor, 1/5/09 12:00AM, Billable, 1
    R, Brian, Contractor, 2/17/09 12:00AM, Billable, 2
    output:
    Task, Month, Workgroup, count
    Billable, 1, MC Consultant, 1
    Non-Billable, 1, MC Consultant, 1
    Billable, 2, MC Consultant, 2
    Non-Billable, 2, MC Consultant, 1
    Billable, 1, Contractor, 2
    Non-Billable, 1, Contractor, 0
    Billable, 2, Contractor, 1
    Non-Billable, 2, Contractor, 0
    Thanks in advance

    Please avoid posting your homework here.
    Definitely DON'T post it in multiple forums, acting extreemly rude.
    Sybrand Bakker
    Senior Oracle DBA

  • Database retrieving records based on time stamp

    Hello all,
                           I just  want to know that SQL query to retrieve specific time stamp record from the database using SQL server will work when same query is executed using SQL execute query.vi in labview.
                          Its not working actually.
    My query is,
    SELECT * FROM table name where col_name between 'date/time 2012-12-13 10:48:00' and 'date/time 2012-12-13 10:55:00'
    I am using mdb file. This date/time 2012-12-13 10:48:00 is first time stamp to be searched.. This is string comes from DB Tools format datetime string.vi 
    Kudos are always welcome if you got solution to some extent.
    I need my difficulties because they are necessary to enjoy my success.
    --Ranjeet

    A MS-Access query of a datetime field needs to be delimited wth the # (number sign / hash mark)
    Something like:
    SELECT * FROM table name where col_name between #2012-12-13 10:48:00# and #2012-12-13 10:55:00#
    I've never used the between condition; I don't know if it will work reliably with Access. I would normally use  >= and <= comparisons
    Important: the # is specific to Access. We converted from Access to SQL Server in the last year and had to find all the places that used the "#' in our LabVIEW code and replace with a single quote.
    Now is the right time to use %^<%Y-%m-%dT%H:%M:%S%3uZ>T
    If you don't hate time zones, you're not a real programmer.
    "You are what you don't automate"
    Inplaceness is synonymous with insidiousness

  • Records based on time from Oracle database

    Dear Experts,
    I need some valuable suggestion from your end.
    This a synchronous scenario from Sender ECC to Oracle Database.
    In Oracle Database, the swiping entry time of employees is stored in format as 03/11/2012 08:10:22 which would be the primary key while making ECC request.
    I have to fetch all the records along with other 3 output fields for the date between 03/11/2012 00:00:01 to 04/11/2012 00:00:01.
    The Oracle view has following column EMPID,CITY,TIME,DEVICE
    1. How would be ECC and JDBC request structure so that the start time and end time are captured?
    2.How to map the ECC and Oracle Database request structure where the SQL query would look something below.
    select EMPID,CITY,TIME,DEVICE  from time_details where
    TIME > TO_DATE('03/11/2012 00:00:01', 'MM/DD/YYYY HH24:MI:SS')
    and
    TIME < TO_DATE('04/11/2012 00:00:01', 'MM/DD/YYYY HH24:MI:SS')
    3. I tried to fetch the records by putting the WILDCARD in the date input value, I am receiving the response but with no payload.Is there any other design where I can fetch all the records for 03/11/2012 from 0 hours to 24 hours.
    Quick help is highly appreciated.
    Regards
    Rebecca

    Hi Praveen,
    Genius..
    You saved my whole day by giving this input..
    I would need your help to in the Access block specially to form the JDBC request structure from where clause. Let me first try to form the Message Type.
    <access>select EMPID,CITY,TIME,DEVICE  from time_details where TIME > TO_DATE('$placeholder1$', 'MM/DD/YYYY HH24:MI:SS') and TIME < TO_DATE('$placeholder2$', 'MM/DD/YYYY HH24:MI:SS')</access>
    1. I assume for TO_DATE, I have to check in the DateTransformation Mapping function whether HH24:MI:SS is available or not.
    Thanks once again for your input.
    Regards
    Rebecca

  • How to get Records based on time period?

    Hi,
    Iam having a Table which consists of two columns named "ID" (number datatype) and "JoinDate" (Varchar datatype). I would like to retrive the records whose join date is 3 months before. Any one pls give SQL for this scenario?
    Thanks in Advance...

    Why your joindate is varchar type? Which the sample data looks like? Is the format consistent?

  • Select records based on the closest given time

    Dear SQL gurus,
    I have a table T1:
    Name Null? Type
    ID NOT NULL NUMBER(5)
    MOMENT NOT NULL DATE [DD.MM.YYYY HH24:MI]
    MEASUREMENT NOT NULL NUMBER(8,3)
    Example (ID, MOMENT, MEASUREMENT)
    -- START OF EXAMPLE --
    9380 18.11.2000 03:45 17.6
    9380 18.11.2000 04:30 17.3
    9380 18.11.2000 05:45 16.8
    9380 18.11.2000 06:15 16.8
    9380 18.11.2000 07:00 16.2
    9380 18.11.2000 07:30 16.2
    9380 18.11.2000 08:15 16
    9380 18.11.2000 08:45 15.7
    9380 18.11.2000 09:30 15.4
    9380 18.11.2000 10:00 15.4
    9380 18.11.2000 11:15 15.4
    9380 18.11.2000 11:45 15.4
    9380 18.11.2000 12:30 15.4
    9380 18.11.2000 13:00 15.4
    9380 18.11.2000 13:45 15.4
    --- END OF EXAMPLE --
    How to select records based on the:
    - time period specified by the day only [DD.MM.YYYY] - CONDITION 1
    - with values for 6AM only, and if not available, with values closest to 6AM - CONDITION 2
    (if the time gap in MOMENT field is too big, lets say > 5h then choose the average between the value before 6AM (ex. 4:15AM) and the value after the 6AM (ex. 9:45AM))
    CONDITION 1 (something like): moment between '01.01.2005' and '31.12.2004' - this is OK
    CONDITION 2: I do not know how to formulate, especially if 6AM value is not availabe, and I have to find the closest available value, or get the avergae from the two adjacent values.
    Maybe cursor magic??? Thanks a lot for your help.
    Rado

    About condition two, would the following select be of use to you? Picking the first record could be achived by rownum, analytic function, etc.
    WITH t1 AS (SELECT 9380 id, TO_DATE('18.11.2000 03:45', 'dd.mm.yyyy hh24:mi') moment,  17.6 measurement
                  FROM dual
                 UNION 
                SELECT 9380 id, TO_DATE('18.11.2000 04:30', 'dd.mm.yyyy hh24:mi') moment,  17.3 measurement
                  FROM dual
                 UNION
                SELECT 9380 id, TO_DATE('18.11.2000 05:45', 'dd.mm.yyyy hh24:mi') moment,  16.8 measurement
                  FROM dual
                 UNION
                SELECT 9380 id, TO_DATE('18.11.2000 06:15', 'dd.mm.yyyy hh24:mi') moment,  16.8 measurement
                  FROM dual
    SELECT id, moment, measurement, diff
      FROM (SELECT id, moment, measurement,
                   moment - TO_DATE(TO_CHAR(moment, 'dd.mm.yyyy ') || '06:00', 'dd.mm.yyyy hh24:mi') diff
              FROM t1
    ORDER BY abs(diff) asc, SIGN(diff) desc;
      C.

  • Info record based on lead time

    How to create info record based on Lead time.
    If vendor supplies material with in 5 days cost will be 5 dollars each
    if he supplied after 5 days cost will be 3 dollars.
    how to control this function in info record or in Purchase order or in Conditions.
    Thanks
    SUNIL KUMAR

    closed

  • Is it possible to get the updated table records based on date & time.

    Is it possible to get the updated table records based on date & time in oracle.
    Thanks in advance.

    no, actually i am asking update records using 'UPDATE
    or DELETE' statement, but not insert statement.
    Is it possible?
    I think we can do using trigger on table, but problem
    is if i am having 20 tables means i have to write 20
    trigger. i don't want like this.Of course it's still possible, typically you'll find applications with a column LAST_UPDATE, probably a LAST_UPDATED_BY and so on column. You don't say what your business need is, if you just want a one of query of updates to particular records and have a recent version of Oracle, then flashback query may well help, if you want to record update timestamps you either have to modify the table, or write some code to store your updates in an audit table somewhere.
    Niall Litchfield
    http://www.orawin.info/

  • Fetching 10 records at a time

    Product.Category dimension has 4 child nodes Accessories,Bikes,Clothing n Components.My problem is when I have thousands of first level nodes my application takes a lot of time to load. Is there a way to fetch only say 100 records at a time? So then when
    i click a next button i get the next 100
    Eg:On the 1st click of a button I fetch 2 members
    WITH MEMBER [Measures].[ChildrenCount] AS
    [Product].[Category].CurrentMember.Children.Count
    SELECT [Measures].[ChildrenCount] ON 1
    ,TopCount([Product].[Category].Members, 2) on 0
    FROM [Adventure Works]
    This fetches only Accessories. Is there a way the fetch the next two records Bikes n Clothing on  click.
    Then Components on the next click. So on an so forth.

    Hi Tsunade,
    According to your description, there are thousands of members on your cube. It will take long time to retrieve all the member at a time, in order to improve the performance, you are looking for a function to fetch 10 records at a time, right? Based on my
    research, there is no such a functionally to work around this requirement currently.
    If you have any concern about this behavior, you can submit a feedback at
    http://connect.microsoft.com/SQLServer/Feedback and hope it is resolved in the next release of service pack or product. Your feedback enables Microsoft to make software and services the best that they can be, Microsoft might consider to add this feature
    in the following release after official confirmation.
    Regards,
    Charlie Liao
    TechNet Community Support

  • ....Count Record Problem

    I want to get a count of the records return by my query.
    I have a search Form through which user can search , and i want to display the Number of Records retrieved/count of records that meet the search Criteria.
    I have tried to use
    rc:= get_block_property('Blockname',QUERY_HITZ)
    it returns the value of 10. basically 10 is the number of records displayed..
    but this is not what is required.... the required thing is that we need the count of how many records return by the query.
    Anybody has ever done this..
    I mean everything is done by oracle ..
    i m not manually writing select * from .... ...
    Datablock it self return record based on
    set_block_propery('BLKname',default_where' cirteria')
    Now how to get the count.
    thnx for the reply

    Hi all
    First of all. Thnx alot for your kind input.
    Now..
    Let come to the point. i have already tried this
    get_block_property(......Query_hitz) method,
    it is definitly not working ppl
    I tell you it gives me a value of 10,
    but i for sure knows that the search yielded 54 records.
    So Mr. prasanth .. sorry your solution isnt working.
    Basically Search Forms gives you a facility to search by City Name
    Now all the employees in a particular city will be displayed, but 10employees record display at a single time and user have to scroll down.
    I just want ot give the total count so that user should know that how many records his/her search Yeileded...
    HOpe this would be much clear now.
    and sorry again i dont understand the ON_Message method...
    SOrry but i dont get it so thats why i have to write this again..
    Hope somebody have known the solution.
    thnx to all anyhow

  • Invalid Leaf Count Record

    When I repaired my startup disk with Disk Utility, an invalid leaf count record error was reported. From looking at other posts, it appears that one of the recommended things to do for this is trying to repair the issue with Disk Utility. I tried this using Disk Utility 4.1. I replaced my directory with the rebuilt directory. Unfortunately, when I started back up from my install CD and ran Repair Disk, the invalid leaf count record error was reported again.
    Any advice would be much appreciated... maybe I did something wrong.
    Thanks

    First, I realized that I had the error message wrong. I should have wrote "Invalid Leaf Record Count" originally instead of "Invalid Leaf Count Record". I doubt this makes a difference, but just in case there it is.
    Secondly, I am running 10.3.9 and have been doing so for quite some time. My understanding based on this is that DiskWarrior 4.1 should work. I took your advice and tried running DiskWarrior again. As I did previously, I simply booted from DiskWarrior because the disk I am trying to fix is my startup disk. I rebuilt and replaced the directory with DiskWarrior 4.1 again. As a matter of fact, I ran it multiple times while I had it going. I even ran it under the scavenge mode.
    After doing this, I restarted the computer, ejected the DiskWarrior disc, and put in my install disc that came with my iMac. I booted from this CD and reran "Repair Disk" with Disk Utility. The error stills shows up. One thing to note is that my install disc came with 10.3.5 on it. Could this somehow cause a problem? My understanding is that you should always use an install disc for the major OS version you are running to run the "Repair Disk" function of Disk Utility. For example use an install disc for 10.3 if you are trying to repair a disk running 10.3.x or use an install disc for 10.4 if you are trying to repair a disk running 10.4.x.
    Prior to ever running DiskWarrior, I used the fsck command from single-user mode. Interestingly, the error did not show up here. I thought the "Repair Disk" function with Disk Utility was similar to this command, but maybe there is enough variation to cause the difference. Do you guys have any idea, which one I should trust?
    Let me know if any of this is incorrect. Any other suggestions regarding this error would be welcomed. I don't really understand what the error itself means. For now, I guess I will just leave it since I don't really know what else to do. Maybe in the future it will get worse and DiskWarrior will recognize it... I know that's asking for a problem!

  • Challenge involving creating a file on GUI & seeing one record at a time...

    Hi,
    If anyone can help me with this project I'd be most appreciative. I'll try and explain the problem the best I can. I'm adding students to a database at a university they're either a Graduate or an Undergraduate. I'm taking in first, lastname's, ssn, & ACT/SAT/GMAT test results. I have a GUI called StudentRecord that has all the JTextFields, JButton's, etc. I'm also writing it to a .txt file called StudentDA. For this I used a BufferedFile reader.
    What I really need is on my StudentRecord when I click the display button I want it to show one record at a time in another JFrame. This other JFrame I named it display. I'm trying to create an instance of JFrame inside of the actionPerformed for StudentRecord but when I click display nothing happens.
    I adding the students with a vector that I'm calling v. I want the Display to read from the .txt file and display one at a time hence next, and previous. I'm going to post the tidbit of relevant code. If anyone can help me you'd be my hero for the day for all time I've tried to get this to work.
    Here's the StudentRecord (GUI) display part:
          public void actionPerformed( ActionEvent event )
         try {
              Display d = new Display(StudentDA.v);
             }//end try
            //catch right here no problems with this..Here's the DataAccess part:
    public class StudentDA{
      static Vector v = new Vector();;
      static String pathName = "a:/Final Project/test1.txt";
      static File studentFile = new File(pathName);
      static String status;
      public StudentDA() {}
      public static void initialize() {
        if (studentFile.exists() && studentFile.length() !=0) {
         try{
          BufferedReader in = new BufferedReader(new
          FileReader(studentFile) );
          do{
             status = in.readLine();
              if(status.equals ("uGrad")) {
                uGrad u = new uGrad();
                u.setFName(in.readLine() );
                u.setLName(in.readLine() );
                u.setssNum(Integer.parseInt(in.readLine()) );
                u.setACT(Integer.parseInt(in.readLine() ));
                v.add(u);
                System.out.println(u + "inside ugrad");
              }//end if uGrad
              else{
                if(status.equals("Grad")) {
                //same process as uGrad
                v.add(g);
              }//end else Grad
          }while (status != null);
        }//end try statement
        catch (Exception e) {
          }//end catch
        }//end if there's something there
      }//end method initialize
      //creating the terminate method
      public static void terminate() {
        try{
          PrintStream out = new PrintStream ( new
          FileOutputStream (studentFile) );
          for (int i = 0; i < v.size(); i++) {
            Student s = (Student) v.elementAt(i);
            String p = s.printRecord();
            StringTokenizer rt = new StringTokenizer(p, "\t");
            while (rt.hasMoreTokens() ) {
              out.println(rt.nextToken() );
              }//end while
          }//end for loop
        }//end try loop
        catch (Exception e){
        }//end catch
      }//end terminate
    public static void add(Student s){// throws DuplicateException{
              boolean duplicate = false;
              for(int i = 0; i < v.size(); i++){
                   if(s.getssNum() == ((Student)(v.elementAt(i))).getssNum()){
                        duplicate = true;
                        break;
                   if(duplicate){
                        throw new DuplicateException("Student Already Exists");
                   else{
                        v.add(s);
    }//end add method
    }//end classHere's the display class:
    public class Display extends JFrame {
         private JButton Next, Previous;
         private JTextField statusField, firstField, lastField, socialField, advPlacementField, actField;
         private JLabel statusLabel, firstLabel, lastLabel, socialLabel, advPlacementLabel, actLabel;
         private JPanel fieldPanel, buttonsPanel;
         private JTextArea displayArea;
         static int count = 0;
         static String status;
         public Display(){}
    public Display(Vector v){
         //setting up the GUI components for the display class here
         //JTextAreas & JLabels
         buttonsPanel = new JPanel();
         buttonsPanel.setLayout(new GridLayout(1,2));
        Next = new JButton("Next");
        buttonsPanel.add(Next);
        Next.addActionListener(
        new ActionListener() {
          public void actionPerformed( ActionEvent event )
              //try to catch display errors
           try {
                        count++;
                     displayData(count);
                     //displayData();
          }//end try
              catch {
             }//end catch
          } // end actionPerformed
        } // end anonymous inner class
        ); // end call to addActionListener
        buttonsPanel.add(Next);
        Previous = new JButton("Previous");
        buttonsPanel.add(Previous);
        Previous.addActionListener(
        new ActionListener() {
          public void actionPerformed( ActionEvent event )
              //try to catch display errors
              try {
                   count--;
                   displayData(count);
                   //displayData();
             }//end try
              catch {
             }//end catch
          } // end actionPerformed
        } // end anonymous inner class
        ); // end call to addActionListener
    }//end display() constructor
    public void displayData(int count) {
         StudentDA.initialize();
           if (status.equals ("uGrad")) {
           //these are all part of the StudentRecord GUI not Display GUI
                fieldPanel.setVisible(true);
                buttonsPanel.setVisible(true);
                actLabel.setVisible(true);
                actField.setVisible(true);
                advPlacementLabel.setVisible(false);
                advPlacementLabel.setVisible(false);
           }//end if
           else {
                if(status.equals ("Grad")) {
                 fieldPanel.setVisible(true);
                 buttonsPanel.setVisible(true);
                 actLabel.setVisible(false);
                 actField.setVisible(false);
                 advPlacementLabel.setVisible(true);
                 advPlacementLabel.setVisible(true);
                  }//end if
           }//end else
    }//end method displayData()
    public static void main ( String args[] )
        Display application = new Display();
        application.addWindowListener(
              new WindowAdapter(){
                   public void windowClosing( WindowEvent e)
                        System.exit(0);
        application.setSize( 300, 200);
        application.setVisible( true );
    };//end main
    }//end class Display{}I know this is long but if anyone can help I'd greatly appreciate it. Please ask me if you need me to clarify something, I tried to not make it way too long. --rockbottom01
         

    I'm not really too sure what it is that you are after, but here is some code, that loads up an array with each line of a .txt file, then displays them. I hope you can make use of a least some of it.
    just ask if you don't understand any of the code.
    String array[];
    int i;
    public Test() {
              readFile("file.txt");
              i = 0;
              nextEntry();
         public void nextEntry() {
              Display display = new Display();
              display.show();
         class Display extends JFrame implements ActionListener {
              JLabel label1;
              JButton button;
              public Display() {
                   label1 = new JLabel(array);
                   button = new JButton("OK");
                   getContentPane().setLayout(new FlowLayout());
                   getContentPane().add(label1);
                   getContentPane().add(button);
                   button.addActionListener(this);
              public void actionPerformed(ActionEvent e) {
                   setVisible(false);
                   i++;
                   if(i < array.length) {
                        nextEntry();
         public void readFile(String fileName) {
              String s, s2 = "";
              int lineCount = 0;
              BufferedReader in;
              try {
                   in = new BufferedReader(new FileReader(fileName));
                   while((s = in.readLine()) != null) {
                        lineCount++;
                   array = new String[lineCount];
                   in.close();
                   in = new BufferedReader(new FileReader(fileName));
                   int j = 0;
                   while((s = in.readLine()) != null) {
                        array[j] = s;
                        j++;
              catch(IOException e) {
                   System.out.println("Error");

  • How to save more than 2 records at a time in tabular form?

    I have a table name SAMPLE_TABLE, which has SNO,NAME items and one sequence name is SEQ_SAMPLE.
    i have one form based on SAMPLE_TABLE. my form is in tabular format, which has 5 records.
    in the layout wizard only NAME is displayed. SNO doesnot displayed.
    in the layout wizard, there is one push button named as SAVE.
    the code of SAVE button(When_Button_Pressed) is
    insert into sample_table values(seq_sample.nextval,:sample_table.name);
    clear_record;
    commit;
    my problem is :
    when ever i want to save one record at a time there is no problem.
    if i want to save more than 2 records at a time then sequence number is alloted for last record. other records have no sequence numbers.
    for example i want to insert 2 names as XYZ,PQR then
    the table look like this:
    sno name
    1 PQR
    XYZ
    if SNO is primary key then it doesnot work because of null value.
    can any one solve my problem?
    Thanks
    Meegada

    Is the block a database block or a control block,
    1. if database block, assign the primary key on a
    trigger like new record instance for each record
    enteredour's is a control block, ididnt get your point clearly
    could you make it clear how to assign a primary key on a trigger
    our criteria is we are having two block as lov_values and lov_name
    lov_values:
    lov_values_id (sequence generated)
    lov_id will be same for the all the values for a particular lov_name
    lov_values will be which we enter in the form which will be the only visuble colums on the form
    lov_name block:
    lov_name
    lov_id(sequence generated)
    could you help me with the code
    thanks
    prasad

  • How to create Child record at the time of master record creation.

    Hi,
    I have MasterVO and ChildVO. And association between both are 1 to *. I have a requirement like, I need to create row in ChildVO at the time of MasterVO row creation.
    I have used entity based association to create view link. This view link created ChildVO accessor in MasterRowImpl as type RowIterator.
    Actually my idea is to override create method in MasterVORowImpl and call ChildVO ViewObject and call .createRow() method on it. But I don't have access to ViewObject, instead it gave access to RowIterator.
    Could you please provide any pointer to achieve above functionality?
    Many thanks in advance.
    Jdev version - 11.1.1.7.0
    Regards,
    Dileep.

    Hi Tim,
    Now it is creating child record at the time of master row creation. But it is working only through BC tester. But when I drag the child VO instance in the jsff page, only master is get created as editable only, child is displayed as read only without populating any default values like child VO surrogate key and other default attributes. But through BC tester it is working fine.
    Am I missing anything here while implementing in UI?
    Thanks,
    Dileep.

Maybe you are looking for

  • Regarding Sumit report

    HI, Could you tell me when calling report using Submit. can i pass variables. If I can, then variables in calling program and passing program must be same or not. Regards Reddy

  • [15013] Logical table, BIDATA.W1_SYNONYM_EMPLOYEE1_D1, does not join to any

    Hello all. I have following situation. I have a Employee table(w1_employee1_d1) Salary table(w_salary_f) in Database. every thing is fine when I import it in OBIEE Administration tool and use the answers. Then I created a synonym as (w1_synonym_emplo

  • Can't repair permissions in iPhoto 9.6

    Upgraded to iPhoto 9.6.  On opening get message: "The photo library needs to be upgraded to work with this version of iPhoto."  When I click UPGRADE, I am "invited" to repair permissions of this library.  When I select REPAIR, I am informed that "iPh

  • Short, basic VB script works on 2003 Server but not on 2012 R2 server

    Hello all, Hopefully I'm posting this in the right place. I have a legacy VB script that I need to keep, but I'm having trouble getting it to work on Server 2012 R2. The script reads a file called "Test.txt" that contains the following string: String

  • Populate Data in a WebService Using ODI

    Hello Everyone, I have a requirement where i need to populate the data in a web service. I have data coming in a flat file needs to be processed by applying some transformations.After transformation i will be loading this data in a Oracle table first