QUERY FOR HOW TO ACCESS NEXT ROW WHILE IN CURRENT ROW
Hi, can you please make a oracle sql query for the following.
My Data in table dt0attlog:
ID staffid logdt login logout
01 aw101 01.12.11 01.12.11 08.30
01 aw101 01.12.11 01.12.11 10.30
01 aw101 01.12.11 01.12.11 11.40
01 aw101 01.12.11 01.12.11 14.30
01 aw101 01.12.11 01.12.11 15.00
01 aw101 01.12.11 01.12.11 17.45
01 aw102 01.12.11 01.12.11 19.20
01 aw102 01.12.11 01.12.11 20.30
01 aw102 01.12.11 01.12.11 21.50
01 aw102 01.12.11 01.12.11 23.10
01 aw102 01.12.11 01.12.11 23.20
01 aw102 02.12.11 02.12.11 07.00
01 aw102 02.12.11 02.12.11 18.00
01 aw102 03.12.11 03.12.11 04.30
01 aw103 01.12.11 01.12.11 09.40
01 aw104 01.12.11 01.12.11 18.00
My required output:
ID staffid logdt login logout diff-in-seconds
01 aw101 01.12.11 01.12.11 08.30 01.12.11 10.30 7200
01 aw101 01.12.11 01.12.11 11.40 01.12.11 14.30 10200
01 aw101 01.12.11 01.12.11 15.00 01.12.11 17.45 9900
01 aw102 01.12.11 01.12.11 19.20 01.12.11 20.30 4200
01 aw102 01.12.11 01.12.11 21.50 01.12.11 23.10 4800
01 aw102 01.12.11 01.12.11 23.20 02.12.11 07.00 27600
01 aw102 02.12.11 02.12.11 18.00 03.12.11 04.30 37800
01 aw103 01.12.11 01.12.11 09.40
01 aw104 01.12.11 01.12.11 18.00
Here record aw102 & dt. 01.12.11 / 02.12.11, it should shows the next day out in
the current date ie. 01.12.11.
thanks and await your great help please.
the followings are the testcase
SQL> create table dt0device (
2 deviceid varchar2(15),
3 staffid varchar2(10),
4 logdt date,
5 in_out_flag varchar2(3));
Table created.
SQL> insert into dt0device values('01','aw101',to_date('01.12.2011 08:30','DD/MM/RRRR HH24.MI'),'IN');
1 row created.
SQL> insert into dt0device values('01','aw101',to_date('01.12.2011 10:30','DD/MM/RRRR HH24.MI'),'OUT');
1 row created.
SQL> insert into dt0device values('01','aw101',to_date('01.12.2011 11:40','DD/MM/RRRR HH24.MI'),'IN');
1 row created.
SQL> insert into dt0device values('01','aw101',to_date('01.12.2011 14:30','DD/MM/RRRR HH24.MI'),'OUT');
1 row created.
SQL> insert into dt0device values('01','aw101',to_date('01.12.2011 15:00','DD/MM/RRRR HH24.MI'),'IN');
1 row created.
SQL> insert into dt0device values('01','aw101',to_date('01.12.2011 17:45','DD/MM/RRRR HH24.MI'),'OUT');
1 row created.
SQL>
SQL> insert into dt0device values('01','aw102',to_date('01.12.2011 19:20','DD/MM/RRRR HH24.MI'),'IN');
1 row created.
SQL> insert into dt0device values('01','aw102',to_date('01.12.2011 20:30','DD/MM/RRRR HH24.MI'),'OUT');
1 row created.
SQL> insert into dt0device values('01','aw102',to_date('01.12.2011 21:50','DD/MM/RRRR HH24.MI'),'IN');
1 row created.
SQL> insert into dt0device values('01','aw102',to_date('01.12.2011 23:10','DD/MM/RRRR HH24.MI'),'OUT');
1 row created.
SQL> insert into dt0device values('01','aw102',to_date('01.12.2011 23:20','DD/MM/RRRR HH24.MI'),'IN');
1 row created.
SQL> insert into dt0device values('01','aw102',to_date('02.12.2011 07:00','DD/MM/RRRR HH24.MI'),'OUT');
1 row created.
SQL> insert into dt0device values('01','aw102',to_date('02.12.2011 18:00','DD/MM/RRRR HH24.MI'),'IN');
1 row created.
SQL> insert into dt0device values('01','aw102',to_date('03.12.2011 04:30','DD/MM/RRRR HH24.MI'),'OUT');
1 row created.
SQL>
SQL> insert into dt0device values('01','aw103',to_date('01.12.2011 09:40','DD/MM/RRRR HH24.MI'),'IN');
1 row created.
SQL> insert into dt0device values('01','aw104',to_date('01.12.2011 18:00','DD/MM/RRRR HH24.MI'),'OUT');
1 row created.
SQL> create table dt0attlogdevice
2 ( staffid varchar2(10),
3 logdt date,
4 login date,
5 logout date);
Table created.
SQL> insert into dt0attlogdevice select staffid,logdt,
2 decode(in_out_flag,'IN',logdt,null) login,
3 decode(in_out_flag,'OUT',logdt,null) logout
4 from dt0device;
16 rows created.
SQL> select staffid,to_char(logdt,'DD/MM/RR') logdt, to_char(login,'DD/MM/RR HH24.MI') login,
2 to_char(logout,'DD/MM/RR HH24.MI') logout
3 from dt0attlogdevice;
STAFFID LOGDT LOGIN LOGOUT
aw101 01/12/11 01/12/11 08.30
aw101 01/12/11 01/12/11 10.30
aw101 01/12/11 01/12/11 11.40
aw101 01/12/11 01/12/11 14.30
aw101 01/12/11 01/12/11 15.00
aw101 01/12/11 01/12/11 17.45
aw102 01/12/11 01/12/11 19.20
aw102 01/12/11 01/12/11 20.30
aw102 01/12/11 01/12/11 21.50
aw102 01/12/11 01/12/11 23.10
aw102 01/12/11 01/12/11 23.20
STAFFID LOGDT LOGIN LOGOUT
aw102 02/12/11 02/12/11 07.00
aw102 02/12/11 02/12/11 18.00
aw102 03/12/11 03/12/11 04.30
aw103 01/12/11 01/12/11 09.40
aw104 01/12/11 01/12/11 18.00
16 rows selected.
===
from the above table , I want to generate ouput as below:
staffid logdt login logout diff-in-seconds
aw101 01.12.11 01.12.11 08.30 01.12.11 10.30 7200
aw101 01.12.11 01.12.11 11.40 01.12.11 14.30 10200
aw101 01.12.11 01.12.11 15.00 01.12.11 17.45 9900
aw102 01.12.11 01.12.11 19.20 01.12.11 20.30 4200
aw102 01.12.11 01.12.11 21.50 01.12.11 23.10 4800
aw102 01.12.11 01.12.11 23.20 02.12.11 07.00 27600
aw102 02.12.11 02.12.11 18.00 03.12.11 04.30 37800
aw103 01.12.11 01.12.11 09.40
aw104 01.12.11 01.12.11 18.00
Here record aw102 & dt. 01.12.11 / 02.12.11, it should shows the next day out in
the current date ie. 01.12.11.
I dont know how to make query for the above output.
please help me.
Similar Messages
-
Query for create manual tabular form using apex collection add row button functionality
Hello everyone
My requirement is i created a tabular form manually using apex collection but if i click on add row button then previously selected data refreshed and added new row in this form it is fine.but i don't want to refreshed previously selected data and click on add row button then add new row .how it is possible? plz help
Thanks & Regards,
UjwalaUjwala
Instead of starting a new thread with the same question as Query for create manual tabular form using apex collection add row button functionality.
Could you answer the question about what you see while debug the javascript code.
If you don't understand the question or have trouble debug javascript let us know.
Nicolette -
How to access contact list while a call is going o...
Can anybody how to access contact list while a call is going on or call is on hold in Nokia E5 moblile?
Hit the menu key, to switch to the application menu, and open the Contacts app; the E5 supports multitasking just fine.
-
Query for how to display unique rows in a table
Can i have a query for displaying unique rows in a table.
use d query
select distinct col1,col2... from table ; -
How to access next record from database on to form
hi
i have written the following piece of code to retrieve data from database oon to form...
Try
rset = oDICompany.GetBusinessObject(SAPbobsCOM.BoObjectTypes.BoRecordset)
query = "Select * from [@TEST] where Code = ('" + oform.Items.Item("6").Specific.value + "') "
rset.DoQuery(query)
Catch ex As Exception
SBO_Application.MessageBox(ErrorToString)
End Try
' oform.Items.Item("6").Specific.value = rset.Fields.Item("Code").Value
oform.Items.Item("7").Specific.value = rset.Fields.Item("Name").Value
oform.Items.Item("8").Specific.value = rset.Fields.Item("U_Sal").Value
but i can see only one record on my form controls.... i have placed on more button called " Next" so that i can access next records from DB when i click on "Next" button...
Public Sub NextRecords()
Try
rset.MoveFirst()
While Not rset.EoF
' oform.Items.Item("6").Specific.value = rset.Fields.Item("Code").Value
oform.Items.Item("7").Specific.value = rset.Fields.Item("Name").Value
oform.Items.Item("8").Specific.value = rset.Fields.Item("U_Sal").Value
rset.MoveNext()
End While
rset.MoveNext()
Catch ex As Exception
SBO_Application.MessageBox(ErrorToString)
SBO_Application.MessageBox("Updated")
End Try
End sub
i'm not able to access next records...
plz provide me the solution and code for this how to handle this scenario....From your question and code sample given, I think the problem is you are seeing only the last record when pressing the next button.
In the Next button press, you are coded such a way that it will populate the last record.
Try removing the do..While.. loop and simply code like
if Not rset.EoF
rset.MoveNext()
oform.Items.Item("6").Specific.value = rset.Fields.Item("Code").Value
oform.Items.Item("7").Specific.value = rset.Fields.Item("Name").Value
oform.Items.Item("8").Specific.value = rset.Fields.Item("U_Sal").Value
end if
So when you click next, you can see the next record. Not the last record.
Anoop -
How to access the form while processing?
Hello ,
how can one access his form while its processing a certain task - like a query or running a report - in order to cancel or abort this process?..
Thanks...For being able to interrupt a query you can set the property "Interaction Mode" at form-level.
For any other interruption you have to program it one your own. -
I recently bought an iPod touch and had no trouble loading all the existing music I have in iTunes to my new iPod. The problem is that no matter what I try I cannot transfer purchases I made on the new iPod into iTunes. Every time I try, "Transfer Purchases" is greyed out. As a result the seven tracks that I bought on the iPod are trapped on the device. I can't get them into iTunes. Does anyone have any suggestions for how I can get the seven new purchases currently trapped on my iPod transferred to iTunes?
I've tried suggestions from multiple support forums, and nothing has worked. Does anyone know why "Transfer Purchases" would be greyed out and how I can fix it so I can get the music purchases from the device to the computer. Before anyone asks, this has not happened with any other Apple device I have owned, including my iPhone 4 8GB, iPod Touch 2nd Gen 32GB, iPad 1st Gen 64GB, and iPad 2 64GB. Why is it suddenly happening now?
My new iPod is an iPod Touch 5th generation 64GB using iOS 7.1.2, and iTunes is version 11.
I've never had this problem before. It's driving me nuts. Any help is very much appreciated.Does iTunes see the iPod?
Is the computer authorized for the account that purchased the items?
iTunes Store: Authorize or deauthorize your Mac or PC -
Copying values from a row to a current row
hi all, i have a complex scenario here. i have a table that has the following data.
WITH table1 AS
SELECT 111 the_id, To_Date('6/30/2009','mm/dd/yyyy') dt, 93 src, 'A-C' the_name, 'AA' cod, 'BB' pad, ' CC' tek FROM dual UNION ALL
SELECT 111 the_id, To_Date('10/1/2009','mm/dd/yyyy') dt, 93 src, 'B-L' the_name, 'AA' cod, 'NN' pad, ' TT' tek FROM dual UNION all
SELECT 111 the_id, To_Date('10/2/2009','mm/dd/yyyy') dt, 93 src, 'C-H' the_name, 'BA' cod, 'RR' pad, ' BAN' tek FROM dual UNION ALL
SELECT 111 the_id, To_Date('10/5/2009','mm/dd/yyyy') dt, 93 src, 'D-R' the_name, 'HH' cod, 'FCY' pad, ' BANW' tek FROM dual UNION ALL
SELECT 111 the_id, To_Date('10/6/2009','mm/dd/yyyy') dt, 93 src, 'E-C' the_name, 'JJ' cod, 'EE' pad, ' JJ' tek FROM dual UNION ALL
SELECT 111 the_id, To_Date('10/7/2009','mm/dd/yyyy') dt, 93 src, 'F-L' the_name, 'DD' cod, null pad, ' BAN' tek FROM dual UNION all
SELECT 111 the_id, To_Date('10/8/2009','mm/dd/yyyy') dt, 93 src, 'G-H' the_name, 'HG' cod, 'YY' pad, ' BAN' tek FROM dual UNION ALL
SELECT 111 the_id, To_Date('10/9/2009','mm/dd/yyyy') dt, 93 src, 'K-R' the_name, 'EE' cod, 'FCY' pad, ' BANW' tek FROM dual UNION ALL
SELECT 111 the_id, To_Date('7/31/2009','mm/dd/yyyy') dt, 93 src, 'G-H' the_name, 'HG' cod, 'YY' pad, ' BAN' tek FROM dual UNION ALL
SELECT 111 the_id, To_Date('8/3/2009','mm/dd/yyyy') dt, 93 src, 'K-R' the_name, 'EE' cod, 'FCY' pad, ' BANW' tek FROM dual UNION ALL
SELECT 111 the_id, To_Date('8/4/2009','mm/dd/yyyy') dt, 93 src, 'K-R' the_name, 'EE' cod, 'FCY' pad, ' BANW' tek FROM dual UNION ALL
SELECT 111 the_id, To_Date('8/5/2009','mm/dd/yyyy') dt, 93 src, 'K-R' the_name, 'EE' cod, 'FCY' pad, ' BANW' tek FROM dual UNION ALL
SELECT 111 the_id, To_Date('8/6/2009','mm/dd/yyyy') dt, 93 src, 'K-R' the_name, 'EE' cod, 'FCY' pad, ' BANW' tek FROM dual UNION ALL
SELECT 111 the_id, To_Date('8/7/2009','mm/dd/yyyy') dt, 93 src, 'K-R' the_name, 'EE' cod, 'FCY' pad, null tek FROM dual UNION ALL
SELECT 111 the_id, To_Date('6/30/2009','mm/dd/yyyy') dt, 22 src, 'A-C' the_name, 'AA' cod, 'BB' pad, ' CC' tek FROM dual UNION ALL
SELECT 111 the_id, To_Date('10/1/2009','mm/dd/yyyy') dt, 22 src, 'B-L' the_name, 'AA' cod, 'NN' pad, ' TT' tek FROM dual UNION all
SELECT 111 the_id, To_Date('10/2/2009','mm/dd/yyyy') dt, 22 src, 'C-H' the_name, 'BA' cod, 'RR' pad, ' BAN' tek FROM dual UNION ALL
SELECT 111 the_id, To_Date('10/5/2009','mm/dd/yyyy') dt, 22 src, 'D-R' the_name, 'HH' cod, 'FCY' pad, ' BANW' tek FROM dual UNION ALL
SELECT 111 the_id, To_Date('10/6/2009','mm/dd/yyyy') dt, 22 src, 'E-C' the_name, 'JJ' cod, 'EE' pad, ' JJ' tek FROM dual UNION ALL
SELECT 111 the_id, To_Date('10/7/2009','mm/dd/yyyy') dt, 22 src, 'F-L' the_name, 'DD' cod, 'FIC' pad, ' BAN' tek FROM dual UNION all
SELECT 111 the_id, To_Date('10/8/2009','mm/dd/yyyy') dt, 22 src, 'G-H' the_name, 'HG' cod, 'YY' pad, ' BAN' tek FROM dual UNION ALL
SELECT 111 the_id, To_Date('10/9/2009','mm/dd/yyyy') dt, 22 src, 'K-R' the_name, 'EE' cod, 'FCY' pad, ' BANW' tek FROM dual UNION ALL
SELECT 111 the_id, To_Date('10/30/2009','mm/dd/yyyy') dt, 168 src, 'T-C' the_name, 'WW' cod, 'AA' pad, ' NN' tek FROM dual UNION ALL
SELECT 111 the_id, To_Date('11/2/2009','mm/dd/yyyy') dt, 168 src, 'Y-L' the_name, 'HH' cod, 'AA' pad, ' BAN' tek FROM dual UNION all
SELECT 111 the_id, To_Date('11/3/2009','mm/dd/yyyy') dt, 168 src, 'G-H' the_name, 'BA' cod, 'WW' pad, ' BAN' tek FROM dual UNION ALL
SELECT 111 the_id, To_Date('11/4/2009','mm/dd/yyyy') dt, 168 src, 'E-R' the_name, 'JJ' cod, 'XX' pad, ' DD' tek FROM dual UNION ALL
SELECT 111 the_id, To_Date('11/5/2009','mm/dd/yyyy') dt, 168 src, 'T-C' the_name, 'TT' cod, 'JJ' pad, ' WW' tek FROM dual UNION ALL
SELECT 111 the_id, To_Date('11/6/2009','mm/dd/yyyy') dt, 168 src, 'H-L' the_name, 'EE' cod, 'DD' pad, ' BAN' tek FROM dual UNION all
SELECT 111 the_id, To_Date('11/9/2009','mm/dd/yyyy') dt, 168 src, 'S-H' the_name, 'BA' cod, 'WW' pad, ' BAN' tek FROM dual UNION ALL
SELECT 111 the_id, To_Date('11/10/2009','mm/dd/yyyy') dt, 168 src, 'H-R' the_name, 'VV' cod, 'FCY' pad, ' YY' tek FROM dual UNION ALL
SELECT 111 the_id, To_Date('11/30/2009','mm/dd/yyyy') dt, 90 src, 'V-C' the_name, 'GG' cod, 'FCS' pad, ' BAN' tek FROM dual UNION ALL
SELECT 111 the_id, To_Date('12/1/2009','mm/dd/yyyy') dt, 90 src, 'B-L' the_name, 'QQ' cod, 'GG' pad, ' BAN' tek FROM dual UNION all
SELECT 111 the_id, To_Date('12/2/2009','mm/dd/yyyy') dt, 90 src, 'A-H' the_name, 'BA' cod, 'WW' pad, ' BAN' tek FROM dual UNION ALL
SELECT 111 the_id, To_Date('12/3/2009','mm/dd/yyyy') dt, 90 src, 'N-R' the_name, 'TT' cod, 'JJ' pad, ' TT' tek FROM dual UNION ALL
SELECT 111 the_id, To_Date('12/7/2009','mm/dd/yyyy') dt, 90 src, 'C-C' the_name, 'YY' cod, 'QQ' pad, ' WE' tek FROM dual UNION ALL
SELECT 111 the_id, To_Date('12/8/2009','mm/dd/yyyy') dt, 90 src, 'X-L' the_name, 'UU' cod, 'JJ' pad, ' BAN' tek FROM dual UNION all
SELECT 111 the_id, To_Date('12/9/2009','mm/dd/yyyy') dt, 90 src, 'V-H' the_name, 'BA' cod, 'PP' pad, ' YR' tek FROM dual UNION ALL
SELECT 111 the_id, To_Date('12/10/2009','mm/dd/yyyy') dt, 90 src, 'E-R' the_name, 'FIN2' cod, 'FCY' pad, ' RE' tek FROM dual UNION ALL
SELECT 112 the_id, To_Date('2/28/2009','mm/dd/yyyy') dt, 93 src, 'V-C' the_name, 'EE' cod, 'FCS' pad, ' BAN' tek FROM dual UNION ALL
SELECT 112 the_id, To_Date('3/2/2009','mm/dd/yyyy') dt, 93 src, 'A-S' the_name, 'BA' cod, 'WW' pad, ' TT' tek FROM dual UNION ALL
SELECT 112 the_id, To_Date('3/3/2009','mm/dd/yyyy') dt, 93 src, 'N-R' the_name, 'TT' cod, 'JJ' pad, ' TT' tek FROM dual UNION ALL
SELECT 112 the_id, To_Date('3/4/2009','mm/dd/yyyy') dt, 93 src, 'C-C' the_name, 'YY' cod, 'QQ' pad, ' WE' tek FROM dual UNION ALL
SELECT 112 the_id, To_Date('3/5/2009','mm/dd/yyyy') dt, 93 src, 'X-L' the_name, 'SS' cod, 'JJ' pad, ' BAN' tek FROM dual UNION all
SELECT 112 the_id, To_Date('3/6/2009','mm/dd/yyyy') dt, 93 src, 'V-H' the_name, 'BA' cod, 'PP' pad, ' YR' tek FROM dual UNION ALL
SELECT 112 the_id, To_Date('3/9/2009','mm/dd/yyyy') dt, 93 src, 'E-R' the_name, 'HH' cod, 'KK' pad, ' RE' tek FROM dual
)so as you can see, there are month end dates and well and daily dates. the daily are basically business days. what i want to do is the following
for a particular id, i would like to take the month end date, look forward 5 business day and copy the column values from the 5th business day
to the current row.
there is two exceptions:
1. i am only interested on those src=93 and 168.
2. the_name column will not be copy, but the rest will
so lets take an example, id = 111 src = 93. since i am only interested in src=93 and 168, this data fall in that category.
the month end dates for id=111 and src=93 are 6/30/09 and 7/31/2009.
in this case i want to look forward 5 business days. in the case of 6/30/09, the 5th business day is 10/7/2009 and for 7/31/2009 is 8/7/2009.
i want to take all the column values except the_name column and display those values for 6/30/09. same thing with 7/31/2009, take column values from 8/7/2009
and display those values.
so the output for 6/30/2009 should look like this
THE_ID DT SRC THE_NAME COD PAD TEK
111 6/30/2009 93 A-C DD BANif ou notice here 6/30/2009 retain the value for the_name column but took the values for the remaining column from 10/7/2009 (even the null values got copy)
the same logic should apply to 7/31/2009 and value should be taking from 8/7/2009
if the src is not equal to 93 or 168. then just display the data and no logic apply, for id=111 and src=90
no logic apply, the data should just be display.
i would like to write a query tha give me the output below.
i tried using last_value function but i am using oracle 9i and ignore null is not supported in oracle 9i. i need to copy null if the 5th day contain null in the columns
the final ouput for the data above should be this
THE_ID DT SRC THE_NAME COD PAD TEK
111 6/30/2009 93 A-C DD BAN
111 10/1/2009 93 B-L AA NN TT
111 10/2/2009 93 C-H BA RR BAN
111 10/5/2009 93 D-R HH FCY BANW
111 10/6/2009 93 E-C JJ EE JJ
111 10/7/2009 93 F-L DD FIC BAN
111 10/8/2009 93 G-H HG YY BAN
111 10/9/2009 93 K-R EE FCY BANW
111 7/31/2009 93 G-H EE FCY
111 8/3/2009 93 K-R EE FCY BANW
111 8/4/2009 93 K-R EE FCY BANW
111 8/5/2009 93 K-R EE FCY BANW
111 8/6/2009 93 K-R EE FCY BANW
111 8/7/2009 93 K-R EE FCY
111 6/30/2009 22 A-C AA BB CC
111 10/1/2009 22 B-L AA NN TT
111 10/2/2009 22 C-H BA RR BAN
111 10/5/2009 22 D-R HH FCY BANW
111 10/6/2009 22 E-C JJ EE JJ
111 10/7/2009 22 F-L DD FIC BAN
111 10/8/2009 22 G-H HG YY BAN
111 10/9/2009 22 K-R EE FCY BANW
111 10/30/2009 168 T-C EE DD BAN
111 11/2/2009 168 Y-L HH AA BAN
111 11/3/2009 168 G-H BA WW BAN
111 11/4/2009 168 E-R JJ XX DD
111 11/5/2009 168 T-C TT JJ WW
111 11/6/2009 168 H-L EE DD BAN
111 11/9/2009 168 S-H BA WW BAN
111 11/10/2009 168 H-R VV FCY YY
111 11/30/2009 90 V-C GG FCS BAN
111 12/1/2009 90 B-L QQ GG BAN
111 12/2/2009 90 A-H BA WW BAN
111 12/3/2009 90 N-R TT JJ TT
111 12/7/2009 90 C-C YY QQ WE
111 12/8/2009 90 X-L UU JJ BAN
111 12/9/2009 90 V-H BA PP YR
111 12/10/2009 90 E-R FIN2 FCY RE
112 2/28/2009 93 V-C BA PP YR
112 3/2/2009 93 A-S BA WW TT
112 3/3/2009 93 N-R TT JJ TT
112 3/4/2009 93 C-C YY QQ WE
112 3/5/2009 93 X-L SS JJ BAN
112 3/6/2009 93 V-H BA PP YR
112 3/9/2009 93 E-R HH KK REhi i am using oracle 9i 9.2.0.7.0
you are right about the 5th business day, for 6/30/2010 it should have been 8/7/2010. 7/31/2010 is a month end so it doesnt count when you go down the list of business days. and for 7/31/2010 the 5th business day should have been 10/7/2010.
sorry for the mistake, i got both of them backwards. so for the output, 6/30/2010 should copy from 8/7/2010 and 7/31/2010 from 10/7/2010
THE_ID DT SRC THE_NAME COD PAD TEK
111 6/30/2009 93 A-C EE FCY
111 8/3/2009 93 K-R EE FCY BANW
111 8/4/2009 93 K-R EE FCY BANW
111 8/5/2009 93 K-R EE FCY BANW
111 8/6/2009 93 K-R EE FCY BANW
111 8/7/2009 93 K-R EE FCY
111 7/31/2009 93 G-H DD BAN
111 10/1/2009 93 B-L AA NN TT
111 10/2/2009 93 C-H BA RR BAN
111 10/5/2009 93 D-R HH FCY BANW
111 10/6/2009 93 E-C JJ EE JJ
111 10/7/2009 93 F-L DD BAN
111 10/8/2009 93 G-H HG YY BAN
111 10/9/2009 93 K-R EE FCY BANWEdited by: elmasduro on May 10, 2010 11:53 AM -
Hi all,
I have got the requirement where my user want have Access Bex Query into his system.
I know that in Query Properties we have option "Allow External Access to this Query" and I have selected that option.
But I don't know what sould be configuration I need to do after that.
anyone who have worked on it please tell me.Hello,
See the below inforamtion, i think this option wont solve ur requirement:
Release for OLE DB for OLAP
External reporting tools that communicate using the OLE DB for OLAP interface use queries as data sources. If you want to release this query as a data source for external Reporting tools, select Allow External Access to this Query.
Note: Queries containing formulas with the operators %RT, %CT, %GT, SUMRT, SUMCT, SUMGT, and LEAF cannot be released for OLE DB for OLAP. These operators are dependent on how the list is displayed in the BEx Analyzer and the formulas return unexpected values when using OLE DB for OLAP or MDX. You may be able to obtain the required result by selecting constants.
Go thru the link below for detailed information:
http://help.sap.com/saphelp_nw04/helpdata/EN/03/cf903c47c95875e10000000a11405a/frameset.htm
Regards,
Shashank -
How to access external drives while in Windows
Using VMWare Fusion as the system hosting Windows XP. Have specific programs in Windows only but of course they work much better on the IMac. I edit a ton of video and have the vids all stored on eternal drives. These drives are read by the Mac and all show up on the desktop and are accessible for all Mac programs.
Here's the issue. I need to access those external drives from a Windows video editing program being run thru Fusion. The Windows program is accessing a folder via "Shared folder on host" but the only folders showing up there are the ones listed under "Home" om "My Places". I'm sure this is nothing more than a setting but I am in need of help! All my editing is held up at the moment so any assistance is greatly appreciated for this Apple rookie. Thanks.I don't have my laptop with fusion loaded, so I can't think of the exact terms. However, you should be able to set the shared folders in the settings for the virtual machine. The ones you see are the default setup, but you can define more paths to view while in Fusion.
-
Best practice for how to access a set of wsdl and xsd files
I've recently beeing poking around with the Oracle ESB, which requires a bunch of wsdl and xsd files from HOME/bpel/system/xmllib. What is the best practice for including these files in a BPEL project? It seems like a bad idea to copy all these files into every project that uses the ESB, especially if there are quite a few consumers of the bus. Is there a way I can reference this directory from the project so that the files can just stay in a common place for all the projects that use them?
BretHi,
I created a project (JDeveloper) with local xsd-files and tried to delete and recreate them in the structure pane with references to a version on the application server. After reopening the project I deployed it successfully to the bpel server. The process is working fine, but in the structure pane there is no information about any of the xsds anymore and the payload in the variables there is an exception (problem building schema).
How does bpel know where to look for the xsd-files and how does the mapping still work?
This cannot be the way to do it correctly. Do I have a chance to rework an existing project or do I have to rebuild it from scratch in order to have all the references right?
Thanks for any clue.
Bette -
? Tsql query to add a sumTotal column from value in current row + value in previous row
--using Sql Server 2008 (Developer)
create table #tmp1(rowID int Identity(1,1), val1 int)
insert into #tmp1(val1)
select 5 union all
select 8 union all
select 12 union all
select 13 union all
select 22 union all
select -7 union all
select 25 union all
select 19 union all
select 32 union all
select -17
What Tsql could produce a result set as follows based on the data from #tmp1?
rowID val1 sumTotal
1 5 5
2 8 13
3 12 25
4 13 37
5 22 59
6 -7 52
7 25 77
8 19 96
9 32 128
10 -17 111
Rich PIn SQL 2008 check these links
http://social.technet.microsoft.com/wiki/contents/articles/19670.t-sql-useful-links.aspx#Running_Total
In SQL 2012 and up, the Running total can be calculated directly with ordered SUM
For every expert, there is an equal and opposite expert. - Becker's Law
My blog
My TechNet articles -
Customer support html (html service) - how can i query for 'closed' SRs
hi,
11.5.10.2
in customer support html (html service - CSZ), is there any facility to query for SRs that are in 'closed' status?
currently, a SR in 'closed' status can only be queried if agent knows the exact SR number. on Advanced Search page, even though the application allows 'closed' status to be selected, it does not return any record.
help is appreciated, as this is critical to our business.
regards.You can search for Closed SRs. Ensure that the search criteria 'Active' is set to 'No'. This will return back closed SRs.
Who is the customer? Can you provide some more details on the implementation? (you can send me an email to [email protected])
Thanks.
Edited by: dejoseph on Mar 31, 2010 12:00 PM -
How to get default values while using the transaction "BP"
Hi Group,
I have a query on how to get default values while using the transaction <b>BP</b>?
The thing is:
when I enter into the transaction "BP", I need to see some default values to some of the input fields in the screen.
how can I achieve this?
So please kindly let me know the procedure to achieve this.
Thanks & Regards,
Vishnu.Hi,
The events of BDT can be used to default some fields on creating a partner.
For this create a function module for ISDAT. attach that event in BUS7.
In the ISDAT funtion modulethe following code should be used.
For example to set the nationality:
I_BUSDEFAULT-NATIO = 'DE.
CALL FUNCTION 'BUP_BUPA_FIELDVALUES_SET'
EXPORTING
i_busdefault = I_BUSDEFAULT
Regards, Smita. -
Hi to all.........
Plz tell me the ABAP query for how to delete the duplicate posting months from dfkkop & after
then the query to count the no of rows of dfkkop ??
Thanks & Regards........
Rajeev Shrivastavahi check this..
tables:marc .
data: it_marc like marc occurs 0.
select-options:s_matnr for marc-matnr .
data: v_count type i .
select matnr
werks
from
marc into table it_marc
where matnr in s_matnr .
delete adjacent duplicates from it_marc comparing werks .
describe table it_marc lines v_count .
Maybe you are looking for
-
Failure to backup while updating 3GS to iOS5 - now iTunes doesn't recognize iPhone!
Hi, I'm trying to update my 3GS to iOS5. Working on a brand-new Macbook Pro with Lion 10.7.2. Made sure I had the newest iTunes (10.5), synced my phone, transferre purchases to the computer, backed up manually for good measure. Downloaded the iOS5 up
-
EA1 - Manage Database doesn't work
Environment: Windows 2000 Connected to Oracle 10.2 or 9.2 (Using oracle spatial) Right click on a connection and go Manage Database. It brings up a tab with this text in the middle of it Only Oracle connections are currently supported to display stat
-
Where is the jQuery options in DW CS5?
I installed Trial DW CS5, but unable to find options for jQuery and HTML 5. Is there any feature 'bout jQuery Intellisence and HTML 5?
-
Can someone help? my ipad is stuck on the apple logo!
my ipad wont turn on. its stuck on the apple logo. i already tried to hold down the power button and the home button a million times but it wont work. itunes wont recognize my ipad when i plug it in. I DONT KNOW WHAT TO DO!!!!!! my ipad is jailbroken
-
.mac system pref gives wrong password
I saw this question in the archives, but it was not answered. I hope someone can help me. I have acquired an iMac and am trying to sync and run Backup. Backup says it is in trial version because I am not a .mac member. Sync says my iDisk is not conne