Query Solve

SELECT
TO_CHAR(TRUNC(MTRH.DATE_REQUIRED),'MON-YYYY')DATE_REQUIRED,
COUNT(DISTINCT WT.TRIP_ID)NO_OF_TRIPS_CREATED,
0 NO_OF_TRIPS_DISPATCHED,
OETL.ATTRIBUTE1 DOM_EXP,
OETL.ATTRIBUTE2 REGION,
OETL.ATTRIBUTE3 CURR
FROM OE_ORDER_HEADERS_ALL OEHA ,
OE_ORDER_LINES_ALL OELA ,
WSH_DELIVERY_DETAILS WDD,
WSH_DELIVERY_ASSIGNMENTS WDA ,
WSH_NEW_DELIVERIES WND ,
WSH_DELIVERY_LEGS WDL ,
WSH_TRIP_STOPS WTS ,
WSH_TRIPS WT,
MTL_TXN_REQUEST_LINES MTRL ,
MTL_TXN_REQUEST_HEADERS MTRH ,
MTL_TRANSACTION_TYPES MTT ,
MTL_SYSTEM_ITEMS_B MSIB,
MTL_ITEM_CATEGORIES MIC ,
MTL_CATEGORIES_B MCB,
OE_TRANSACTION_TYPES_ALL OETL
WHERE OEHA.HEADER_ID = OELA.HEADER_ID
AND OEHA.HEADER_ID = WDD.SOURCE_HEADER_ID
AND OELA.LINE_ID = WDD.SOURCE_LINE_ID
AND WDD.DELIVERY_DETAIL_ID = WDA.DELIVERY_DETAIL_ID
AND WND.DELIVERY_ID = WDA.DELIVERY_ID
AND WDL.DELIVERY_ID = WND.DELIVERY_ID
AND WTS.STOP_ID = WDL.PICK_UP_STOP_ID
AND WT.TRIP_ID = WTS.TRIP_ID
AND MTRL.LINE_ID = WDD.MOVE_ORDER_LINE_ID
AND MTRL.HEADER_ID = MTRH.HEADER_ID
AND MTT.TRANSACTION_TYPE_ID = MTRL.TRANSACTION_TYPE_ID
AND MSIB.INVENTORY_ITEM_ID = MTRL.INVENTORY_ITEM_ID
AND MIC.INVENTORY_ITEM_ID = MTRL.INVENTORY_ITEM_ID
AND MCB.CATEGORY_ID = MIC.CATEGORY_ID
AND OETL.TRANSACTION_TYPE_ID = OEHA.ORDER_TYPE_ID
AND WDD.RELEASED_STATUS IN (SELECT LOOKUP_CODE FROM wsh_lookups WHERE LOOKUP_TYPE = 'PICK_STATUS' AND MEANING <> 'Shipped')
AND TO_CHAR(MTRH.MOVE_ORDER_TYPE) IN (SELECT LOOKUP_CODE FROM MFG_LOOKUPS
WHERE LOOKUP_TYPE = 'MOVE_ORDER_TYPE' AND MEANING = 'Pick Wave')
AND MSIB.ORGANIZATION_ID = 327
AND MIC.ORGANIZATION_ID = 327
AND OETL.TRANSACTION_TYPE_CODE = 'ORDER'
AND MTT.TRANSACTION_TYPE_NAME = 'Sales Order Pick'
AND MIC.CATEGORY_SET_ID IN (SELECT CATEGORY_SET_ID FROM MTL_CATEGORY_SETS_TL WHERE CATEGORY_SET_NAME LIKE
'IIL-Inventory')
--AND TRUNC(MTRH.DATE_REQUIRED) BETWEEN TO_DATE(:P_MONTH_FROM,'MON-YYYY') AND
--LAST_DAY(TO_DATE(:P_MONTH_TO,'MON-YYYY'))
AND TRUNC(MTRH.DATE_REQUIRED) BETWEEN :P_MONTH_FROM AND
:P_MONTH_TO
--AND DECODE(UPPER(WDD.SOURCE_HEADER_TYPE_NAME),'PROFORMA','TRANSFER','SALES') =  NVL(:P_SOURCE_NAME,
-- DECODE(UPPER(WDD.SOURCE_HEADER_TYPE_NAME),'PROFORMA','TRANSFER','SALES'))
AND UPPER(OETL.ATTRIBUTE1) = NVL(:P_DOM_EXP,UPPER(OETL.ATTRIBUTE1))
AND UPPER(OETL.ATTRIBUTE2) = NVL(:P_REGION, UPPER(OETL.ATTRIBUTE2))
AND DECODE(:P_CURR , NULL , 'ALL' , :P_CURR)= DECODE(:P_CURR , NULL , 'ALL' , UPPER(OETL.ATTRIBUTE3))
GROUP BY
TO_CHAR(TRUNC(MTRH.DATE_REQUIRED),'MON-YYYY'),
OETL.ATTRIBUTE1,
OETL.ATTRIBUTE2,
OETL.ATTRIBUTE3
UNION
SELECT
TO_CHAR(TRUNC(WDD.EARLIEST_PICKUP_DATE),'MON-YYYY')DATE_DISPATCHED,
0,
COUNT(DISTINCT WT.TRIP_ID)NO_OF_TRIPS_DISPATCHED,
OETL.ATTRIBUTE1,
OETL.ATTRIBUTE2,
OETL.ATTRIBUTE3
FROM OE_ORDER_HEADERS_ALL OEHA ,
OE_ORDER_LINES_ALL OELA ,
WSH_DELIVERY_DETAILS WDD,
WSH_DELIVERY_ASSIGNMENTS WDA ,
WSH_NEW_DELIVERIES WND ,
WSH_DELIVERY_LEGS WDL ,
WSH_TRIP_STOPS WTS ,
WSH_TRIPS WT,
MTL_SYSTEM_ITEMS_B MSIB,
MTL_ITEM_CATEGORIES MIC ,
MTL_CATEGORIES_B MCB,
OE_TRANSACTION_TYPES_ALL OETL
WHERE
OEHA.HEADER_ID = OELA.HEADER_ID
AND OEHA.HEADER_ID = WDD.SOURCE_HEADER_ID
AND OELA.LINE_ID = WDD.SOURCE_LINE_ID
AND WDD.DELIVERY_DETAIL_ID = WDA.DELIVERY_DETAIL_ID
AND WND.DELIVERY_ID = WDA.DELIVERY_ID
AND WDL.DELIVERY_ID = WND.DELIVERY_ID
AND WTS.STOP_ID = WDL.PICK_UP_STOP_ID
AND WT.TRIP_ID = WTS.TRIP_ID
AND MSIB.INVENTORY_ITEM_ID = WDD.INVENTORY_ITEM_ID
AND MIC.INVENTORY_ITEM_ID = WDD.INVENTORY_ITEM_ID
AND MCB.CATEGORY_ID = MIC.CATEGORY_ID
AND OETL.TRANSACTION_TYPE_ID = OEHA.ORDER_TYPE_ID
AND WDD.RELEASED_STATUS IN (SELECT LOOKUP_CODE FROM wsh_lookups WHERE LOOKUP_TYPE = 'PICK_STATUS' AND MEANING = 'Shipped')
AND MSIB.ORGANIZATION_ID = 327
AND MIC.ORGANIZATION_ID = 327
AND MIC.CATEGORY_SET_ID IN (SELECT CATEGORY_SET_ID FROM MTL_CATEGORY_SETS_TL WHERE CATEGORY_SET_NAME LIKE
'IIL-Inventory')
--AND TRUNC(WDD.EARLIEST_PICKUP_DATE) BETWEEN TO_DATE(:P_MONTH_FROM,'MON-YYYY') AND
--LAST_DAY(TO_DATE(:P_MONTH_TO,'MON-YYYY'))
AND TRUNC(WDD.EARLIEST_PICKUP_DATE) BETWEEN :P_MONTH_FROM AND
:P_MONTH_TO
--AND DECODE(UPPER(WDD.SOURCE_HEADER_TYPE_NAME),'PROFORMA','TRANSFER','SALES') =  NVL(:P_SOURCE_NAME,
--DECODE(UPPER(WDD.SOURCE_HEADER_TYPE_NAME),'PROFORMA','TRANSFER','SALES'))
AND UPPER(OETL.ATTRIBUTE2) NOT IN ('INTERNAL')
AND UPPER(OETL.ATTRIBUTE1) = NVL(:P_DOM_EXP,UPPER(OETL.ATTRIBUTE1))
AND UPPER(OETL.ATTRIBUTE2) = NVL(:P_REGION,UPPER(OETL.ATTRIBUTE2))
AND DECODE(:P_CURR , NULL , 'ALL' , :P_CURR)= DECODE(:P_CURR , NULL , 'ALL' , UPPER(OETL.ATTRIBUTE3))
/*AND UPPER(OETL.ATTRIBUTE3) =
(CASE
WHEN UPPER(:P_REGION) IS NULL THEN NVL(:P_CURR , UPPER(OETL.ATTRIBUTE3))
WHEN UPPER(:P_REGION) = 'NORTH' THEN :P_CURR
ELSE NVL(:P_CURR , UPPER(OETL.ATTRIBUTE3))
--WHEN UPPER(OETL.ATTRIBUTE2) IS NULL THEN NVL(:P_CURR , UPPER(OETL.ATTRIBUTE3))
END)*/
--DECODE (UPPER(OETL.ATTRIBUTE2),'NORTH',:P_CURR, NVL(:P_CURR, UPPER(OETL.ATTRIBUTE3)))
GROUP BY
TO_CHAR(TRUNC(WDD.EARLIEST_PICKUP_DATE),'MON-YYYY'),
OETL.ATTRIBUTE1,
OETL.ATTRIBUTE2,
OETL.ATTRIBUTE3
the problem is dat
the output look like this
DATE_REQUIRED     NO_OF_TRIPS_CREATED     NO_OF_TRIPS_DISPATCHED     DOM_EXP     REGION     CURR
AUG-2009     0     28     Export     Exp-SL     
AUG-2009     0     33     Export     Exp-Others     
AUG-2009     0     65     Export     Exp-AFG     
AUG-2009     0     189     Domestic     North     SN
AUG-2009     0     376     Domestic     South     SS
AUG-2009     0     784     Domestic     North     LSN
AUG-2009     1     0     Domestic     North     SN
JUL-2009     0     9     Export     Exp-Others     
JUL-2009     0     34     Export     Exp-SL     
JUL-2009     0     75     Export     Exp-AFG     
JUL-2009     0     323     Domestic     South     SS
JUL-2009     0     325     Domestic     North     SN
JUL-2009     0     1162     Domestic     North     LSN
SEP-2009     0     8     Export     Exp-Others     
SEP-2009     0     61     Export     Exp-AFG     
SEP-2009     0     61     Export     Exp-SL     
SEP-2009     0     167     Domestic     North     SN
SEP-2009     0     248     Domestic     South     SS
SEP-2009     0     666     Domestic     North     LSN
SEP-2009     1     0     Domestic     North     SN
SEP-2009     1     0     Domestic     South     SS
the major problem is the BOLD lines are same i want to create into just one line like this
AUG-2009       1     189     Domestic     North     SN
plzz help

try something like this.
select date_required,max(no_of_trips_created),max(no_of_trips_dispatched), dom_exp,region,curr
from (
SELECT
TO_CHAR(TRUNC(MTRH.DATE_REQUIRED),'MON-YYYY')DATE_REQUIRED,
COUNT(DISTINCT WT.TRIP_ID)NO_OF_TRIPS_CREATED,
0 NO_OF_TRIPS_DISPATCHED,
OETL.ATTRIBUTE1 DOM_EXP,
OETL.ATTRIBUTE2 REGION,
OETL.ATTRIBUTE3 CURR
FROM OE_ORDER_HEADERS_ALL OEHA ,
OE_ORDER_LINES_ALL OELA ,
WSH_DELIVERY_DETAILS WDD,
WSH_DELIVERY_ASSIGNMENTS WDA ,
WSH_NEW_DELIVERIES WND ,
WSH_DELIVERY_LEGS WDL ,
WSH_TRIP_STOPS WTS ,
WSH_TRIPS WT,
MTL_TXN_REQUEST_LINES MTRL ,
MTL_TXN_REQUEST_HEADERS MTRH ,
MTL_TRANSACTION_TYPES MTT ,
MTL_SYSTEM_ITEMS_B MSIB,
MTL_ITEM_CATEGORIES MIC ,
MTL_CATEGORIES_B MCB,
OE_TRANSACTION_TYPES_ALL OETL
WHERE OEHA.HEADER_ID = OELA.HEADER_ID
AND OEHA.HEADER_ID = WDD.SOURCE_HEADER_ID
AND OELA.LINE_ID = WDD.SOURCE_LINE_ID
AND WDD.DELIVERY_DETAIL_ID = WDA.DELIVERY_DETAIL_ID
AND WND.DELIVERY_ID = WDA.DELIVERY_ID
AND WDL.DELIVERY_ID = WND.DELIVERY_ID
AND WTS.STOP_ID = WDL.PICK_UP_STOP_ID
AND WT.TRIP_ID = WTS.TRIP_ID
AND MTRL.LINE_ID = WDD.MOVE_ORDER_LINE_ID
AND MTRL.HEADER_ID = MTRH.HEADER_ID
AND MTT.TRANSACTION_TYPE_ID = MTRL.TRANSACTION_TYPE_ID
AND MSIB.INVENTORY_ITEM_ID = MTRL.INVENTORY_ITEM_ID
AND MIC.INVENTORY_ITEM_ID = MTRL.INVENTORY_ITEM_ID
AND MCB.CATEGORY_ID = MIC.CATEGORY_ID
AND OETL.TRANSACTION_TYPE_ID = OEHA.ORDER_TYPE_ID
AND WDD.RELEASED_STATUS IN (SELECT LOOKUP_CODE FROM wsh_lookups WHERE LOOKUP_TYPE = 'PICK_STATUS' AND MEANING 'Shipped')
AND TO_CHAR(MTRH.MOVE_ORDER_TYPE) IN (SELECT LOOKUP_CODE FROM MFG_LOOKUPS
WHERE LOOKUP_TYPE = 'MOVE_ORDER_TYPE' AND MEANING = 'Pick Wave')
AND MSIB.ORGANIZATION_ID = 327
AND MIC.ORGANIZATION_ID = 327
AND OETL.TRANSACTION_TYPE_CODE = 'ORDER'
AND MTT.TRANSACTION_TYPE_NAME = 'Sales Order Pick'
AND MIC.CATEGORY_SET_ID IN (SELECT CATEGORY_SET_ID FROM MTL_CATEGORY_SETS_TL WHERE CATEGORY_SET_NAME LIKE
'IIL-Inventory')
--AND TRUNC(MTRH.DATE_REQUIRED) BETWEEN TO_DATE(:P_MONTH_FROM,'MON-YYYY') AND
--LAST_DAY(TO_DATE(:P_MONTH_TO,'MON-YYYY'))
AND TRUNC(MTRH.DATE_REQUIRED) BETWEEN :P_MONTH_FROM AND
:P_MONTH_TO
--AND DECODE(UPPER(WDD.SOURCE_HEADER_TYPE_NAME),'PROFORMA','TRANSFER','SALES') = NVL(:P_SOURCE_NAME,
-- DECODE(UPPER(WDD.SOURCE_HEADER_TYPE_NAME),'PROFORMA','TRANSFER','SALES'))
AND UPPER(OETL.ATTRIBUTE1) = NVL(:P_DOM_EXP,UPPER(OETL.ATTRIBUTE1))
AND UPPER(OETL.ATTRIBUTE2) = NVL(:P_REGION, UPPER(OETL.ATTRIBUTE2))
AND DECODE(:P_CURR , NULL , 'ALL' , :P_CURR)= DECODE(:P_CURR , NULL , 'ALL' , UPPER(OETL.ATTRIBUTE3))
GROUP BY
TO_CHAR(TRUNC(MTRH.DATE_REQUIRED),'MON-YYYY'),
OETL.ATTRIBUTE1,
OETL.ATTRIBUTE2,
OETL.ATTRIBUTE3
UNION
SELECT
TO_CHAR(TRUNC(WDD.EARLIEST_PICKUP_DATE),'MON-YYYY')DATE_DISPATCHED,
0,
COUNT(DISTINCT WT.TRIP_ID)NO_OF_TRIPS_DISPATCHED,
OETL.ATTRIBUTE1,
OETL.ATTRIBUTE2,
OETL.ATTRIBUTE3
FROM OE_ORDER_HEADERS_ALL OEHA ,
OE_ORDER_LINES_ALL OELA ,
WSH_DELIVERY_DETAILS WDD,
WSH_DELIVERY_ASSIGNMENTS WDA ,
WSH_NEW_DELIVERIES WND ,
WSH_DELIVERY_LEGS WDL ,
WSH_TRIP_STOPS WTS ,
WSH_TRIPS WT,
MTL_SYSTEM_ITEMS_B MSIB,
MTL_ITEM_CATEGORIES MIC ,
MTL_CATEGORIES_B MCB,
OE_TRANSACTION_TYPES_ALL OETL
WHERE
OEHA.HEADER_ID = OELA.HEADER_ID
AND OEHA.HEADER_ID = WDD.SOURCE_HEADER_ID
AND OELA.LINE_ID = WDD.SOURCE_LINE_ID
AND WDD.DELIVERY_DETAIL_ID = WDA.DELIVERY_DETAIL_ID
AND WND.DELIVERY_ID = WDA.DELIVERY_ID
AND WDL.DELIVERY_ID = WND.DELIVERY_ID
AND WTS.STOP_ID = WDL.PICK_UP_STOP_ID
AND WT.TRIP_ID = WTS.TRIP_ID
AND MSIB.INVENTORY_ITEM_ID = WDD.INVENTORY_ITEM_ID
AND MIC.INVENTORY_ITEM_ID = WDD.INVENTORY_ITEM_ID
AND MCB.CATEGORY_ID = MIC.CATEGORY_ID
AND OETL.TRANSACTION_TYPE_ID = OEHA.ORDER_TYPE_ID
AND WDD.RELEASED_STATUS IN (SELECT LOOKUP_CODE FROM wsh_lookups WHERE LOOKUP_TYPE = 'PICK_STATUS' AND MEANING = 'Shipped')
AND MSIB.ORGANIZATION_ID = 327
AND MIC.ORGANIZATION_ID = 327
AND MIC.CATEGORY_SET_ID IN (SELECT CATEGORY_SET_ID FROM MTL_CATEGORY_SETS_TL WHERE CATEGORY_SET_NAME LIKE
'IIL-Inventory')
--AND TRUNC(WDD.EARLIEST_PICKUP_DATE) BETWEEN TO_DATE(:P_MONTH_FROM,'MON-YYYY') AND
--LAST_DAY(TO_DATE(:P_MONTH_TO,'MON-YYYY'))
AND TRUNC(WDD.EARLIEST_PICKUP_DATE) BETWEEN :P_MONTH_FROM AND
:P_MONTH_TO
--AND DECODE(UPPER(WDD.SOURCE_HEADER_TYPE_NAME),'PROFORMA','TRANSFER','SALES') = NVL(:P_SOURCE_NAME,
--DECODE(UPPER(WDD.SOURCE_HEADER_TYPE_NAME),'PROFORMA','TRANSFER','SALES'))
AND UPPER(OETL.ATTRIBUTE2) NOT IN ('INTERNAL')
AND UPPER(OETL.ATTRIBUTE1) = NVL(:P_DOM_EXP,UPPER(OETL.ATTRIBUTE1))
AND UPPER(OETL.ATTRIBUTE2) = NVL(:P_REGION,UPPER(OETL.ATTRIBUTE2))
AND DECODE(:P_CURR , NULL , 'ALL' , :P_CURR)= DECODE(:P_CURR , NULL , 'ALL' , UPPER(OETL.ATTRIBUTE3))
/*AND UPPER(OETL.ATTRIBUTE3) =
(CASE
WHEN UPPER(:P_REGION) IS NULL THEN NVL(:P_CURR , UPPER(OETL.ATTRIBUTE3))
WHEN UPPER(:P_REGION) = 'NORTH' THEN :P_CURR
ELSE NVL(:P_CURR , UPPER(OETL.ATTRIBUTE3))
--WHEN UPPER(OETL.ATTRIBUTE2) IS NULL THEN NVL(:P_CURR , UPPER(OETL.ATTRIBUTE3))
END)*/
--DECODE (UPPER(OETL.ATTRIBUTE2),'NORTH',:P_CURR, NVL(:P_CURR, UPPER(OETL.ATTRIBUTE3)))
GROUP BY
TO_CHAR(TRUNC(WDD.EARLIEST_PICKUP_DATE),'MON-YYYY'),
OETL.ATTRIBUTE1,
OETL.ATTRIBUTE2,
OETL.ATTRIBUTE3)
group by date_required,dom_exp,region,curr

Similar Messages

  • Thank you Allan Sampson, your answer to another person's query solved my dilemma :-)

    Thank you Allan Sampson, your answer to another person's query solved my dilemma :-)

    i am also have the same thing how can i get they out from my game center ?

  • Cannot upgrade pacman due to conflict with package-query [SOLVED]

    Package query 0.9 requires pacman <4, package-query 1 requires pacman >=4, therefore I am totally unable to upgrade, even using pacman -f
    I'm aware that package-query is unsupported software, but this seems a bit stupid to me! Am I to uninstall package-query and therefore yaourt, only to reinstall them by hand, or is there a safe workaround?
    Last edited by markhadman (2012-01-24 11:02:20)

    jasonwryan wrote:
    markhadman wrote:Groan - guess pacman 4 is going to eat a day of my life after all...
    Or, realistically, 5 minutes.
    But if that is too much for you to spare, rather than bemoaning the fact that the developers have spent a significant amount of time and effort on this upgrade that will cause you such inconvenience, you could just install another distro - that would probably eat a day.
    Every other distro I've tried is inferior and eats up far more frustration time than Arch, which is why it's now on all my machines. I'm still putting off upgrading my 4 machines, though - because painful recent experience tells me that the chances of all 4 getting through this without day-eating breakage is about 6% (If you want a laugh at my expense, see this woeful example of breakage https://bugs.archlinux.org/task/27385). And yes, I'm aware that the longer I put it off, the worse my chances get.
    Edit:
    machine one (netbook).
    Time taken so far: 44 minutes (inc reading up on a few errors, plus line-by-line comparison of rc.conf.pacnew, reboot plus check of basic system workiness, plus waiting unsuccessfully for package-query source to download).
    Status: yaourt uninstallable (package-query git server appears to be down), openjdk6 broken due to bug, system otherwise appears healthy.
    Prognosis: Total 90 minutes for 4 machines seems a reasonable (optimistic) estimate, but I'll further put the other machines off until package-query git server is back up and running.
    And many apologies, this has veered somewhat off-topic and off-forum. I will probably make this my last post and let it die.
    Further edit: How do I mark a thread as SOLVED? I can't see an option anywhere, or any way to edit the thread title!
    edit: Nevermind, the trick is to edit the first post in the thread, it would seem.
    Last edited by markhadman (2012-01-24 11:03:17)

  • XPath Query Solved

    JDev Team,
    Is there a way to execute XPath Query on an XML document? In version 10.1.3 there was a extension through to achieve this. Do we have anything similar in TP4? If not, can we expect something for the production release? Please let me know.
    Thanks
    Bala.

    Please ignore my previous post. I found the option under the search menu.
    Thanks

  • EMP and DEPT sampledata query (SOLVED)

    I don't have access to create tables at work - just to run selects on existing tables.
    I've used the SQL below to use the 2 standard Oracle test dept and emp tables for testing, but - is it possible to use SQL to join the tables, or can the GET table WITH table AS ... SQL only ever work on one table at a time, rather than allowing joins to be done?
    Thanks
    GET dept
    WITH dept AS
         (SELECT 10 deptno
               , 'ACCOUNTING ' dname
               , 'NEW YORK' loc
            FROM DUAL
          UNION ALL
          SELECT 20 deptno
               , 'RESEARCH   ' dname
               , 'DALLAS' loc
            FROM DUAL
          UNION ALL
          SELECT 30 deptno
               , 'SALES      ' dname
               , 'CHICAGO' loc
            FROM DUAL
          UNION ALL
          SELECT 40 deptno
               , 'OPERATIONS ' dname
               , 'BOSTON' loc
            FROM DUAL)
    SELECT *
      FROM dept;
    GET emp
    WITH emp AS
         (SELECT 7369 empno
               , 'SMITH' ename
               , 'CLERK' job
               , 7902 mgr
               , '17-Dec-80' hiredate
               , 800 sal
               , NULL comm
               , 20 deptno
            FROM DUAL
          UNION ALL
          SELECT 7499 empno
               , 'ALLEN' ename
               , 'SALESMAN' job
               , 7698 mgr
               , '20-Feb-81' hiredate
               , 1600 sal
               , 300 comm
               , 30 deptno
            FROM DUAL
          UNION ALL
          SELECT 7521 empno
               , 'WARD' ename
               , 'SALESMAN' job
               , 7698 mgr
               , '22-Feb-81' hiredate
               , 1250 sal
               , 500 comm
               , 30 deptno
            FROM DUAL
          UNION ALL
          SELECT 7566 empno
               , 'JONES' ename
               , 'MANAGER' job
               , 7839 mgr
               , '02-Apr-81' hiredate
               , 2975 sal
               , NULL comm
               , 20 deptno
            FROM DUAL
          UNION ALL
          SELECT 7654 empno
               , 'MARTIN' ename
               , 'SALESMAN' job
               , 7698 mgr
               , '28-Sep-81' hiredate
               , 1250 sal
               , 1400 comm
               , 30 deptno
            FROM DUAL
          UNION ALL
          SELECT 7698 empno
               , 'BLAKE' ename
               , 'MANAGER' job
               , 7839 mgr
               , '01-May-81' hiredate
               , 2850 sal
               , NULL comm
               , 30 deptno
            FROM DUAL
          UNION ALL
          SELECT 7782 empno
               , 'CLARK' ename
               , 'MANAGER' job
               , 7839 mgr
               , '09-Jun-81' hiredate
               , 2450 sal
               , NULL comm
               , 10 deptno
            FROM DUAL
          UNION ALL
          SELECT 7788 empno
               , 'SCOTT' ename
               , 'ANALYST' job
               , 7566 mgr
               , '19-Apr-87' hiredate
               , 3000 sal
               , NULL comm
               , 20 deptno
            FROM DUAL
          UNION ALL
          SELECT 7839 empno
               , 'KING' ename
               , 'PRESIDENT' job
               , NULL mgr
               , '17-Nov-81' hiredate
               , 5000 sal
               , NULL comm
               , 10 deptno
            FROM DUAL
          UNION ALL
          SELECT 7844 empno
               , 'TURNER' ename
               , 'SALESMAN' job
               , 7698 mgr
               , '08-Sep-81' hiredate
               , 1500 sal
               , NULL comm
               , 30 deptno
            FROM DUAL
          UNION ALL
          SELECT 7876 empno
               , 'ADAMS' ename
               , 'CLERK' job
               , 7788 mgr
               , '23-May-87' hiredate
               , 1100 sal
               , NULL comm
               , 20 deptno
            FROM DUAL
          UNION ALL
          SELECT 7900 empno
               , 'JAMES' ename
               , 'CLERK' job
               , 7698 mgr
               , '03-Dec-81' hiredate
               , 950 sal
               , NULL comm
               , 30 deptno
            FROM DUAL
          UNION ALL
          SELECT 7902 empno
               , 'FORD' ename
               , 'ANALYST' job
               , 7566 mgr
               , '03-Dec-81' hiredate
               , 3000 sal
               , NULL comm
               , 20 deptno
            FROM DUAL
          UNION ALL
          SELECT 7934 empno
               , 'MILLER' ename
               , 'CLERK' job
               , 7782 mgr
               , '23-Jan-82' hiredate
               , 1300 sal
               , NULL comm
               , 10 deptno
            FROM DUAL)
    SELECT *
      FROM emp;

    is it you requirement.
    WITH dept AS
         (SELECT 10 deptno
               , 'ACCOUNTING ' dname
               , 'NEW YORK' loc
            FROM DUAL
          UNION ALL
          SELECT 20 deptno
               , 'RESEARCH   ' dname
               , 'DALLAS' loc
            FROM DUAL
          UNION ALL
          SELECT 30 deptno
               , 'SALES      ' dname
               , 'CHICAGO' loc
            FROM DUAL
          UNION ALL
          SELECT 40 deptno
               , 'OPERATIONS ' dname
               , 'BOSTON' loc
            FROM DUAL),
    emp AS
         (SELECT 7369 empno
               , 'SMITH' ename
               , 'CLERK' job
               , 7902 mgr
               , '17-Dec-80' hiredate
               , 800 sal
               , NULL comm
               , 20 deptno
            FROM DUAL
          UNION ALL
          SELECT 7499 empno
               , 'ALLEN' ename
               , 'SALESMAN' job
               , 7698 mgr
               , '20-Feb-81' hiredate
               , 1600 sal
               , 300 comm
               , 30 deptno
            FROM DUAL
          UNION ALL
          SELECT 7521 empno
               , 'WARD' ename
               , 'SALESMAN' job
               , 7698 mgr
               , '22-Feb-81' hiredate
               , 1250 sal
               , 500 comm
               , 30 deptno
            FROM DUAL
          UNION ALL
          SELECT 7566 empno
               , 'JONES' ename
               , 'MANAGER' job
               , 7839 mgr
               , '02-Apr-81' hiredate
               , 2975 sal
               , NULL comm
               , 20 deptno
            FROM DUAL
          UNION ALL
          SELECT 7654 empno
               , 'MARTIN' ename
               , 'SALESMAN' job
               , 7698 mgr
               , '28-Sep-81' hiredate
               , 1250 sal
               , 1400 comm
               , 30 deptno
            FROM DUAL
          UNION ALL
          SELECT 7698 empno
               , 'BLAKE' ename
               , 'MANAGER' job
               , 7839 mgr
               , '01-May-81' hiredate
               , 2850 sal
               , NULL comm
               , 30 deptno
            FROM DUAL
          UNION ALL
          SELECT 7782 empno
               , 'CLARK' ename
               , 'MANAGER' job
               , 7839 mgr
               , '09-Jun-81' hiredate
               , 2450 sal
               , NULL comm
               , 10 deptno
            FROM DUAL
          UNION ALL
          SELECT 7788 empno
               , 'SCOTT' ename
               , 'ANALYST' job
               , 7566 mgr
               , '19-Apr-87' hiredate
               , 3000 sal
               , NULL comm
               , 20 deptno
            FROM DUAL
          UNION ALL
          SELECT 7839 empno
               , 'KING' ename
               , 'PRESIDENT' job
               , NULL mgr
               , '17-Nov-81' hiredate
               , 5000 sal
               , NULL comm
               , 10 deptno
            FROM DUAL
          UNION ALL
          SELECT 7844 empno
               , 'TURNER' ename
               , 'SALESMAN' job
               , 7698 mgr
               , '08-Sep-81' hiredate
               , 1500 sal
               , NULL comm
               , 30 deptno
            FROM DUAL
          UNION ALL
          SELECT 7876 empno
               , 'ADAMS' ename
               , 'CLERK' job
               , 7788 mgr
               , '23-May-87' hiredate
               , 1100 sal
               , NULL comm
               , 20 deptno
            FROM DUAL
          UNION ALL
          SELECT 7900 empno
               , 'JAMES' ename
               , 'CLERK' job
               , 7698 mgr
               , '03-Dec-81' hiredate
               , 950 sal
               , NULL comm
               , 30 deptno
            FROM DUAL
          UNION ALL
          SELECT 7902 empno
               , 'FORD' ename
               , 'ANALYST' job
               , 7566 mgr
               , '03-Dec-81' hiredate
               , 3000 sal
               , NULL comm
               , 20 deptno
            FROM DUAL
          UNION ALL
          SELECT 7934 empno
               , 'MILLER' ename
               , 'CLERK' job
               , 7782 mgr
               , '23-Jan-82' hiredate
               , 1300 sal
               , NULL comm
               , 10 deptno
            FROM DUAL)
    SELECT *
      FROM emp,dept
      where emp.deptno =dept.deptno

  • Invalid Character in Email Address Check Query [SOLVED]

    I have been asked to identify a list of all email addresses on our system which contain invalid characters.
    Acceptable characters are: 1-9, and a-z, and also '\','.','@'.
    Is this something a regular expression would be able to handle?
    I have made a start via:SELECT fu.user_id
         , fu.user_name
         , fu.email_address fu_email
      FROM applsys.fnd_user fu
    WHERE (
               fu.email_address LIKE '%(%'
            OR fu.email_address LIKE '%)%'
            OR fu.email_address LIKE '%,%'
            OR fu.email_address LIKE '% %'
            OR fu.email_address LIKE '%+%'
            OR fu.email_address NOT LIKE '%@%'
            OR fu.email_address NOT LIKE '%.%'
           );But that seems pretty clunky, because I will have to add a new line for every character I want to search for. I have seen regular expressions being used for similar in the past, but I cannot tailor regexpressions to suit my need, because I find them really confusing.
    Thanks
    Message was edited by:
    jimr

    Thank you very much Frank and Anthony. We're not on Oracle 10 so the Translate option worked brilliantly - here's the answer, in case it is of help to anyone else who might have the same issue:
    SELECT fu.user_id
         , fu.user_name
         , wlr.notification_preference
         , wlr.email_address
         , DECODE(
              TRANSLATE(
                 LOWER(wlr.email_address)
               , '+0123456789abcdefghijklmnopqrstuvwxyz.@/-'
               , '+'
            , ' ', 'SPACE'
               TRANSLATE(
                  LOWER(wlr.email_address)
                , '+0123456789abcdefghijklmnopqrstuvwxyz.@/-'
                , '+'
           ) invalid_character
      FROM applsys.fnd_user fu
         , applsys.wf_local_roles wlr
    WHERE wlr.NAME = fu.user_name
       AND wlr.orig_system = 'PER'
       AND TRANSLATE(
              LOWER(wlr.email_address)
            , '+0123456789abcdefghijklmnopqrstuvwxyz.@/-'
            -- + followed by all the acceptable characters
           ,  '+'
           ) IS NOT NULL;

  • Stuck on Count Sub Query [ SOLVED ]

    A Purchase Order can be receipted in Oracle.
    I am using 4 tables here:
    po_headers_all - Stores Purchase Order Details
    po_lines_all - Stores Purchase Order Line Details
    rcv_shipment_lines - Stores Receipt Line Details
    rcv_shipment_headers - Stores Receipt Header Details
    This simple SQL shows that a PO with 3 lines has been receipted:
    SELECT pha.segment1
         , rsh.receipt_num
         , rsh.shipment_header_id
         , rsl.shipment_line_id
      FROM po.po_headers_all pha
         , po.po_lines_all pla
         , po.rcv_shipment_lines rsl
         , po.rcv_shipment_headers rsh
    WHERE pha.po_header_id = pla.po_header_id
       AND rsl.shipment_header_id = rsh.shipment_header_id
       AND pla.po_line_id = rsl.po_line_id
       AND pha.segment1 = 1442060;
    SEGMENT1             RECEIPT_NUM                    SHIPMENT_HEADER_ID SHIPMENT_LINE_ID
    1442060              526312                                     583092          1285161
    1442060              526312                                     583092          1285162
    1442060              526312                                     583092          1285163Because the PO has 3 lines, and each line has been receipted, there is a corresponsing receipt line in the 'rcv_shipment_lines' table.
    I am trying to work out a way to list a PO number, and do a count of how many times that PO has been receipted.
    In the above example, the PO has 3 lines, but it has only been receipted once, because all 3 receipt lines share the same Receipt Number.
    I have tried this:
    SELECT pha.segment1
         , (SELECT (COUNT(*))
              FROM po.rcv_shipment_lines rsl
                 , po.rcv_shipment_headers rsh
             WHERE pha.po_header_id = pla.po_header_id
               AND rsl.shipment_header_id = rsh.shipment_header_id
               AND pla.po_line_id = rsl.po_line_id) ct
      FROM po.po_headers_all pha
         , po.po_lines_all pla
    WHERE pha.po_header_id = pla.po_header_id
       AND pha.segment1 = 1442060;
    SEGMENT1                     CT
    1442060                       1
    1442060                       1
    1442060                       1But clearly that fails because it is counting the fact that each PO line has been receipted and has a corresponding line in the 'rcv_shipment_lines' table.
    I can't just join the 'po_headers_all' table to the 'rcv_shipment_lines' table, but have to join via the 'rcv_shipment_lines' table, - the only join is:
    'rcv_shipment_lines' joins 'rcv_shipment_lines' via 'shipment_header_id'
    And then join the 'rcv_shipment_lines' table to the 'po_lines_all' table, and from there to the 'po_headers_all' table.
    I am sorry if I am making a hash of explaining what I am trying to do.
    I can supply the table definitions if required, but I haven't done so to start with because it'll make this post even longer.
    Thank you

    Thanks Dave. This is the result:
    SQL> SELECT pha.segment1
      2       , (SELECT COUNT(DISTINCT receipt_num)
      3            FROM po.rcv_shipment_lines rsl
      4               , po.rcv_shipment_headers rsh
      5           WHERE pha.po_header_id = pla.po_header_id
      6             AND rsl.shipment_header_id = rsh.shipment_header_id
      7             AND pla.po_line_id = rsl.po_line_id) ct
      8    FROM po.po_headers_all pha
      9       , po.po_lines_all pla
    10   WHERE pha.po_header_id = pla.po_header_id
    11     AND pha.segment1 = 1442060;
    SEGMENT1                     CT
    1442060                       1
    1442060                       1
    1442060                       1I though then I could do a join via the PO_HEADER_ID instead of going via the po_line_id, and... it works! THANK YOU very much for your help. This forum is such a big help.
    This works, in case you are interested:
    SELECT pha.segment1
         , (SELECT COUNT(DISTINCT receipt_num)
              FROM po.rcv_shipment_lines rsl
                 , po.rcv_shipment_headers rsh
             WHERE rsl.shipment_header_id = rsh.shipment_header_id
               AND pha.po_header_id = rsl.po_header_id) eek
      FROM po.po_headers_all pha
    WHERE pha.segment1 = 1442060;Removed 'pha.po_header_id = pha.po_header_id'!

  • Error when running a query in BI 7.0

    Hi All,
    We have recently upgraded our BI system to BI 7.0. It is a technical Upgrade. The Bex version is also upgraded from Bex 3.5 to Bex 7.0. We are trying to execute a query which we have been using earlier on 3.5 system. We get an error message "Error cannot use variable ZCONLEH in structure elements".
    Can anyone let me know what could be the issue and how I can solve this?
    Suman

    Hello Suman,
    Check the table rszglobv for this variable - ZCONLEH.
    If it is available there then see which infoobject it belongs to and then look for that in the query designer. May be resaving the query solves the issue.
    If the variable is not available in the table, then it seems that the variable is lost and you might have to recreate it for keeping the semantics of the query the same as it was before the upgrade.
    Regards,
    Shweta

  • BEx error when running a query or workbook

    Hi guys,
    We're experiencing the following issue (trace dumped below) within BEx, while running either queries or workbook.  Nothing special in ST22.
    SM21 says:
    Communication error, CPIC return code 020, SAP return code 223
    Conversation ID: 53497548
    CPI-C function: CMSEND(SAP)
    We're using:
    BEx version "7.x (based on 7.20)", SP3, revision 1728
    SAP version
    SAP_ABA     700     0023     SAPKA70023
    SAP_BASIS     700     0023     SAPKB70023
    PI_BASIS     2006_1_700     0013     SAPKIPYM13
    ST-PI     2008_1_700     0003     SAPKITLRD3
    SAP_BW     700     0025     SAPKW70025
    FINBASIS     600     0019     SAPK-60019INFINBASIS
    SEM-BW     600     0019     SAPKGS6019
    BI_CONT     703     0016     SAPKIBIIQ6
    ST-A/PI     01M_BCO700     0001     SAPKITAB7F
    Dump content:
    3/3/2011 12:39:15 PM----
    com.sap.bi.et.analyzer.api.BExApplication+BExConnectionLostException: CPIC-CALL: 'CMRCV : rc=20
    LOCATION    CPIC (TCP/IP) on local host
    ERROR       connection to partner '10.1.9.126:3320' broken
    TIME        Thu Mar 03 12:39:14 2011
    RELEASE     720
    COMPONENT   NI (network interface)
    VERSION     40
    RC          -6
    MODULE      nixxi.cpp
    LINE        5087
    DETAIL      NiIRead: P=10.1.9.126:3320; L=0.0.0.0:2225
    SYSTEM CALL recv
    ERRNO       10054
    ERRNO TEXT  WSAECONNRESET: Connection reset by peer
    COUNTER     6
       at com.sap.bi.et.analyzer.api.BExApplication.Process(BExParameter iParameter)
       at com.sap.bi.et.analyzer.addin.BExExcelApplication.Process(BExParameter iParameter)
    CPIC-CALL: 'CMRCV : rc=20
    LOCATION    CPIC (TCP/IP) on local host
    ERROR       connection to partner '10.1.9.126:3320' broken
    TIME        Thu Mar 03 12:39:14 2011
    RELEASE     720
    COMPONENT   NI (network interface)
    VERSION     40
    RC          -6
    MODULE      nixxi.cpp
    LINE        5087
    DETAIL      NiIRead: P=10.1.9.126:3320; L=0.0.0.0:2225
    SYSTEM CALL recv
    ERRNO       10054
    ERRNO TEXT  WSAECONNRESET: Connection reset by peer
    COUNTER     6
       at com.sap.bi.et.analyzer.api.BExApplication.Process(BExParameter iParameter)
       at com.sap.bi.et.analyzer.addin.BExExcelApplication.Process(BExParameter iParameter)
    Brgds,
    Olivier

    Hello Suman,
    Check the table rszglobv for this variable - ZCONLEH.
    If it is available there then see which infoobject it belongs to and then look for that in the query designer. May be resaving the query solves the issue.
    If the variable is not available in the table, then it seems that the variable is lost and you might have to recreate it for keeping the semantics of the query the same as it was before the upgrade.
    Regards,
    Shweta

  • Error when running a query against Multiprovider using 0FIGL_VC1

    Hi SAP Gurus,
    I'm creating a MultiProvider for FI-GL.It has 2 Cubes.one is 0FIGL_VC1 (Virtual Cube) and other one is Customised Cube.When I run Query against this MultiProvider with  the combination of basic cubes key figures,I'm getting an error
    'Abort system error in Program SAPLRSDRC and Form RSDRC/Form DISPATCHER/RECEIV '
    then system gets disconnected from the Server .
    Please give me the solution to fix it & I'll assign the points .
    Thanks & Regards
    Raja

    Hello Suman,
    Check the table rszglobv for this variable - ZCONLEH.
    If it is available there then see which infoobject it belongs to and then look for that in the query designer. May be resaving the query solves the issue.
    If the variable is not available in the table, then it seems that the variable is lost and you might have to recreate it for keeping the semantics of the query the same as it was before the upgrade.
    Regards,
    Shweta

  • JSP Basics query

    Hello friends,
    I had asked few questions in my last post of init parameters in jsp, which must have got overlooked, but the questions are still not solved. Please help me.
    1) How to override jspInit() ?
    I tried one sample program, but the kind of output i get is weird, which leads me to ask this question. I have written one jsp: -
    Simple.jsp
    <%@ page language="java" contentType="text/html; charset=ISO-8859-1"
        pageEncoding="ISO-8859-1"%>
    <%@ page import="java.io.*"  %>   
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    <html>
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
    <title>Welcome to SWA_JSP</title>
    </head>
    <body>
    <%!
         String classPath = "Yet to be set!";
         String realPath = "This one needs to be set too!";
         String fileSperator = File.separator;
         String libPath = "library ....ann what ?";
         public void jspInit() {
              // I am trying to override jsp init method
              System.out.println("\n\nMy try at overriding the jsp init method !");
    %>
    <%
         classPath = System.getProperty("java.class.path");
         realPath = application.getRealPath("");
         libPath = System.getProperty("java.library.path");
    %>
    <center>
    <p>
    <table >
         <tr>
              <td width = "25%">
                   <b>
                   Parameter obtained
                   </b>
              </td>
              <td width = "50%">
                   <b>
                   Value
                   </b>
              </td>
              <td width = "25%">
                   <b>
                   Obtained using
                   </b>
              </td>
         </tr>
         <tr>
              <td>
                   classpath
              </td>
              <td>
                   <%= classPath %>
              </td>
              <td>
                   System.getProperty("java.class.path");
              </td>
         </tr>
         <tr>
              <td>
                   realpath
              </td>
              <td>
                   <%= realPath %>
              </td>
              <td>
                   application.getRealPath("");
              </td>
         </tr>
         <tr>
              <td width = "25%">
                   Library path
              </td>
              <td width = "150px">
                   <%= libPath %>
              </td>
              <td width = "25%">
                   System.getProperty("java.library.path");
              </td>
         </tr>
    </table>
    </p>
    </center>
    </body>
    </html>And in index.html i have a hyperlink that points to this jsp: -
    index.html
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    <html>
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
    <title>Insert title here</title>
    </head>
    <body>
    <center>
         <p>
              <table>
                   <tr>
                        <td>
                             <a href="simple.jsp">Click here</a> to find out what the classpath and <br>
                             realpath of servletcontext for the container mean ?
                        </td>
                   </tr>
              </table>
         </p>
    </center>
    </body>
    </html>Now, the scenario is as follows,
    1) The index.html is loaded
    2) I click on the "click here" hyperlink
    3) The simple.jsp is loaded .... in the console......"My try at overriding the jsp init method !" is printed once.
    4) At this moment, i again click on Refresh page button of Firefox, the simple.jsp is loaded again, and in the console it again prints .... "My try at overriding the jsp init method !" ....that means the SOP statement was printed twice!!!!
    5) i again click on Refresh page button or F5 key several times, ......but from now on the SOP is not printed in the console
    Thus, in the console, it only shows, the SOP statement printed twice! .... But, it should print only once, since i have overridden the jspInit() method.....and it is invoked only once......why this strange behavior ?
    and my second doubt is :-
    2) We have nine implicit objects, are these objects available even in declaration tags
    *<%! ..... %>* also ? , ..... because i could neither use the application nor config object, not even request object in the jspInit() method.....i mean, in any normal method declared in declaration tag, the implicit objects are NOT available* ... why is it so ?
    Thanks and Regards
    Omkar Patkar

    Hi
    i got my query solved....@ [this post|http://saloon.javaranch.com/cgi-bin/ubb/ultimatebb.cgi?ubb=get_topic&f=50&t=017658]
    Thanks and Regards
    Omkar Patkar

  • WQL Query SCCM 2012: computers that need specific article or bulletin.

    Hi!
    I need a
    query
    that returns the
    computers that
    require
    a specific bulletin
    or
    article.
    Example:
    MS14-080
    Example:
    article
    2687455

    Thank you all so much
    Nick
    Pilon,
    Eswar
    Koneti
    and
    Xin
    Guo!
    I need a
    WQL
    query
    because
    my
    report server
    is not working.
    At the moment
    I can't
    repair
    it.
    A
    WQL
    query
    solves
    my problem.
    I know that the Log SMSProv returns results of tasks that run in graphical mode.
    I did it with the query shown in the attached image and found the following Query to the log.
    I used the Query found in the log, but I can’t edit it to show the name of the 95 PCs found.
    I need to know who
    are the
    95
    PCs that
    need the
    article
    2687455
    in the
    "All
    Software
    Updates". My Report don't work.

  • X3-02 Flight Query

    Can I know what is the function of Flight Query in X3-02?
    Settings>Phone>Flight Query
    Solved!
    Go to Solution.

    Thanks again for the reply Meow
    It is an honour to have a moderator to reply my thread
    What I try to say earlier is, after my 5800 offline profile activated, all active connections will be disconnected...
    After disconnection(during offline mode), I can switch on my bluetooth during that time although it is in offline mode but I cannot do so in flight mode for my X3-02.
    Actually I have made the "profile selection" as one of my shortcuts in the desktop cause I switch profiles a lot....
    And one more thing I'm still using v5.60 for X3-02, kinda sad V6.00 haven't reach my region yet.... If possible I want to request for next firmware update to support video call using the back camera... thanks in advance
    Sorry for the bad English

  • Something Wrong with my DELETE statement

    Dear All, The below Code suppose to delete those records which are matching p.sys_cd = 'DYT' criteria. But its deleteing 'DYT' matching records and the other records also. Do you thing any logic problem in the below code. Help me guys.
    EXECUTE IMMEDIATE 'DELETE FROM SLS_F_TRANSACTION f
    WHERE f.trans_dt_key between
    (SELECT TO_CHAR(MIN(i.use_dt),''YYYYMMDD'') from stg_bi_actv_chrg_int i) and
    (SELECT TO_CHAR(MAX(i.use_dt),''YYYYMMDD'') from stg_bi_actv_chrg_int i)
    AND EXISTS (SELECT ''X'' FROM cp_d_customer p where p.sys_cd = ''DYT'')';
    Thanks and Regards
    Phani

    Hi Phani,
    can you give us the table structure?
    seems like column f.trans_dt_key is a varchar2 column.
    convert it to date when checking using "between" operator.
    check if below query solves your purpose...
    EXECUTE IMMEDIATE 'DELETE FROM SLS_F_TRANSACTION f
    WHERE to_date(f.trans_dt_key,''YYYYMMDD'')  between
    (SELECT MIN(i.use_dt) from stg_bi_actv_chrg_int i) and (SELECT MAX(i.use_dt) from stg_bi_actv_chrg_int i)
    AND EXISTS (SELECT ''X'' FROM cp_d_customer p where p.sys_cd = ''DYT'' and f.sys_cd = p.sys_cd)'; Regards
    Imran
    Edited by: imran soudagar on Mar 25, 2010 7:46 PM

  • Error when activate the Adobe forms

    Hi,
      I am getting the below error message when activate the adobe forms,and the message tells that to install a forms design tool,please tell me which tool in need to install and where i will get this tool.
    Could not start Layout Designer (see long text)
    Message no. FPUIFB086
    Diagnosis
    The forms design tool for developing the form layout could not be started; either it is not installed or there are errors in the installation.
    Procedure
    Make sure that you have the forms design tool installed on your desktop (the tool is part of the SAPGUI installation).
    Also read SAP Note 801524.
    Thanks,
    Deesanth.

    FIrstly, you have posted the question in the wrong forum. There's an entire forum in SCN only for Interactive Forms: .
    Secondly, this is a frequently asked question, especially in the Interactive Forms Forum. There's enough information there to get your query solved by searching.
    pk

Maybe you are looking for