Random Data Selection based on Worksheet results
I need to randomly select a percentage of records in a discoverer query. So if I have 1500 records from worksheet1 I want a second worksheet to select 6% of the records from sheet one and display them. Any ideas??
Hi Bill,
Have you tried the new SAMPLE sytax for Oracle 9i?
I think it may have been in 8i too - but you'd have to check.
You specify a number in the SAMPLE(n) after the table name in your from clause, supposed to be a percent. I have had inconsistent results - but then our dev database can get a bit sick at times.
Try using a correlated subquery referencing the 1st worksheet and try adding the SAMPLE bit. Sorry, I haven't tried it in Disco.
Let us all know how you get on.
Lance
Similar Messages
-
Routine in Infopackage data selection doesnt give appropriate results...
Hi Gurus,
I need to pull data into PSA (BW 3.5) based on a certain selections in the Infopackage. Selection is based on specific values of Infoobject 0PLANT , however, as these values are multiple and do not fall in a specific range I have written a routine to derive these values.
The routine does the following steps :
- creates an internal table from /bio/mplant and deletes the plant values that I do not wish to consider in the extraction.
- delete data from l_t_range for fieldname = 'PLANT'
- Appends data from the internal table to l_t_range.
However, when I execute the infopackage, the extraction is done for ALL the 0PLANT values i.e it includes the data for 0PLANT value which have been delete from the internal table.
My routine is :
$$ end of global - insert your declaration only before this line -
InfoObject = 0PLANT
Fieldname = PLANT
data type = CHAR
length = 000004
convexit =
form compute_PLANT
tables l_t_range structure rssdlrange
using p_infopackage type rslogdpid
p_fieldname type rsfnm
changing p_subrc like sy-subrc.
Insert source code to current selection field
$$ begin of routine - insert your code only below this line -
TYPES ls_range like l_t_range.
data: l_idx like sy-tabix.
DATA: lt_plant like /bi0/mplant OCCURS 0 with header line.
SELECT PLANT from /bi0/mplant into lt_Plant WHERE objvers = 'A
ENDSELECT.
delete lt_plant WHERE plant = 'W206'.
delete lt_plant WHERE plant = 'WF11'.
delete lt_plant WHERE plant = 'W945'.
DELETE lt_plant WHERE plant = 'W530'.
read table l_t_range with key
fieldname = 'PLANT'.
l_idx = sy-tabix.
DELETE l_t_range where fieldname = 'PLANT'.
Loop at lt_plant.
l_t_range-sign = 'I' .
l_t_range-low = lt_plant-plant.
l_t_range-OPTION = 'EQ'.
append l_t_range.
endloop.
modify l_t_range index l_idx.
p_subrc = 0.
$$ end of routine - insert your code only before this line -
endform.
Any bugs in the routines ?try this one:
Loop at lt_plant.
if lt_plant-plant ne 'WF11' or lt_plant-plant ne 'W945' or lt_plant-plant ne 'W530'.
l_t_range-sign = 'I' .
l_t_range-low = lt_plant-plant.
l_t_range-OPTION = 'EQ'.
append l_t_range.
endif.
endloop.
or
don't use a table with header ( use a standard table and use a work area to access the table ) and do an other select like this:
SELECT PLANT from /bi0/mplant
into corresponding fields of table lt_Plant
WHERE objvers = 'A
and plant ne 'WF11'
and plant ne 'W945'
and plant ne 'W530'.
I hope it helps...
Kind regard.
Tobias
Edited by: Tobias Kreuser on Aug 23, 2010 11:34 AM -
Delete Duplicate rows in Data Package based on selection
Hello experts,
I have the data coming from Oracle using DB_Connect. The data has duplicate order no. I need to delete the duplicate rows in the data package based selection before updating the data target.
I am thinking of writing this in updaterule start routine. I would greatly appreciate any sample code on selective deletion of data package rows.
Thanks a lot!
SriNagesh,
Thanks for your reply.
Do I need write this in Update Start routine?
Another thing the order number field is coming from source system. Currently we are not mapping/assingning to InfoObject. In other words we are not seding order no to data target.
In my query can I write something like this...
DELETE ADJACENT DUPLICATES FROM DATA_PACKAGE COMPARING DATA_Package-OrderNo
Thanks a lot!
Sri -
SQL (Select) based on Excel data
Hi
I have accounts & their status in a Excel file (like below)
Account status
1111 1
22222 11
I have like 300 rows in excel file
(sometimes Account will have only 4digits, in that case I want to append '0' in the front)
(sometimes status will have only 1/2digits, in that case I want to append '00', if its one digit and '0' if its two digit)
I want to write a select statement based on those, for example (in this case)
SELECT * FROM SUPPLIER
WHERE (Account = '01111' AND Status = '001')
OR (Account = '22222' AND Status = '011')
How do I write the select for all 300 rows(in excel) at one time? I don't want to use(create) tables. And I am using Oracle version 9
ThanksHi,
I assume this question is just about how to format the numbers, not about directly reading the Ecel file.
To use different formats in different situations, all in the same column, use CASE to to choose the appropriate format, like this:
WITH my_excel_table AS
( -- Begin test data
SELECT 1 AS n FROM dual UNION ALL
SELECT 22 FROM dual UNION ALL
SELECT 333 FROM dual UNION ALL
SELECT 4444 FROM dual UNION ALL
SELECT 55555 FROM dual UNION ALL
SELECT 666666 FROM dual UNION ALL
SELECT 7777777 FROM dual
) -- End test data, cut here
SELECT n
, TO_CHAR ( n
, 'fm'
||
CASE
WHEN n < 1000 THEN '000'
WHEN n < 100000 THEN '00000'
ELSE '9999999999'
END
) AS f
FROM my_excel_table
ORDER BY n;The code above produces:
N F
1 001
22 022
333 333
4444 04444
55555 55555
666666 666666
7777777 7777777As written, this assumes the numbers are all non-negative integers, but it can be modified.
Message was edited by:
Frank Kulash
Sorry if this confused you. I see now that it doesn't really answer your question.
You can use TO_CHAR separately on the two columns:
TO_CHAR (account, 'fm00000')
TO_CHAR (status, 'fm000')
or use LPAD, as Visu demonstrated.
Only use these things for display. In the WHERE-clause (and similar places), you can use leading zeros if you like, but do not use quotes, that is, just say "account = 1111" and "status = 1", or, if you prefer, "account = 01111" and/or "status = 001". -
Running data providers based on other data provider results in webi
Hi,
Thank you all; this is a great place to look for answers whenever you stumble in BO.
I got a specific requirement for a Webi report. The report should display the associated metrics only when the total surveyed members are greater than 25, if not, N/A.
This requirement happens to be a new add on for the already existing report; the report was built with multiple providers, in which one of the providers gives the total surveyed members.
Is there any way that we can control the rest of the data providers based on the first data provider output. I donu2019t want to run the rest of the data providersu2014 as there are too many, and each takes quite a bit of timeu2014 if the surveyed members are less than or equal to 25.
We are on XI3.1 Sp3
Thanks in advance.Thanks for the quick response!
Vills u2013 Is it query from the results functionality that you are talking about? I tried this approach, but as I am using the measure in the filter of the 2nd data provider (total members > 25),and the resulting SQL is not getting parsed.
Waveryu2014 The report filter that I tried to use is not working. Can you please give me some more details how to use it?
As I would like to leverage the existing report, which perfectly works for the total members> 25 logic, I was asked to find a way to not to run the rest of the data providers to save db resources, provided if the total mbrs participated in the survey from the first data provider <25.
Is there any way that we can embed some case statement in the other data providers to make them run or throw an error message depending on member count?
To give some more understanding, I want to provide you the screen shots of the queries, but I am unable to paste those screen shots here .
Essentially I am looking for is there any way to use one data provideru2019s output as a trigger for the rest of the data providers? -
제품 : SQL*PLUS
작성날짜 : 2004-05-20
TABLE에서 RANDOM하게 DATA를 가져오는방법
======================================
PURPOSE
아래의 내용은 Sample table scan을 통해서 table의 data를 가져올 때 마다
result set에서 Random하게 가져오는 방법을 기술하고 있습니다.
8i의 새로운 기능입니다.
Explanation
기본적으로 오라클은 data를 access할 때는
1)Full table scan
2) Sample table scan.
의 두 가지 방법이 있습니다.
1. Full Table Scan
이 방법은 table의 모든 행을 scan한 후 가져오는 방법입니다.
Full table scan을 위해서 Oracle은 table의 모든 row들을 읽고
각각의 행이 where 조건에 만족하는지는 확인합니다. Oracle은
table에 관련된 모든 block을 차례로 읽기 때문에 full table scan은
multiblock 읽기를 통해서 효율적으로 이루어 집니다.
2. Sample Table Scan
Sample table scan 은 table의 data중 무작위적으로 sample을
가져옵니다. 이러한 방법은 SQL문장의 FROM 절에 SAMPLE
option 이나 SAMPLE BLOCK option을 기술 해 줌으로써
사용되어 집니다.
SAMPLE option
Sample table scan은 row 단위로 sample data를 가져올 때
사용하는 option 입니다. (SAMPLE option),
Oracle 은 특정 비율(%)의 row를 테이블에서 읽은 후 각각의
Row가 WHERE 절의 조건에 만족하는지 확인 합니다.
SAMPLE BLOCK option
Sample table scan은 block 단위로 sample data를 가져올 때
사용하는 option 입니다. (SAMPLE BLOCK option),
Oracle 은 특정 비율(%)의 테이블 block을 읽은 후 각각의 row가
WHERE 절에 만족하는지 확인 합니다.
Sample_Percent
Sample_percent 은 전체 row 또는 sample이 포함된 block중에서
가져올 비율(%)를 지정해 줍니다. Sample value 은 반드시
0.000001 와 99.999999 사이에 존재 하여야 합니다.
Example
SQL> SELECT * FROM emp SAMPLE (30);
EMPNO ENAME JOB MGR HIREDATE SAL COMM
DEPTNO
7499 ALLEN SALESMAN 7698 20-FEB-81 1600 300
30
7654 MARTIN SALESMAN 7698 28-SEP-81 1250 1400
30
7902 FORD ANALYST 7566 03-DEC-81 3000
20
SQL> SELECT * FROM emp SAMPLE BLOCK (10);
EMPNO ENAME JOB MGR HIREDATE SAL COMM
DEPTNO
7521 WARD SALESMAN 7698 22-FEB-81 1250
500 30
7934 MILLER CLERK 7782 23-JAN-82
1300 10
제약사항
1. 하나의 테이블에서 select할 경우만 사용하실 수 있습니다.
Join이나 remote table은 지원하지 않습니다.
2. SAMPLE option은 사용하실 때, Oracle은 자동적으로 cost-based
optimizer를
사용하게 됩니다. Rule-based optimizer 은 지원되지 않습니다.
3. View는 지원하지 않습니다.
SQL> CREATE VIEW sample_view AS SELECT * FROM emp SAMPLE (30);
CREATE VIEW sample_view AS SELECT * FROM emp SAMPLE (30)
ERROR at line 1:
ORA-00933: SQL command not properly ended
4. 8.1.6 이하에서는 PL/SQL 에서 SAMPLE BLOCK을 지원하지 않습니다.
8.1.5 에서는 아래와 같은 error가 발생합니다.
SQL> ed sample.sql
DECLARE
CURSOR C1 IS
SELECT * FROM emp SAMPLE (10);
C1_rec c1%ROWTYPE;
temp number := 0;
BEGIN
OPEN C1;
WHILE temp = 1 LOOP
FETCH c1 INTO c1_rec;
IF c1%NOTFOUND THEN
temp := 0;
ELSE
DBMS_OUTPUT.PUT_LINE(TO_CHAR(c1_rec.empno));
END IF ;
end LOOP;
CLOSE c1;
END;
SQL> @sample.sql
SELECT * FROM emp SAMPLE (10);
ERROR at line 3:
ORA-06550: line 3, column 34:
PLS-00103: Encountered the symbol "(" when expecting one of the
following:
, ; for group having intersect minus order start union where
connect
The symbol "having" was substituted for "(" to continue.
5. 작은 수의 row를 가진 table에서 sample이나 sample block option을
사용 시에는 일정 비율(%)의 sample data가 return되지 않을 수도
있습니다.
Reference Documents
1. Note:95455.1
2. ORACLE 8i, SQL Reference, Volume 2, Release 8.1.5 (PartA67795-01),
Chapter 7: SQL Statements, Pages 7-542 to 7-546.
3. ORACLE 8i, Concepts, Volume 2, Release 8.1.5 (Part A67783-01),
Chapter 23: Optimizer Operations, Page 23-34. -
Use SQL to roll a schedule forward to a random date
Hi,
oracle 10.2.0.4 Linux
We have two largeish tables ( 10^5 rows in each) that track our workforces scheduled hours. The first table creates generic schedules that show working days, each schedule must have 1-n rows in it, one for each day in the cycle. The majority of our workforce are on a rolling 8 day cycle. In the example below I have two shifts
Sched_4d that is a four day cycle of day-on day-off pairs.
Sched_3d this is a staggered full day, half day, day-off cycle.
From the information below you can see that in 1990 the sched_4d went from an 8 hour day to a 9 hour day. There is no guarantee that SCHED_4D will not suddenly gain 2 extra days as part of this years union talks.
The second table is a simple assigment table showing when a person goes onto a schedule.
To work out a given day's schedule, you look at the EMP_SHIFT table to work out which schedule is "current", then you look at the date that the person was assigned to the schedule and assume that is SHIFT_ID 1, the next day is SHIFT_ID 2 until you complete the cycle and start again.
CREATE TABLE SCHED_DATA
SCHED_ID VARCHAR2(8 CHAR) NOT NULL,
ASOFDATE DATE NOT NULL,
SHIFT_ID NUMBER(3) NOT NULL,
SCHED_HRS NUMBER(4,2) NOT NULL
CREATE UNIQUE INDEX SCHED_DATA on SCHED_DATA (SCHED_ID, ASOFDATE, SHIFT_ID)
CREATE TABLE EMP_SHIFT
EMPID VARCHAR2(15 CHAR) NOT NULL,
ASOFDATE DATE NOT NULL,
SCHED_ID VARCHAR2(8 CHAR) NOT NULL
CREATE UNIQUE INDEX EMP_SHIFT on EMP_SHIFT ( EMPID, ASOFDATE, SCHED_ID)
INSERT INTO SCHED_DATA VALUES ('SCHED_4D', '01-JAN-1980',1,8);
INSERT INTO SCHED_DATA VALUES ('SCHED_4D', '01-JAN-1980',2,0);
INSERT INTO SCHED_DATA VALUES ('SCHED_4D', '01-JAN-1980',3,8);
INSERT INTO SCHED_DATA VALUES ('SCHED_4D', '01-JAN-1980',4,0);
INSERT INTO SCHED_DATA VALUES ('SCHED_4D', '01-JAN-1990',1,9);
INSERT INTO SCHED_DATA VALUES ('SCHED_4D', '01-JAN-1990',2,0);
INSERT INTO SCHED_DATA VALUES ('SCHED_4D', '01-JAN-1990',3,9);
INSERT INTO SCHED_DATA VALUES ('SCHED_4D', '01-JAN-1990',4,0);
INSERT INTO SCHED_DATA VALUES ('SCHED_3D', '01-JAN-1990',1,8);
INSERT INTO SCHED_DATA VALUES ('SCHED_3D', '01-JAN-1990',2,4);
INSERT INTO SCHED_DATA VALUES ('SCHED_3D', '01-JAN-1990',3,0);
INSERT INTO EMP_SHIFT VALUES ('001', '20-DEC-1989', 'SCHED_4D');
INSERT INTO EMP_SHIFT VALUES ('001', '01-JAN-1990', 'SCHED_4D');
INSERT INTO EMP_SHIFT VALUES ('001', '03-JAN-1990', 'SCHED_3D');
Given the above information, I need to write a select that receives 2 dates ( :FROM and :TO) and for all employees in EMP_SHIFT returns a row for each day and the relevant scheduled hours for that day.
Thus the above data with a from and to of '21-DEC-1989' : '05-JAN-1990' should return
EMPID, DATE, SCHED_HOURS
001, 21-DEC, 0
001, 22-DEC, 8
001, 23-DEC, 0
001, 24-DEC, 8
001, 25-DEC, 0
001, 26-DEC, 8
001, 27-DEC, 0
001, 28-DEC, 8
001, 29-DEC, 0
001, 30-DEC, 8
001, 31-DEC, 0
001, 01-JAN, 9
001, 02-JAN, 0
001, 03-JAN, 8
001, 04-JAN, 4
001, 05-JAN, 0
The employee started thir assignment to sched_4d on 20-DEC, so that would be SHIFT_ID 1. Thus 21-DEC is SHIFT ID 2 which is 0 hours. Cycle until the next event which is 01-JAN, when they are assigned to the new sched_4d which has them working 9 hours on day 1. On 03-JAN they switch to the new cycle and go on the 8:4:0 rotation.
I can see how I could
SELECT EMPID, DAY_OF_INTEREST, SCHED_ID
FROM EMP_SHIFT A, (SELECT '01-JAN-1979' + rownum "DAY_OF_INTEREST" from dual connect by level <=10000)
WHERE A.ASOFDATE = (SELECT MAX(A1.ASOFDATE) FROM EMP_SHIFT A1 WHERE A1.EMPID = A.EMPID AND A1.ASOFDATE <= DAY_OF_INTEREST)
AND DAY_OF_INTEREST BETWEEN :FROM_DT AND :TO_DT
And I imagine I need to use some kind of MOD( (DAY_OF_INTEREST - EMP_SHIFT.ASOFDATE), (#number of days in shift) ) to work out which shift_id applies for a given Day_of_interest
But I am struggling to do this in a way that would scale to more than one employee,
Do any of the analytic functions achieve this in a neat way ?Hi,
There are several analytic functions that might help here. Both tables include starting dates only; we need to know ending dates for employee assignments as well as for schedules. I used the analytic MIN and LEAD functions to get these in the query below. Also, the query below needs to know how many days are in each schedule. I used the analytic COUNT function for that.
WITH params AS
SELECT TO_DATE ('21-DEC-1989', 'DD_MON-YYYY') AS start_date
, TO_DATE ('05-JAN-1990', 'DD_MON-YYYY') AS end_date
FROM dual
, all_dates AS
SELECT start_date + LEVEL - 1 AS a_date
FROM params
CONNECT BY LEVEL <= (end_date + 1) - start_date
, sched_data_plus AS
SELECT sched_id, asofdate, shift_id, sched_hrs
, NVL ( MIN (asofdate) OVER ( PARTITION BY sched_id
ORDER BY asofdate
RANGE BETWEEN 1 FOLLOWING
AND UNBOUNDED FOLLOWING
) - 1
, TO_DATE ('31-DEC-9999', 'DD-MON-YYYY')
) AS uptodate
, COUNT (*) OVER ( PARTITION BY sched_id
, asofdate
) AS days_in_sched
FROM sched_data
, emp_shift_plus AS
SELECT empid, asofdate, sched_id
, NVL ( LEAD (asofdate) OVER ( PARTITION BY empid
ORDER BY asofdate
) - 1
, TO_DATE ('31-DEC-9999', 'DD-MON-YYYY')
) AS uptodate
FROM emp_shift
SELECT e.empid
, d.a_date
, s.sched_hrs
FROM all_dates d
JOIN sched_data_plus s ON d.a_date BETWEEN s.asofdate
AND s.uptodate
JOIN emp_shift_plus e ON d.a_date BETWEEN e.asofdate
AND e.uptodate
AND e.sched_id = s.sched_id
AND MOD ( d.a_date - e.asofdate
, s.days_in_sched
) + 1 = s.shift_id
ORDER BY e.empid
, d.a_date
This query starts by getting all the days of interest, that is, all the days between the given start- and end dates. (When you said "random date", I assume you meant "given date", which may not involve any random element.)
Once we have a list of all the dates of interest, getting the results you want is just a matter of inner-joining to get which schedules were in effect on those dates, and which employees were assigned to those schedules on those dates.
If you're concerned about having more than 1 employee, maybe you should post sample data that involves more than 1 employee.
How do you handle employee terminations? For example, what if employee 001 had quit on January 4, 1990? I assume you'd want the output for that employee to stop on January 4, rather than continue to the end of the period of interest.
If you have termination dates in an employee table not shown here, then you can use that termination date instead of December 31, 9999 as the default end date for assignments. If you have a special schedule for terminations (or leaves of absence, for that matter) you'll probably want to include a WHERE clause in the main query not to display dates after the employee left (or while the employee was on leave). -
How do you generate random data info using json and spry?
I have a mobile applicaton that uses spry datasets that dynamically populate a jquery mobile listview by using a json file. Everything is operating as it should.
However, I would like to understand how to pull random objects from the json file to have them displayed on a different page.
My json file is standard and not complicated. It has several levels. Each is represented as below:
{ "Level1":
{"imageurl":"images/_myimage.png",
"someData":"S,A,P,R",
"levelLongDesc":"further description",
"name": "John Doe",
"page": "referencepage",
"description":"The description of the image"
{"imageurl":"images/_myimage.png",
"someData":"S,A,P,R",
"levelLongDesc":"further description",
"name": "John Doe",
"page": "referencepage",
"description":"The description of the image"
Json file Level1 has about 70 objects
What I would like to do is randomly load one of the Level1 object arrays into the page when the user selects a Level 1 radio button that is on the screen. I know how to create the page, radio buttons and basics, but just don't know how to pull in the random data.
I've found one code sample on this site that speaks to spry and xml, but I haven't been able to apply it in any way that works for me with the json file:
http://forums.adobe.com/message/662551
I've also googled. There isn't much on spry datasets with json and generating random info. There was a little bit on sorting, but that didn't help either.
Does anyone have a good example/tutorial of how to use the random function with spry/json?
TIA
-RachelI've done similar things before. A few thoughts for you:
1. I'm assuming you're doing a buffered period or frequency measurement on the incoming encoder pulses, right? First key point is that you'll have data that is spaced equally in position, but not equally in time. If you are looking for a time-based FFT such that increasing speed will shift your spectrum, you're going to need to go through an interpolation process to resample your data as though equally-spaced in in time.
2. Your 149 pulse per rev encoder may be a significant source of error unless its 149 pulses are placed with extreme accuracy. Any error in pulse placement violates your underlying assumption of data that is equally-spaced in position. It'll be very helpful to send your data through a software lowpass filter to attenuate those artifacts.
3. I am not sure what you mean by "decompose the buffered data (array) into a single datastream." You'll get an array of periods / frequencies from the call to DAQmx Read. If you want to use it in a LabVIEW waveform datatype, you'll first need to do the resampling to create equally-spaced-in-time data. The LabVIEW waveform datatype (and all the analysis functions like FFT that use it) depend on receiving data with a fixed constant time interval between samples.
-Kevin P. -
Infopackage-Data Selection Tab Values Get Populated Automatically.
Hi All,
In infopackage dataselection tab currently we are entering manually values for 0version info object and process has to be done for 4 differenct infopackagewe are getting a ticket for doing this process for every month.So 0version values would not be unique values ,all the values are different,for instancec10,c99,c11.
user community felt that this one is a time consuming take they want to customize it and they want to enter the value on their own thorug some custom sap screen.
we cannot give access to the user for the infopackage selection and all .we have figured out like we have to create a custom t code and give acces to the user for that t code alone.
If the user enter the 0version value in the front end of it should get reflected in infopackage dataselection tab.
It would be really grateful if u have shared ur thought on the same.
Regards,
Sakthivel SHi,
You could use the TVARVC table instead of creating a Z-control table, and allow the users to enter the data into TVARVC via the tcode you are creating.
So for instance the table entries could be as follows.
NAME
SIGN
OPT
LOW
HIGH
IP_1
I
EQ
V1
IP_2
I
BT
V3
V4
IP_3
I
EQ
V9
Now, in the first InfoPackage, write the ABAP routine to read the data from TVARVC where the NAME = IP_1. Based on the results the InfoPackage restrictions will be populated by the routine.
In the second InfoPackage you read based on NAME = IP_2. And so on. Rest of the routine code is same as in the first InfoPackage.
This way you can be assured that the different IPAKs will not have overlapping criteria as long as the table entries are correctly maintained.
Regards,
Suhas -
Infopackage "Data Selection" Criteria
Hello,
This is a really simple question.
I want to break out an INIT infopackage from 1 big load to several smaller loads.
To do this I am going to create multiple INIT infopackages that have selections based upon Fiscal Year, and each infopackage will also include a selection for 0VTYPE of 010.
The result will be 4 infopackages that have the following selections for Fiscal year/0VTYPE
1. The beginning of time to 2001 010
2. 2002 010
3. 2003 010
4. 2004 to the end of time 010
When I create the infopackages under the 'data selection' tab I see "From Value" and "To Value"
For each infopackage what values should I enter, so that I get the 4 correct infopackages as described above ( I am most concerned about structuring #1 and #4 correctly)?
Thanks,
NickHello Andres,
I am still testing but things seem to be working well.
What i did was setup an Delta INIT infopackage for Periods 007/2008 - 012/9999
Then I built Full (repair) loads for 6 period intervals beneath the INIT. For example:
001/2008 - 006/2008
007/2007 - 012/2007
001/2007 - 006/2007
It works nicely to break the load up from 1 gigantic to many smaller loads. I put all these packages together in a process chain.
I also found that the load was not slowing down becuase of it being a huge load, it was actually because of the Update rule processing.
I like the smaller loads in the process chain better then 1 huge load, it is easier to manage.
I have also addressed the update rule processing issue, so things (will be) operating much better going forward.
Thanks for the help!
Nick -
Date Picker based on transient field
Hi,
JDev 10.1.3, ADF, BC4J:
I have a jsp with two date fields that I use for searching. I have created a form bean that stores these fields as java.sql.Date types, and also generated a data control from this form bean.
The problem is, I want to display these fields as date pickers in my browser.
If I have a data-bound date field I can just drag it on to the page and select to drop it as type "Input render". This will create the date picker for me.
However, if I do the same thing with my non-data-bound dates, they do not appear on the resulting page.
Is there a way of creating date pickers based on transient (non-data-bound) fields?
Cheers,
Alex.Field validation assumes that the field being validated is to the left of the operator in the syntax. Since your validation requirement is complex, you would use the IIf statement.
This is the syntax you should use for the Status field:
=IIf((FieldValue('<Status>') = 'Commit' AND [<ClosedDate>] > Today() + 90) OR (FieldValue('<Status>') <> 'Commit'),[<Status>],"Invalid")
You would build the syntax for Closed Date similarly. You would want to place this on all the affected fields to ensure it is called at the appropriate time. You should also test that it runs as expected when you edit other fields as well. This is another thread that talks about this issue: Re: Contact Field Validation (Email, Work Phone #, Mobile Phone #)
Good Luck,
Thom -
OBIEE Report - filter based on the result from another analysis
Hi,
I am using OBIEE 11g,
I am trying to use a filter which is based on the result from another analysis. I have an analysis A which is as table 1, and I want to filter the respective columns of analysis B (Table B) based on analysis A to remove the duplicates for march 01, 02, and 07 , but it is not working properly. I took a max of start and end time when I created analysis A. Please let me know if I did anything wrong. thanks.
Table 1
Employee Number
Date
IN
Out
Start Time
End Time
xxxxxxx
2015-02-26
9:00
13:00
00:00:00
00:00:00
2015-02-27
12:00
18:00
00:00:00
00:00:00
2015-02-28
8:00
14:00
00:00:00
00:00:00
2015-03-01
14:00
20:00
14:00:00
20:00:00
2015-03-02
16:00
20:00
16:00:00
20:00:00
2015-03-07
14:06
20:02
14:00:00
20:00:00
2015-03-11
16:00
20:00
16:00:00
20:00:00
2015-03-14
8:00
14:00
00:00:00
00:00:00
2015-03-25
14:00
20:00
16:00:00
20:00:00
Table 2
Employee Number
Date
IN
Out
Start Time
End Time
Hours
xxxxxxx
2015-02-26
9:00
13:00
00:00:00
00:00:00
-3
2015-02-27
12:00
18:00
00:00:00
00:00:00
6
2015-02-28
8:00
14:00
00:00:00
00:00:00
6
2015-03-01
14:00
20:00
00:00:00
00:00:00
6
14:00:00
20:00:00
6
2015-03-02
16:00
20:00
00:00:00
00:00:00
4
16:00:00
20:00:00
4
2015-03-07
14:06
20:02
00:00:00
00:00:00
6
14:00:00
20:00:00
6
2015-03-11
16:00
20:00
16:00:00
20:00:00
4
2015-03-14
8:00
14:00
00:00:00
00:00:00
6
2015-03-25
14:00
20:00
16:00:00
20:00:00
4Why avg here?
What columns you want to show in the report?
for a employee for given date if he have 2 rows then you may sum up hours right?
Employee Number
Date
IN
Out
Start Time
End Time
Hours -
How to creat a Data provider based on different fields in SAP BW ?
Hi,
Experts,
There are 20 fields of Plant Maintainace like :
SWERK
BEBER
STORT
TPLNR
EQUNR
INGRP
QMDAT ---peroid
STTXT
QMDAT - Date of Notification
QMNUM
QMTXT
QMART
AUSVN
AUZTV
AUSBS
AUZTB
AUSZT
ERNAM
QMDAB
AUFNR
I want to creat a Report based upon these fields ?
For that I h'v checked the relevant Fields to the existing standard Datasource in Bw side &
Checked cubes created based upon these Datasource in Bw side !
i h'v found some fields are existing different cubes & some are missing .
How to creat a Data provider based on different fields in SAP BW ?
plz suggest !!!!!!!
Thanx,
Asit
Edited by: ASIT_SAP on Jul 15, 2011 6:25 AM
Edited by: ASIT_SAP on Jul 15, 2011 6:27 AM
Edited by: ASIT_SAP on Jul 15, 2011 12:37 PMHi Lee, Please see below..
DECLARE @Machine2 TABLE
DispatchDate DATE
INSERT INTO @Machine2 VALUES ('2014/02/01'), ('2014/02/02'), ('2014/02/03')
DECLARE @DateFrom DATE
SELECT @DateFrom = DATEADD(D,1,MAX(DispatchDate)) FROM @Machine2
SELECT @DateFrom AS DateFrom
Please mark as answer, if this has helped you solve the issue.
Good Luck :) .. visit www.sqlsaga.com for more t-sql code snippets and BI related how to articles. -
Sort all the Records in Data manager based on Update Date
How to sort the reocrds in Data Manager based on Date or something ?
And also I have three records for a same customer in ( for three different company codes ) and when I search for this customer with the Customer number then it is showing three records , but when I search with Update Date then no records are fetched ...what is the reason ?If you make a field as type "Time Stamp" in your data model using the MDM Console, make sure that the option Sort Index is set to Normal. If this is the case, whenever a record is updated in the repository, the date will be updated. If the sort index is normal, then MDM will allow you to sort the records based on the date and time by which they were updated. You can do this by finding your time stamp field in the MDM data manager and clicking on it. If there is an up and down arrow next to the name of your field, it means it can be sorted. Also, to answer your other question, you can definitely search based on date. Use the Free-Form Search on the left hand side of the data manager at the bottom of the screen. Simply select a date, and it will show you all the records updated on that date.
-
Error in Data selection in R/3 Generic Extraction Using function Modules
Hi Friends,
I have created a a generic data source using function module to load data from PA0000 and PA0001 Tables ,Function module is working fine when i execute it indipendently and the data source is also working fine when i extract data using RSA3. it is showing correct no of records 157.
When loading data into DSO from BW (using 3.x/7.0 flows) data is comming to PSA all 157 records but in the RSMO the load status is showing yellow when i look into the step by step analysis it is
data selection successfully started
Data selection successfully ended
All Data packets completed.
are showing in red.
after and hour time load getting failed and in the error message it is showing " job terminated in source system---> Request set to red"
it is giving this message wir no RSM 78.
Please let me know itHi Jerry,
Thanks for the immediate replay
But here in my source system job is getting terminated.
this is the status of job in Job logs.
the job is running till this step not going ahead.
Call customer enhancement BW_BTE_CALL_BW204010_E (BTE) with 157 records
Result of customer enhancement: 157 records
Call customer enhancement EXIT_SAPLRSAP_001 (CMOD) with 301 records
Result of customer enhancement: 157 records
Asynchronous send of data package 000001 in task 0002 (1 parallel tasks)
pl. update me if any idea.
Maybe you are looking for
-
How do I sync my Iphone with my MacBook Pro with a reformatted hard drive?
My MacBook Pro hard drive crashed. I rebooted from the Mac OS X install DVD. Now, my itunes is empty. When I tried to sync my iPhone 4, it states that it will erase everything on my phone and replace it with the items in itunes (which is empty). What
-
High CPU consumption with repaint while dragging
Hi! I certainly hope someone can help me with this. I am building a graphical user interface for a graph with custom nodes and edges, the nodes being draggable. I have tried making each network component (node or edge) a JComponent. Now, I'm trying u
-
How to Create Pop-up in ActionScript 3.0
Hi, Suppose, we have an object on the stage(say Rectangle/Circle, Movieclip, Button,etc.,). When we click on this object using mouse, Then it should display some information in a pop-up(say Click event occured on specific object being clicked(viz., R
-
HBA / Part Number for 3100 array connect to Sun 420 R
Hi I need to connect the 420R server to 3100 array. What type of HBA is needed and part number if anybody has. Thanks Srini
-
Using volume keys to see messages on external display on 8220
for some reason, this function sometimes work and sometimes doesn't work on my phone. I think I have the right settings as it sometimes work. anyone know what the issue is? thanks Solved! Go to Solution.