Question related to combining rows...

Hi,
I have a question related to combining rows...
From our typical tables.... Dept and Emp.
I want a result set like....
Dept# | Employees
10 | <Emp1>, <Emp5>, <Emp6>
20 | <Emp7>, <Emp2>, <Emp8>, <Emp9>
30 | <Emp10>, <Emp11>
40 | <Emp12>
Plesae give me the query...
Thanks
Abdul.

How about this solution looks like?
create or replace
function fnc_concat_data(p_query VARCHAR2,P_ID NUMBER) RETURN VARCHAR2
AS
type res_tab is table of varchar2(20);
result_tab res_tab;
v_retval varchar2(256);
begin
execute immediate p_query || p_id BULK COLLECT into result_tab;
FOR i IN 1..result_tab.COUNT LOOP
v_retval := v_retval||','||result_tab(i);
END LOOP;
v_retval := substr(v_retval,2);
return (v_retval);
exception
when others then
return('Error');
end fnc_concat_data;
sql> select deptno, fnc_concat_data('select ename from emp where deptno=', deptno) employees from emp group by deptno
deptno employees
30     ALLEN,WARD,MARTIN,BLAKE,TURNER,JAMES
20     SMITH,JONES,SCOTT,ADAMS,FORD
10     CLARK,KING,MILLER

Similar Messages

  • Can someone plz confirm me that how i can change or update the security questions related to my apple id? as i have been never put them since i create my apple id but now due to some security reasons its asking me again and again the answers. i am unable

    can someone plz confirm me that how i can change or update the security questions related to my apple id? as i have been never put them since i create my apple id but now due to some security reasons its asking me again and again the answers. i am unable to go through the process. thanks.

    Some Solutions for Resetting Forgotten Security Questions: Apple Support Communities

  • Question related to Java Concurrent Program

    Hi Friends,
    I have a basic question related to Java Concurrent Program in the Oracle application. I would like to know the how Java concurrent program is executed in Oracle applications.Also, want to know where can I find the document for the AOL packages for Java concurrent program. Document for packages like oracle.apps.fnd.cp.request.* , oracle.apps.fnd.util.*.
    Please let me know.
    -Thanks,
    Satya

    You may also check:
    Note: 250964.1 - How to Register Sample Java Concurrent Program
    https://metalink.oracle.com/metalink/plsql/ml2_documents.showDocument?p_database_id=NOT&p_id=250964.1
    Note: 186301.1 - How to register and execute Java Concurrent Program ?in Oracle Applications R11i?
    https://metalink.oracle.com/metalink/plsql/ml2_documents.showDocument?p_database_id=NOT&p_id=186301.1

  • Interview Questions related to Warehouse management

    Hi all
    Can u please help me regarding  Interview Questions related to Warehouse management
    Thanks and Regds
    Daniel

    Have you searched in very first thread
    [Warehouse Management?|New to Materials Management / Warehouse Management?;

  • How to combine rows with small numbers into single "other" row?

    How can I combine rows with value 6(for example) or lower to single row representing the SUM of all this values and label OTHER, so the pie chart will have a chance to display all small values combined?
    I'm using Numbers 09

    HI Peter,
    When you write a decimal number, is the decimal separator a period ( . ) or a comma ( , )? If it's a comma, then the syntax error can be corrected by replacing the list separator in the formula, a comma in Jerry's formula, with a semi colon ( ; ):
    =SUMIF(B; "<6"; B)
    (Added): The two Bs appear in blue 'lozenges' in Jerry's image because that is the way cell (or column) references are displayed in Numbers when a formula has correct syntax.
    Regards,
    Barry
    Message was edited by: Barry

  • Questions relating to Groupware Integration (Outlook)

    Hello,
    I have few questions relating to groupware integration for Outlook:
    Q1) The "Relate to CRM" option in outlook add-in for end user is available only  in client side integration? Is it not available for server sider integration (i.e. in server side, end user cannot directly assign CRM account or Transaction to object in outlook the way it is done in client side)?
    Q2) Is there any end user interface (like add-on) available in server side?
    Q3)In client side - Can the outlook add-on for SAPCRM be enhanced for different business logic or look n feel?
    Thanks,
    Vicky

    Hello Vicky,
    1) Yes the Relate to SAP CRM function is part of Client-side groupware only.
    2) The Add-in is only available with Client-side groupware.
    3) The Add-in cannot be customized. However the results can be influenced by parameters in transaction GWIPROFILE.
    The information displayed in the Business information Pane can be changed.
    Best Regards,
    Gervase Auden

  • Basic Questions related EHPs for SEM

    Hi Guys,
    I've some basic questions related to EHPs: -
    1. If we don't mean to implement any of the new functionalities does it make any sense to implement EHP? In other words do EHPs also have some general improments other than the functionalities which can be specifically activated?
    2. If we just activate a functionality and don't implement/ use it can there be any negative impact?
    3. In case of a pure technical upgrade from SEM 4.0 to SEM 6.0 which EHP would be recommended?
    4. Is there a quick way to find all relevant notes in EHPn which are related to corrections for EHPn-1?
    Thanks in advance,
    -SSC

    HI,
    If you see some of my older posts I have had many issues with certain features of the EHP2 functionality but that doesn't mean I would recommned against it.
    BCS 6 EHPs 3 & 4  (BCS 6.03 / 6.04) - enhancement packs worth implementing?
    BCS 6 EHP 2 (BCS 6.02) - activation of enhancement pack
    My recommendation is to implement the EHPs but not necesarrily activate the functions (in SFW5) unless you need them - this means that you will only have to test once after EHP implementation and will have the ability to activate the other features as and when required (although testing is required after activation of course) whereas it might be difficult to persuade your client/basis team to implement EHP4 later if you don't do it now.
    In the features of EHP2 (activate FIN_ACC_GROUP_CLOSE) it states that there is a general performance improvement - although I have yet to experience it! From OSS note 1171344 "The functionality which is available in EHP2 consists of...
    ... Performance improvements of status management, reporting and initial start-up of consolidation workbench and monitor.
    Since activating FIN_ACC_GROUP_CLOSE I have had many OSS notes requiring application but i discovered that when the technical team implemented the EHPs (before i joined this client) they somehow forgot the latest SP (support packs) and didn't upgrade to the current level - so make sure that you get the right SPs too (see the links in Greg's link above) to avoid the many OSS notes.
    As for your question - "is there a list of OSS notes to specific to EHP upgrades? - the answer is most definietly "NO" - I already asked OSS in desperation!
    however, you can see the OSS notes that i have applied listed in the above link ( BCS 6 EHP 2 (BCS 6.02) - activation of enhancement pack )

  • Some questions related to SAP XI

    Hello!
    I would like to know the answers for the following questions regarding SAP XI-context (if it possible with Yes/No and a short comment/explanation)
    <b>CAPACITY PLANNING GUIDELINES</b>
    a) Guidelines to size the server(s)?
    b) Guidelines for sizing the over all environment for High-Availability
    <b>ARCHIVING CAPABILITIES</b>
    a) Approach to archiving of obsolete data
    <b>PLATFORM SUPPORT</b>
    a) Software supported on HP-UX 11.i V2 (r6) on Itanium.
    b) software supported on Windows 2003 sp1 (x64) on AMD Opteron 
    c) software support aligned with release roadmaps for future versions of HP-UX and/or Windows Server
    d) Software supported on OS clustered servers  (If mutliple products, please indicate if all are support or list areas where clustering may not be recommended and why)
    <b>RELATIONAL DATABASE </b>
    a) Does your system run native to the Oracle 10g RDBMS (RAC) and database tools?  If not, please explain the databases and tools supported.
    b) database monitoring tools be used to manage impending maintenance needs and potential problems and performance impacts (i.e., tool will monitor and detect prior to real problem occurring)
    c) standard pre-defined SQL queries and related calculations provided for use with industry standard reporting tools
    d) database accept binary-large-objects (BLOBs) and  be referenced via the relational engine.
    Thank you in advance!
    Regards!
    A.Henke

    two questions related to this:
    1. Why Java is designed to only permit single
    inheritence, any stories behind the scene? I think
    some major reasons why "prefer interfaces toabstract
    classes" is accepted is rooted in this limitation.Yes, one of the reasons interfaces are better is that
    you can only extend one class, but implement many
    interfaces. Say you have a concrete class that should
    "implement" two different types. If those types were
    defined as abstract classes, you could only use one
    type. You could implement both types if they were
    interfaces though. So why java is designed to have this limitation? There may be some arguments before this is settled down. I always like to hear this kind of stories:)
    2. Base on the fact that once an interface is outof
    box and widely implemented, it is almostimpossible
    to change it. So how you guys design yourinterfaces?
    Could you share some? In my idea, I would designmy
    interfaces as compact as possible.You could extend the interface and start using that
    if you didn't want to break existing code. You
    couldn't use that implementation as an Interface1
    though, since the new methods only exist in
    Interface2, so that's not an optimal solution.So we may always need to add a new interface when we just want to add a new method.

  • General questions related to Java

    Good evening,I would like to ask you some questions related to Java :
    1) class A {
    public int x=1;
    public int y=5;
    public A() { y=6; }
    public A(int a) { x=a; }
    public A(int a, int b) { x=a; y=b; }
    class B extends A {
    public B() {}
    public B(int a) { super(a); }
    public B(int a, int b) { super(a,b); }
    public B(int a, int b, int c) { x=a+b+c; }
    public B(int a, int b, int c, int d) {
    super(a,b); y=c+d; }
    public class Test {
    public static void main(String[] args) {
    B b4 = new B(1,1,1);
    System.out.println("b4.x: "+b4.x+" b4.y: "+b4.y);
    I cannot understand why y = 6.
    As i see it,i find it more logical that y = 5.
    Could anybody tell me why y becomes 6?
    How did we get into the constructor of A : public A() in order y to be changed?
    2) Well in an exercise i have to handle out we have to find the a,b,c of a program .Unfortunately i dunno about them,Can anybody explain to me what do they mean or attach me a link (e.g. a tutorial) in order to figure out?
    a)pre condition in Java
    b)post condition in Java
    c)invariant condition
    3)
    3) Fraction apple = new Fraction (1, 2);
    Fraction peach = new Fraction (4, 5);
    Fraction pear = apple;
    peach.halve();
    pear.halve();
    System.out.println(apple);
    System.out.println(peach);
    System.out.println(pear);
    It's the first time i see an object as a parameter in System.out.println.
    CAn anybody tell me when i can pass an object as an argument in System.out.println?
    Thanks in advance!

    How did we get into the constructor of A : public A() in order y to be changed?if you don't explicitly call a super constructor, the empty super constructor is called for you. If no empty accessible super constructor is available and no explicit call from subclass is made - compile error.
    CAn anybody tell me when i can pass an object as an argument in System.out.println?Whenever you want. Object.toString() will be called and the resulting String will be used. If the object is null, the String "null" will be used instead.

  • Question related to E-Business Suite (Business Group)

    Dear All,
    I just started my career as an oracle Functional Consultant (HRMS), I have questions related to Business Group
    - Why BG is a part of HRMS? Although we associates different profiles with it like, legal entity, which is used for financial purpose only.
    - Under which conditions we make more then on Business Group?

    Pl do not post duplicates - E-Business Suite queries related to BG

  • Question related to concept of PCK

    Hi All.
    I am quite a newbie to XI and am only learning it thru online help. I have one conceptual question related to PCK.
    My understanding is that PCK is needed by a small business company to communicate to its larger partner which already has XI running. Correct me if I am wrong here itself.
    Now if the larger business partner already has XI, why does the smaller one need a PCK at all? The XI instance on the larger partner will have all the necessary adapters to understand any format send by the partner. So even if the partner(smaller) sends any format- be it IDOC/HTTP/FTP, the XI instance on larger partner will have its adapters ready to perform the conversion.
    Then why is this PCK needed at all?
    Thanks in advance. Hope my query is clear
    Regards.
    Samant

    Hi Samant,
      Your question is a very good one, Though I have not worked on PCK, I can share my ideas based on some brain storming session I had with our collegues & business partners.
      While executing projects, there are technical & operational issues. For example, when you access any HR related data of a UK based organisation then all those who work on that project have to undertake data security pledge. Like wise there are many constraints on data & system accesses, which vary across organisations.
    When you use PCK*, irrespective of different systems what the small vendors have, you communicate with your Big company's XI system only on the XI's msging protocol http(s)/SOAP. This allows a fair amount of ownership of data/access related issues to the small partners.
    -> you go for PCK, when there is no need for small vendors to go for XI.
    Hope this is of some help. As Michal said there might be much more (or even better) reasons.
    Michal, when you say "all of the mappings and transformations have to be on the small company side", what exactly you mean by this. can you please eloborate.
    Thanks & Regards
    Vishnu

  • Question related to Synchronous update

    Hi, all
    I have some question related to synchronous update:
    1. What is the syntax if I want to write synchronous update.
    Do i write as:
    call funcition A in update task
    commit work and wait
    Or just
    call function  A (A declared as update type function )
    commit work and wait
    Or ...
    2.If we use synchronous update, is VBHDR,VBDATA still filled the same way when using asynchronus update?
    Thanks in advance,
    Liming

    Hi,
    Why do we use this " In Update Task " ??
    The main update technique for bundling database changes in a single
    database LUW is to use CALL FUNCTION... IN UPDATE TASK.
    How do we Use ??
    A typical R/3 installation contains dialog work processes and at least one update work process. The update work processes are responsible for updating the database. When an ABAP program reaches a COMMIT WORK statement, any function modules from CALL FUNCTION... IN UPDATE TASK statements are released for processing in an update work process. The dialog process does not wait for the update to finish. This kind of update is called asynchronous update.
    What is the Use... ??
    Asynchronous update is useful when response time from the transaction is critical, and the database updates themselves are so complex that they justify the extra system load

  • Question related to SCJP 6 certification

    Hi Everyone,
    Just have question related to SCJP Exam.
    I have started to prepare for SCJP 6 from yesterday (3-4 hours in a day) and I am planning to take SCJP exam in march last week. can u suggest books, which I need to go through..and also I need to write exam at earliest..Do I need to take more than one month for preparation....or less than that is it possible for good knowledge and score?
    Thanks,
    Naveen

    Hello Naveen,
    I am also goining to write SCJP1.6 exam(hopefully this month end).
    I am referring Kathy Sierra, Bert Bates SCJP1.6. It is an awesome book and it include 350+ mock question excluding the ones you get at end of each chapter.
    I dont know whats the level of your Java knowledge. In my opinion someone who has a fair amount of knowledge of the subject should take atleast 2 month of preparation before taking the exam. Syllabus for SCJP6 is more or less easy(except for few concepts) but you know what makes it a difficult exam is the minor details which we tend to ignore while studying the Java subject.
    Also the questions will contain more than 1 correct answer which you cant answer correctly unless you have pracised a lot of mock exams.
    So my advise to you is :take time to brush up the minor details of the subject and do lot of mock tests. That ways you can ensure good marks.Dont hurry, else you may clear the exam but not with good percentile.
    Thats all knowledge I wish to give you.
    Let me know if you want some more.
    Best of Luck for your exam,
    Best regards,
    Suvojit CHAKRABORTY

  • Question related to the Federated Portal Network.

    Hi All,
    I have a question related to the Federated Portal Network.
    I have to configured FPN between two portals :
    1. BI-portal  (Producer Portal) (EP 7.0)
    2. Portal for other systems (Consumer Portal) (EP 7.0)
    Can anybody help regarding this, I need material or URLs   ...
    Thanks & Regards,
    Jay

    Hi Jay,
    Check out following links for fedrated portals
    http://www.sdn.sap.com/irj/scn/index?rid=/library/uuid/703cfbbd-e85e-2a10-00a3-ecd502c08e82&overridelayout=true
    http://www.sdn.sap.com/irj/scn/index?rid=/library/uuid/70191d1e-2bd1-2a10-d9b7-ba19500da527&overridelayout=true
    Regards,
    Vaishali

  • Question related to dynami calc

    Hi all,
    I have a question related to dynamic calc members, I read in the dbag saying , it is not possible to add more than 100 members as a children under a
    dynamic calc member...is it right even with 9 and 11 versions.. What are the options we have if we really want to add ....????? I am curious to know about this....
    Thanks

    When you set a member to dynamic calculation (for aggreagtion purposes), it has to look at all of the children in order to calculate. If it is on a sparse dimension, it has to bring multiple blocks into memory to do the calculation. If the dimension is dense, it on;y brings in the single block which is much quicker. as for increasing the block size, If you need the summarization, you have not changed the block size at all. You would have the member regardless. If it is dynamic, you will see the block smaller than if it stored data, but the logical block size (the memory it takes) will be the same size regardless because Essbase expands the block in memory to do the calculations.
    This is the same rational as to why we don't want dynamic calculation on sparse dimensions unless it is comfined to one or two children. The reading of multiple blocks can be very time consuming

Maybe you are looking for

  • How can we move LDOM from one serve to other.

    Hi, i have an LDOM setup on a T6320 Blade with Solaris 10. The boot image of LDOM is under a ZPool image of 32 GB. I want to move this LDOM from T6320 to another T6340. but they don't have the shared disk or not connected to same SAN. Sun's document

  • Inserting existing records to table and getting new identity ID for each row

    I have an issue that I inherited where I need to insert some data to  12 tables related by FK  for about 40 records to an existing database through TSQL, SSIS is not an option.. Essentially the situation is that many weeks ago someone deleted a bunch

  • Upgrade Runtime Systems create new Tracks?

    Hi all, we are in the situation, that our Runtime Systems will upgrade from NW04 to NW04s. Cause we have ongoing development, we can not upgrade existing tracks itself, while the release change will last several weeks (D,Q and P). The idea was, to cr

  • Child protection fail: Gmail app's integrated browser bypasses Safari restrictions

    I found, the hard way, that my children are able to bypass parental restrictions on their iphones by clicking through links in gmail.  Scenario: iOS device, Parental restrictions on downloading 12+ apps, Parental restrictions on Safari browser.    Re

  • Vado central changes clip dates to transfer time

    vado central changes clip dates to transfer time When vado central transfers movies from vado hd onto my imac, each clip gets the date of the transfer, not the date the movie was taken. I have the latest vado central for macs (..0f6). I've tried both