Rows of Data cannot be inserted (Loop Problem) (urgent)

Hi Guys
create table JobWorker
(JobID               Integer,
JobName          char(20),     
Name               char(20),      
Department          char(20),
Responsibilities char(30),
JobRating char(20),
Primary Key (JobID));
Above is my table that requires rows of data.
Create sequence demoseq increment by 1 start with 1;
DECLARE
v_rows integer := 1000; -- THIS IS THE KEY VALUE = NUMBER OF ROWS IN TABLE
v_JobName char(20);
v_temp integer := 1;
BEGIN
FOR v_counter IN 1 .. v_rows LOOP
IF (v_temp > 10) THEN
v_temp := 1;
END IF;
IF (v_temp = 1) THEN
v_JobName := 'Pharmacist';
insert into JobWorker values (demoseq.nextval, v_JobName, 'Richard Smith','Medical', 'Import and Export', 7);
ELSIF (v_temp = 2) THEN
v_JobName := 'Security Officer';
insert into JobWorker values (demoseq.nextval, v_JobName, 'Matt Stevens', 'Security', 'Check Club Tickets', 6);
ELSIF(v_temp = 3) THEN
v_JobName := 'Systems Analyst';
insert into JobWorker values (demoseq.nextval, v_JobName, 'Navdeep Kamboz', 'Finance', 'Analyse Systems', 10);
ELSIF(v_temp = 4) THEN
v_JobName := 'Mathematician';
insert into JobWorker values (demoseq.nextval, v_JobName, 'Paul Potts', 'Algebra and Data Handling', 'Teach Algebra', 4);
ELSIF(v_temp = 5) THEN
v_JobName := 'DB Administrator';
insert into JobWorker values (demoseq.nextval, v_JobName, 'Christine Bleakley', 'Oracle, SQL, DB2', 'Granting User Privileges', 9);
ELSIF(v_temp = 6) THEN
v_JobName := 'Dentist';
insert into JobWorker values (demoseq.nextval, v_JobName, 'Edward Walker', 'Manager', 'General Checkups', 8);
ELSIF(v_temp = 7) THEN
v_JobName := 'Electrician';
insert into JobWorker values (demoseq.nextval, v_JobName, 'Dave Panesar', 'Engineering', 'Examine Specifications', 3);
ELSIF(v_temp = 8) THEN
v_JobName := 'Cricketer';
insert into JobWorker values (demoseq.nextval, v_JobName, 'Sachin Tendulkar', 'Batsman', 'Scoring Hundreds', 9);
ELSIF(v_temp = 9) THEN
v_JobName := 'Personal Trainer';
insert into JobWorker values (demoseq.nextval, v_JobName, 'Brock Lesnar', 'Weights Dept', 'Train People on Weights', 5);
ELSIF(v_temp = 10) THEN
v_JobName := 'Area Manager';
insert into JobWorker values (demoseq.nextval, v_JobName, 'Joe Hoffland', 'Midlands', 'Visit Stores and Examine', 2);
END IF;
END LOOP;
END;
It does work...but the following problems I get are...
As you can see I have populated the tables as a Loop..
But if I was to generate a statement : Select * from JobWorker WHERE Name = 'Joe Hoffland';
It provides me with the result as 'No Rows Selected'.
The first Insert consists of someone called Richard Smith. Every row of data is only populated with his name and his row of data.
I cannot get the other 9 insert rows to work....
Is there something wrong with the above code? I require your help guys! Thank You!

Incrementing v_temp would help :). Also column department length is too small. You need to increase it to 25. And sing CHAR isn't a good idea. Use VARCHAR2 instead:
SQL> DECLARE
  2  v_rows integer := 1000; -- THIS IS THE KEY VALUE = NUMBER OF ROWS IN TABLE
  3  v_JobName char(20);
  4  v_temp integer := 1;
  5 
  6  BEGIN
  7  FOR v_counter IN 1 .. v_rows LOOP
  8 
  9  IF (v_temp > 10) THEN
10  v_temp := 1;
11  END IF;
12 
13  IF (v_temp = 1) THEN
14  v_JobName := 'Pharmacist';
15  insert into JobWorker values (demoseq.nextval, v_JobName, 'Richard Smith','Medical', 'Import and Export', 7);
16  ELSIF (v_temp = 2) THEN
17  v_JobName := 'Security Officer';
18  insert into JobWorker values (demoseq.nextval, v_JobName, 'Matt Stevens', 'Security', 'Check Club Tickets', 6);
19  ELSIF(v_temp = 3) THEN
20  v_JobName := 'Systems Analyst';
21  insert into JobWorker values (demoseq.nextval, v_JobName, 'Navdeep Kamboz', 'Finance', 'Analyse Systems', 10);
22  ELSIF(v_temp = 4) THEN
23  v_JobName := 'Mathematician';
24  insert into JobWorker values (demoseq.nextval, v_JobName, 'Paul Potts', 'Algebra and Data Handling', 'Teach Algebra', 4);
25  ELSIF(v_temp = 5) THEN
26  v_JobName := 'DB Administrator';
27  insert into JobWorker values (demoseq.nextval, v_JobName, 'Christine Bleakley', 'Oracle, SQL, DB2', 'Granting User Privileges',
9);
28  ELSIF(v_temp = 6) THEN
29  v_JobName := 'Dentist';
30  insert into JobWorker values (demoseq.nextval, v_JobName, 'Edward Walker', 'Manager', 'General Checkups', 8);
31  ELSIF(v_temp = 7) THEN
32  v_JobName := 'Electrician';
33  insert into JobWorker values (demoseq.nextval, v_JobName, 'Dave Panesar', 'Engineering', 'Examine Specifications', 3);
34  ELSIF(v_temp = 8) THEN
35  v_JobName := 'Cricketer';
36  insert into JobWorker values (demoseq.nextval, v_JobName, 'Sachin Tendulkar', 'Batsman', 'Scoring Hundreds', 9);
37  ELSIF(v_temp = 9) THEN
38  v_JobName := 'Personal Trainer';
39  insert into JobWorker values (demoseq.nextval, v_JobName, 'Brock Lesnar', 'Weights Dept', 'Train People on Weights', 5);
40  ELSIF(v_temp = 10) THEN
41  v_JobName := 'Area Manager';
42  insert into JobWorker values (demoseq.nextval, v_JobName, 'Joe Hoffland', 'Midlands', 'Visit Stores and Examine', 2);
43 
44  END IF;
45  v_temp := v_temp + 1;
46  END LOOP;
47  END;
48  /
PL/SQL procedure successfully completed.
SQL> Select * from JobWorker WHERE Name = 'Joe Hoffland';
     JOBID JOBNAME              NAME                 DEPARTMENT                RESPONSIBILITIES               JOBRATING
        10 Area Manager         Joe Hoffland         Midlands                  Visit Stores and Examine       2
        20 Area Manager         Joe Hoffland         Midlands                  Visit Stores and Examine       2
        30 Area Manager         Joe Hoffland         Midlands                  Visit Stores and Examine       2
        40 Area Manager         Joe Hoffland         Midlands                  Visit Stores and Examine       2
        50 Area Manager         Joe Hoffland         Midlands                  Visit Stores and Examine       2
       120 Area Manager         Joe Hoffland         Midlands                  Visit Stores and Examine       2
       130 Area Manager         Joe Hoffland         Midlands                  Visit Stores and Examine       2
       140 Area Manager         Joe Hoffland         Midlands                  Visit Stores and Examine       2
     JOBID JOBNAME              NAME                 DEPARTMENT                RESPONSIBILITIES               JOBRATING
       970 Area Manager         Joe Hoffland         Midlands                  Visit Stores and Examine       2
       980 Area Manager         Joe Hoffland         Midlands                  Visit Stores and Examine       2
       990 Area Manager         Joe Hoffland         Midlands                  Visit Stores and Examine       2
      1000 Area Manager         Joe Hoffland         Midlands                  Visit Stores and Examine       2
100 rows selected.
SQL> SY.

Similar Messages

  • Error: Data cannot be inserted as there is no matching record

    Hi,
    I have migrated SharePoint 2010 site to SharePoint 2013.
    I have a custom list, which i was able to do edit multiple records after "opening in Access" in SharePoint 2010.
    After the migration, when i open the list in "open with Access", and try to modify any data, I am getting the error "Data cannot be inserted as there is no matching record". The custom list has columns which are taken from lookup list.
    I have tried the re-link the list, which has not helped.
    Found this: For some of the lookup colums, for which the data is empty, it is getting shown as 0.
    This is causing the issue.
    How to fix this?
    Thanks

    Hi Venkatzeus,
    According to your description, my understanding is that the error occurred when you open the list with Access after migrating SharePoint 2010 to SharePoint 2013.
    Did this issue occur with other lists?
    I recommend to create a new blank database in Access and then import the list into the new one to see if the issue still occurs.
    For test, I recommend to test the same scenario with a new list to narrow the issue scope.
    Best regards.
    Thanks
    Victoria Xia
    TechNet Community Support

  • How to loop through a single row of data?

    What I'm trying to do is use a cursor to loop through a clob. When I create my cursor I get the an error telling me that the table does not exist. Which implies that I have an implicit cursor. Is there a way to get around this?

    > How to loop through a single row of data?
    By not looping as there is only a single row?
    > What I'm trying to do is use a cursor to loop through a clob
    Processing (looping through) a CLOB has nothing to do with a cursor.
    > When I create my cursor I get the an error telling me that the table does
    not exist. Which implies that I have an implicit cursor.
    Incorrect. It simply means that
    a) you do not have permissions to access that table from within the current context
    b) it does not exist (e.g. you have misspelled the object name, you have not qualified it properly within the current scope, etc)

  • How do I create a 1d array that takes a single calculation and insert the result into the first row and then the next calculation the next time the loop passes that point and puts the results in thsecond row and so on until the loop is exited.

    The attached file is work inprogress, with some dummy data sp that I can test it out without having to connect to equipment.
    The second tab is the one that I am having the problem with. the output array from the replace element appears to be starting at the index position of 1 rather than 0 but that is ok it is still show that the new data is placed in incrementing element locations. However the main array that I am trying to build that is suppose to take each new calculation and place it in the next index(row) does not ap
    pear to be working or at least I am not getting any indication on the inidcator.
    Basically what I am attempting to do is is gather some pulses from adevice for a minute, place the results for a calculation, so that it displays then do the same again the next minute, but put these result in the next row and so on until the specifiied time has expired and the loop exits. I need to have all results displayed and keep building the array(display until, the end of the test)Eventually I will have to include a min max section that displays the min and max values calculated, but that should be easy with the min max function.Actually I thought this should have been easy but, I gues I can not see the forest through the trees. Can any one help to slear this up for me.
    Attachments:
    regulation_tester_7_loops.vi ‏244 KB

    I didn't really have time to dig in and understand your program in depth,
    but I have a few tips for you that might things a bit easier:
    - You use local variables excessively which really complicates things. Try
    not to use them and it will make your life easier.
    - If you flowchart the design (very similar to a dataflow diagram, keep in
    mind!) you want to gather data, calculate a value from that data, store the
    calculation in an array, and loop while the time is in a certain range. So
    theres really not much need for a sequence as long as you get rid of the
    local variables (sequences also complicate things)
    - You loop again if timepassed+1 is still less than some constant. Rather
    than messing with locals it seems so much easier to use a shiftregister (if
    absolutely necessary) or in this case base it upon the number of iterations
    of the loop. In this case it looks like "time passed" is the same thing as
    the number of loop iterations, but I didn't check closely. There's an i
    terminal in your whileloop to read for the number of iterations.
    - After having simplified your design by eliminating unnecessary sequence
    and local variables, you should be able to draw out the labview diagram.
    Don't try to use the "insert into array" vis since theres no need. Each
    iteration of your loop calculates a number which goes into the next position
    of the array right? Pass your result outside the loop, and enable indexing
    on the terminal so Labview automatically generates the array for you. If
    your calculation is a function of previous data, then use a shift register
    to keep previous values around.
    I wish you luck. Post again if you have any questions. Without a more
    detailed understanding of your task at hand it's kind of hard to post actual
    code suggestions for you.
    -joey
    "nelsons" wrote in message
    news:[email protected]...
    > how do I create a 1d array that takes a single calculation and insert
    > the result into the first row and then the next calculation the next
    > time the loop passes that point and puts the results in thsecond row
    > and so on until the loop is exited.
    >
    > The attached file is work inprogress, with some dummy data sp that I
    > can test it out without having to connect to equipment.
    > The second tab is the one that I am having the problem with. the
    > output array from the replace element appears to be starting at the
    > index position of 1 rather than 0 but that is ok it is still show that
    > the new data is placed in incrementing element locations. However the
    > main array that I am trying to build that is suppose to take each new
    > calculation and place it in the next index(row) does not appear to be
    > working or at least I am not getting any indication on the inidcator.
    >
    > Basically what I am attempting to do is is gather some pulses from
    > adevice for a minute, place the results for a calculation, so that it
    > displays then do the same again the next minute, but put these result
    > in the next row and so on until the specifiied time has expired and
    > the loop exits. I need to have all results displayed and keep building
    > the array(display until, the end of the test)Eventually I will have to
    > include a min max section that displays the min and max values
    > calculated, but that should be easy with the min max function.Actually
    > I thought this should have been easy but, I gues I can not see the
    > forest through the trees. Can any one help to slear this up for me.

  • Help with Detail entity Insert with row key null cannot find or invalidate

    Hi,
    My Problem:
    I have created a form in JDeveloper ADF. This form is based on the Table Name IT_HARDWARE. The IT_HARDWARE keep track of all the hardware and it is in the relationship with the IT_SYSTEM table, IT_LOCATION, EMPOYEES. So the IT_HARDWARE has a FOREIGN KEY from IT_SYSTEM (SYS_ID), IT_LOCATION (LOC#), EMPLOYEE (EIP#).
    When I create a form to insert data into this form, I receive message "Detail entity ItHardwareInsert with row key null cannot find or invalidate its owning entity."
    I tried all possible to understand what is causing this and I can't find it. Can someone help me?

    Than you for the link, I appreciate it. I kind understand the root of the problem, but since I am new to JDeveloper, I am getting trouble to solve the problem. I am going to read and understand what is going on. Thank you for the link.

  • SEM-BPS 6.0 error message requested data cannot be locked but at 999 row?

    Hi all,
    We are using SEM-BPS with WIB and EP 7.0 and I encountered issues for the first time.  I normally avoid configuring layouts with large hierarchies but at this one the client insisted.  They are in testing right now and selection of relatively small node (approx. 10-20 cost centers) still gave us an error message. 
    I know layouts has a limit of 9,999 rows and we should have been okay since it is about 200-300 lines per cost center but we are getting the error message below and it mentioned a limit of 999 rows in the selection table..  Any way we can change that?
    Thanks,
    mary
    Requested data cannot be locked (-> see long text)
    Notification Number RSPLS092
    Diagnosis
    In order to edit data from InfoProvider 'ZYEE_C02', the requested data has to be locked exclusively for user 'YEESU01'. The data that is currently being requested is specified by a very large selection table. In order to lock the data exclusively, the system has to store a compressed version of this selection table on the SAP standard lock server. However, the compressed selection table still has more than 999 rows. So that a reasonable number of users are able to change data at the same time, the system limits the number of records allowed in a selection table to 999 records.
    Information on Context of Lock Request:
    Lock requests can come from BI-Planning or from BW-BPS. The context specifies the following information:
    BI-Planning: for a lock request from a query, {Planning Function} for a lock request from a planning function.
    BW-BPS: {Planning Area}{Planning Level}{Planning Package}{Planning Function}{Parameter Group}. For lock requests from manual planning the following is true: Planning function = '0-MP' and the parameter group is the technical name of the planning layout.
    InfoProvider 'ZYEE_C02' is always a Basis InfoProvider. The current context information is:
    '{0-ADHOC}{0-MP}'
    System Response
    The requested data cannot be locked.
    Procedure
    You can normally only avoid this by simplifying your selections. For more information, see the documentation on this.
    Procedure for System Administration

    Hi Mary,
    in RSPLSE you use the option that the BI lock table is maintained in the SAP enqueue server. Here there is a limit - as explained in the long text of the message - that the compressed selection table for one enqueue request should not have more than 999 rows. This limit can not be changed.
    The selection table seems to be very big, since the compression factor is at least 5. So please check your selection table:
    1 check whether you can make the characteristic causing the problem not lock relevant
    2 or use the second option that the BI lock table is maintained in a shared memory area of the central instance of the system.
    But it is better to keep the selection tables small, e.g. by making some characteristics not lock relevant.
    Check sizing note 928044, e.g. in case you want to use 2. The default setting is very small.
    Regards,
    Gregor

  • Problem to calculate the coherence (using NetworkFunction-VI) with only 1 row of data for each, the stimulus and response input

    Hello,
    I am trying to calculate the coherence of a stimulus and response
    signal using the Network Functions (avg) VI's. The problem is that I
    always get a coherence of "1" at all frequencies. This problem is
    already known (see KnowledgeBase document: Why is the Network Functions (avg) VI's Coherence Function Output "1"?).
    My trouble is that the described solution (-> the stimulus and response input matrices need to have at least two rows to get non-unity coherence values) doesn't help me much, because I only have one array of stimulus data and one array of response values.
    Thus, how can I fullfil the 'coherence-criteria' to input at least two rows of data each when I just have one row of data each?
    Any hint or idea is very much appreciated. Thanks!
    Horst

    With this weird board layout, I'm not sure whether you were asking me, but, on the assumption that you were, here goes:
    I found no need to use the cross-power spectrum and power spectrum blocks
    1... I was looking for speed.
    2... I already had the component spectral data there, for other purposes. From that, it's nothing but addition and multiplication.
    3... The "easy" VIs, assume a time wave input, as I recall. Which means they would take the same spectrum of the same timewave several times, where I only do it once.
    I have attached PNGs of my code.
    The PROCESS CHANNEL vi accepts the time wave and:
    1... Removes DC value.
    2... Integrates (optional, used for certain sensors).
    3... Windows (Hanning, etc. - optional)
    4... Finds spectrum.
    5... Removes spectral mirrors.
    6... Scales into Eng. units.
    7... From there, you COULD use COMPLEX-TO-POLAR, but I don't care about the phase data, and I need the MAG^2 data anyway, so I rolled my own COMPLEX-TO-MAG code.
    The above is done on each channel. The PROCESS DATA vi calls the above with data for each channel. The 1st channel in the list is required to be the reference (stimulus) channel.
    After looping over each channel, we have the Sxx, Syy, and Sxy terms. This code contains some averaging and peak-picking stuff that's not relevant.
    From there, it's straightforward to ger XFER = Sxy/Sxx and COHERENCE = |Sxy|^2 / (Sxx * Syy)
    Note that it uses the MAGNITUDE SQUARED of Sxy. Again, if you use the "easy" stuff, it will do a square-root operation that you just have to reverse - it is obtained faster by the sum of the squares of the real and imag parts.
    Hope this helps.
    Steve Bird
    Culverson Software - Elegant software that is a pleasure to use.
    Culverson.com
    Blog for (mostly LabVIEW) programmers: Tips And Tricks
    Attachments:
    ProcessChannel.png ‏25 KB

  • Group Above Report problem...not able to display absent rows in date range

    In my report query, I have numerous select statements that I must union together and group by a date. The ultimate goal is to get a count for all records in coordination with that date. Then in the report, I group all the data with the same date to ultimately put all counts on a page that coordinate with a single date.
    Thing is...if there are no records associated with that date, the 'group by' clause makes the return data set not include those lines of output. I need these lines of output! Any suggestions??
    Below is an example...
    Select 'Program1', 'SubProgram1', 'Label 1', to_char(receipt_date, 'MM/DD/RRRR'), count(*)
    from submissions
    where receipt_date between '01-JUN-05' and '10-JUN-05'
    and substr(submission_index,8,1) = '3'
    and substr(submission_index,9,1) = '1'
    group by substr(submission_index,8,1), substr(submission_index,9,1), to_char(receipt_date, 'MM/DD/RRRR')
    union
    Select 'Program2', 'SubProgram2', 'Label 2',
    to_char(receipt_date, 'MM/DD/RRRR'), count(*)
    from submissions
    where receipt_date between '01-JUN-05' and '10-JUN-05'
    and substr(submission_index,8,1) = '4' group by substr(submission_index,8,1), to_char(receipt_date, 'MM/DD/RRRR')
    OUTPUT:
    Program1 SubProgram1 Label 1 06/01/2005 4
    Program1 SubProgram1 Label 1 06/02/2005 2
    Program1 SubProgram1 Label 1 06/03/2005 6
    Program1 SubProgram1 Label 1 06/04/2005 23
    Program1 SubProgram1 Label 1 06/06/2005 71
    Program1 SubProgram1 Label 1 06/07/2005 245
    Program1 SubProgram1 Label 1 06/08/2005 76
    Program1 SubProgram1 Label 1 06/10/2005 45
    Program2 SubProgram2 Label 2 06/01/2005 66
    Program2 SubProgram2 Label 2 06/02/2005 345
    Program2 SubProgram2 Label 2 06/03/2005 89
    Program2 SubProgram2 Label 2 06/04/2005 12
    Program2 SubProgram2 Label 2 06/05/2005 3
    Program2 SubProgram2 Label 2 06/06/2005 27
    Program2 SubProgram2 Label 2 06/09/2005 98
    Program2 SubProgram2 Label 2 06/10/2005 456
    I need the missing lines to show up for Program 1 on 6/05 and 6/09
    and Program 2 on 6/07 and 6/08

    create table your_table (
        program     varchar2(20),
        subprogram  varchar2(20),
        label       varchar2(20),
        day         date,
        num         number
    insert into your_table values ('Program1', 'SubProgram1', 'Label 1', to_date('01-JUN-05'), 4);
    insert into your_table values ('Program1', 'SubProgram1', 'Label 1', to_date('02-JUN-05'), 2);
    insert into your_table values ('Program1', 'SubProgram1', 'Label 1', to_date('03-JUN-05'), 6);
    insert into your_table values ('Program1', 'SubProgram1', 'Label 1', to_date('04-JUN-05'), 23);
    insert into your_table values ('Program1', 'SubProgram1', 'Label 1', to_date('06-JUN-05'), 71);
    insert into your_table values ('Program1', 'SubProgram1', 'Label 1', to_date('07-JUN-05'), 245);
    insert into your_table values ('Program1', 'SubProgram1', 'Label 1', to_date('08-JUN-05'), 76);
    insert into your_table values ('Program1', 'SubProgram1', 'Label 1', to_date('10-JUN-05'), 45);
    insert into your_table values ('Program2', 'SubProgram2', 'Label 2', to_date('01-JUN-05'), 66);
    insert into your_table values ('Program2', 'SubProgram2', 'Label 2', to_date('02-JUN-05'), 345);
    insert into your_table values ('Program2', 'SubProgram2', 'Label 2', to_date('03-JUN-05'), 89);
    insert into your_table values ('Program2', 'SubProgram2', 'Label 2', to_date('04-JUN-05'), 12);
    insert into your_table values ('Program2', 'SubProgram2', 'Label 2', to_date('05-JUN-05'), 3);
    insert into your_table values ('Program2', 'SubProgram2', 'Label 2', to_date('06-JUN-05'), 27);
    insert into your_table values ('Program2', 'SubProgram2', 'Label 2', to_date('09-JUN-05'), 98);
    insert into your_table values ('Program2', 'SubProgram2', 'Label 2', to_date('10-JUN-05'), 456);
    SELECT     yt.program
    ,           yt.subprogram
    ,           yt.label
    ,           nvl(yt.num,0)     NUM
    ,           days.date_value
    FROM     (     select  (to_date('11-JUN-05','DD-MON-YY') - day) date_value
                   from    (   select  rownum day            
                               from    dual            
                               connect by rownum < 11        
              )                    days
    ,          your_table          yt
    where   yt.day(+) = days.date_value
    order by yt.program, days.date_value
    PROGRAM          SUBPROGRAM     LABEL     NUM     DATE_VALUE
    Program1     SubProgram1     Label 1     4     6/1/2005
    Program1     SubProgram1     Label 1     2     6/2/2005
    Program1     SubProgram1     Label 1     6     6/3/2005
    Program1     SubProgram1     Label 1     23     6/4/2005
    Program1     SubProgram1     Label 1     71     6/6/2005
    Program1     SubProgram1     Label 1     245     6/7/2005
    Program1     SubProgram1     Label 1     76     6/8/2005
    Program1     SubProgram1     Label 1     45     6/10/2005
    Program2     SubProgram2     Label 2     66     6/1/2005
    Program2     SubProgram2     Label 2     345     6/2/2005
    Program2     SubProgram2     Label 2     89     6/3/2005
    Program2     SubProgram2     Label 2     12     6/4/2005
    Program2     SubProgram2     Label 2     3     6/5/2005
    Program2     SubProgram2     Label 2     27     6/6/2005
    Program2     SubProgram2     Label 2     98     6/9/2005
    Program2     SubProgram2     Label 2     456     6/10/2005The four null rows will not show up because the date is used at least once between program 1 or program 2. Will there only ever be two programs to chose from? Any one else got any ideas around this?

  • How to identify date & time of insertion of rows in a table

    Hi,
    Is it possible to identify the date & time of insertion of rows in a table?
    for example:
    Table name: emp
    I have rows like this
    emp_code name dept
    pr01 ram edp
    ac05 gowri civil
    pr02 sam pro
    i want to know the date and time of the insertion this( ac05 gowri civil).
    Could you please help me.....
    Thanks in advance....

    psram wrote:
    sorry for the confusion. I dont want to store date and time. I said that for example only.
    I have table which consists of thousands of rows. I want to know the insertion date & time of a particular row.
    Is it possible?So, if I have a table that stores a load of employee numbers, do you think I could get the database to tell me their names?
    If you don't store the information, you can't query the information.
    Ok, there are some dribbs and drabbs of information available from the back end of the database via the SCN's, Archive Logs etc., but those sort of things disappear or get overwritten as time goes by. The only way to know the information it to ensure you store it in the first place.
    So, in answer to your question, No, there isn't a true and reliable way to get the data/time that rows were inserted into the table, unless you have chosen to store it alongside the data.

  • How to manually insert an extra row of data in to a record set

    hi there, i have a standard query which gets me some rows of
    data
    is there a way to manually add in an extra row of data (an
    position that as row number 1 in the recordset)?
    i've tried to find something on this in google / live docs -
    but alas to no avail
    if anyone could give me a pointer in the right direction
    (just a tag would be a help) i'd be very grateful indeed.
    thanks very much

    thank you very much for your replies, this "union query"
    sounds like the way forward for me - thank you very much i shall go
    and investiage this now.
    the reason i was a bit slow in replying was that in interim i
    had coded around my problem
    <cfif recordset.currentrow eq 1>
    #output the extra row i wanted to add here#
    </cfif>
    which, whilst being a bit crude did do the job - however i
    will check out this union query and if that does what it sounds
    like it will - i'll document my final solution here in case this
    helps anyone else
    thanks again for your help guys

  • Problem of update rows in data object

    Hi everybody,
    I got the error message.
    Cannot update rows in data object /Samples/Monitor Express/BI_default_Project1_Process1.java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
    Please advise!!!!

    Are you using alterts related to that data object?
    Do you have any open report that uses that data object?

  • JTable: HOW TO INSERT ROWS AND DATA?

    I have one JFrame on screen and inside of this i have a JTable, the question is how to insert rows and data into the JTable?

    [http://java.sun.com/docs/books/tutorial/uiswing/components/table.html]
    In future, please post Swing questions to the [Swing Forum.|http://forums.sun.com/forum.jspa?forumID=57]
    In short, your TableModel is probably a DefaultTableModel . Study its API.

  • Help writing a excel macro to do a copy of 4 cells and paste transpose. I need to loop the copy and paste through 6900 rows of data.

      I need help writing a excelmacro to do a copy of 4 cells and paste transpose.  I need to loop the copy and paste through 6900 rows of data.  I started the macro with two rounds of copying & paster transposed but I need help getting it
    to loop through all rows.  Here is what macro looks like now.
        Range("I2:I5").Select
        Application.CutCopyMode = False
        Selection.Copy
        Range("J2").Select
        Selection.PasteSpecial Paste:=xlPasteAll, Operation:=xlNone, SkipBlanks:= _
            False, Transpose:=True
        Range("I6:I9").Select
        Application.CutCopyMode = False
        Selection.Copy
        Range("J6").Select
        Selection.PasteSpecial Paste:=xlPasteAll, Operation:=xlNone, SkipBlanks:= _
            False, Transpose:=True
    End Sub

    Thanks Jim for the solution above.
    Hi Brogents,
    Thanks for posting in our forum. Please note that this forum focuses on questions and feedback for Microsoft Office client. For any
    VBA/Macro related issues, I would suggest you to post in the forum of
    Excel for Developers, where you can get more experienced responses:
    https://social.msdn.microsoft.com/Forums/office/en-US/home?forum=exceldev
    The reason why we recommend posting appropriately is you will get the most qualified pool of respondents, and other partners who read the forums regularly can either share their knowledge or learn from your interaction with us. Thank you for your understanding.
    Regards,
    Ethan Hua
    TechNet Community Support
    It's recommended to download and install
    Configuration Analyzer Tool (OffCAT), which is developed by Microsoft Support teams. Once the tool is installed, you can run it at any time to scan for hundreds of known issues in Office
    programs.

  • File to RFC problem- data is not inserting into ztable in R3 system

    Hi
    i have done File to RFC scenario which picks data from flat file and inserts into ztable via RFC in R3. but while testing my scenario everything is successful in XI monitoring (Successful flag in MONI and RWB) and in auditlog message status is DLVD.
    it seems to be everything successful in XI and RFC call also successful in R3 system.
    but for some reason data is not inserting into table (RFC is used to insert data into ztable)
    Is there any way to debug RFC call excecution in XI..?
    RFC code is like this:
    insert ZMM_AUTO_GR from INPUT_TABLE.
    commit work.
    END FUNCTION.
    please advice what could be the reason not inserting into table.
    Help would be appreciated.
    Regards,
    Rajesh

    Hi Praveen,
    please see audit log- from communication channel monitoring..
    Receiver channel 'CC_INCA_RFC_SAPECC_Receiver' for party '', service 'R3DCLNT210' (internal name 'RfcClient[CC_INCA_RFC_SAPECC_Receiver]')
    Client data: {jco.client.lang=EN, jco.client.snc_mode=0, jco.client.client=210, jco.client.passwd=******, jco.webas.ignore_jdsr_error=1, jco.client.user=jsaha, jco.client.sysnr=00, jco.client.ashost=ausr3devdc02}
    Repository data: {jco.client.lang=EN, jco.client.snc_mode=0, jco.client.client=210, jco.client.passwd=******, jco.webas.ignore_jdsr_error=1, jco.client.user=jsaha, jco.client.sysnr=00, jco.client.ashost=ausr3devdc02}
    Current pool size: 1, maximum pool size : 1
    Channel History
    - OK: 2008-07-28 04:32:04 PDT: Message processed for interface ZAUTO_GR_STAGE_INCA
    - OK: 2008-07-28 04:31:04 PDT: Message processed for interface ZAUTO_GR_STAGE_INCA
    - OK: 2008-07-28 03:56:56 PDT: Message processed for interface ZAUTO_GR_STAGE_INCA
    - OK: 2008-07-28 03:49:04 PDT: Message processed for interface ZAUTO_GR_STAGE_INCA
    - OK: 2008-07-28 03:48:04 PDT: Message processed for interface ZAUTO_GR_STAGE_INCA

  • Alternatives to using update to flag rows of data

    Hello
    I'm looking into finding ways of improving the speed of a process, primarily by avoiding the use of an update statement to flag a row in a table.
    The problem with flagging the row is that the table has millions of rows in it.
    The logic is a bit like this,
    Set flag_field to 'F' for all rows in table. (e.g 104million rows updated)
    for a set of rules loop around this
    Get all rows that satisfy criteria for a processing rule. (200000 rows found)
    Process the rows collected data (200000 rows processed)
    Set flag_field to 'T' for those rows processed (200000 rows updated)
    end loop
    Once a row in the table has been processed it shouldn't be collected as part of any criteria of another rule further down the list, hence it needs to be flagged so that it doesn't get picked up again.
    With there being millions of rows in the table and sometimes rules only processing 200k rows, i've learnt recently that this will create a lot of undo to be written and will thus take a long amount of time. (any thoughts on that)
    Can anyone suggest anything other then using an update statement to flag each row to avoid it being processed again?
    Appreciate the help

    With regard to speeding up the process, the answer is
    "it depends". It all hinges on exactly what you mean
    by "Process the rows collected data". What does the
    processing involve?the processing involved is very straight forwards.
    data in these large tables stay unchanged. for sake of this example, i'll call this table orig_data_table, the rules are set by users who have their own tables built (for this example we'll call it target_data_table).
    the rules are there to take rows from the orig_data_table and insert them into the target_data_table.
    e.g
    update orig_data_table set processed='F';rule #1 states : select * from orig_data_table where feature_1 = 310;this applies to 3000 rows in orig_data_table.
    these 3000 rows get inserted to target_data_table.
    final step is to flag these 3000 rows in the orig_data_table so that they are not used by another rule proceeding rule 1 : update orig_data_table.processed='T' where feature_1 = 310;
    commit;rule #2 states :select * from orig_data_table where feature_1=310 and destination='Asia' and orig_data_table.processed = 'F'so it won't pick the 3000 rows that were processed as part of rule #1
    once rule #2 has got the rows from orig_data_table (e.g 400000 rows)
    those get inserted to the target_data_table, followed by them being flagged to avoid being retrieved again
    update orig_data_table.processed='T' where destination='Asia';
    commit;continue onto rule #3...
    - Is the process some kind of transformation of the
    ~200,000 selected rows which could possibly be
    achieved in SQL alone, or is it an extremely complex
    transformation which can not be done in pure SQL?its not at all complex, as i say the data in orig_data_table is unchanged bar the processed field which is initially set to 'F' for all rows and then set to 'T' after each rule for those rows fulfilling the criteria of each rule.
    - Does the FLAG_FIELD exist purely for the use of
    this process or is it referred to by other
    procedures?the flag_field is only for this purpose and not used elsewhere
    Having said that, as a first step to simply avoid the
    update of the flag field, I would suggest that you
    use bulk processing and include a table of booleans
    to act as the indicator for whether a particular row
    has been processed or not.could you elaborate a bit more on this table of booleans for me, it sounds an interesting approach for me to test...
    many thanks again
    Sandip

Maybe you are looking for