Question about nested functions

This can't be done
for example
select min(count(*))
from...
I need to calculate the minimun of a cuantity I obtain from count(*)
Any ideas?
Thanks

You can nest aggregate functions. Here is what it says in the [SQL Reference|http://download.oracle.com/docs/cd/B19306_01/server.102/b14200/functions001.htm#i89203] .
You can nest aggregate functions. For example, the following example calculates the average of the maximum salaries of all the departments in the sample schema hr:SELECT AVG(MAX(salary)) FROM employees GROUP BY department_id;
AVG(MAX(SALARY))
10925
This calculation evaluates the inner aggregate (MAX(salary)) for each group defined by the GROUP BY clause (department_id), and aggregates the results again.

Similar Messages

  • Question about the function module (RFC_READ_TABLE)

    Dear everyone
    Could I ask you a question about the function module (RFC_READ_TABLE)?
    I was asked if it's possible to create a report which compares the data between different SAP systems (both production systems).
    Now, the easiest way would be to use the function module (RFC_READ_TABLE) within a SAP infoset query (SQ01 type query).
    But I heard the rumor that using the function module (RFC_READ_TABLE) is not advisable due to the security reason.
    However, I am not exactly sure what sort of security problems this function module can possibly have...
    Would you help me on this?
    I also would like to know if using "remote enabled module" type function module can always overcome this possible security issue.
    Or, are there any points that I need to be careful about even when I use "remote enabled module" function module?
    Thank you very much in advance.
    Takashi

    Dear Fred-san
    Thank you very much for your support on this.
    But, may I double check about what you mentioned above?
    So, what you were mentioning was that if some user executes the query with
    the function module (RFC_READ_TABLE), under the following conditions, he can access to
    the HR data even when he does not have the authorizations for HR transactions?
    <Conditions>
    1. the user has the authorization for HR database tables themselves
    2. RFC_READ_TABLE is called to retrieve the data from HR database
    <example>
    Data: LF_HR_TABLE like  DD02L-TABNAME value 'PA0000'.
    CALL FUNCTION 'RFC_READ_TABLE'
       EXPORTING
        query_table                = LF_HR_TABLE
      TABLES
       OPTIONS                    =
       fields                     =
       data                       =    .
    But then, as long as we call this function module for a non-critical tables such as
    VBAP (sales order) or EKKO (purchase order) within our query, it wouldn't seem to be
    so security risk to use RFC_READ_TABLE...
    Besides, each query (infoset query) has got the concept of user groups, which limits
    the access to the queries within the user group.
    ※If someone does not belong to the user group, he cannot execute the queries within that
       user group, etc
    So, my feeling is that even infoset queries does have authorization concept...
    Would you give me your thought on this?
    I also thank you for your information for SCU0.
    That is an interesting transaction
    Kind regards,
    Takashi

  • Question about Percent Function

    This kinda goes along with my question about the plus sign. That was answered by the fact it means there is more than can be displayed in the field with the plus sign. The problem I am having is all of the fields with the plus sign are formated to be PERCENT. These fields are filled in via the C# program. The values are calculated in the C# program and outputed to the PDF form in the form of 00.00 - 100.00. Thus if I am filling in these fields with values that are within a PERCENT range, then why are they showing a plus sign. I have even go as far as to wipe the field clean, re-do the Text box, re-format as PERCENT, with the text centered, and the No Calculation radio button set true. The only other thing I do these fields is set the FONT to 10 point or otherwise the huge in size.

    Thank you all for the help on this. What I found is:
    it is correct that the incoming value to a fillable field for a PERCENT must be between 0 and 1 BUT this is NOT the complete answer.
    If I filled the field with 33.33 then it will display  33.33 + which says the display is too big.
    If I filled the field with .3333 thin it will display .3333 without the PLUS sign, but is still not correct because the FORMAT is set to PERCENT.
    What I had to do is add the following JAVA script.
    // Custom Calculate script for text field
    (function () {
        // Get the field values
        var v1 = getField("NO_FEAR_ASSOC_WITH_TARGETED_DISABILITY_PERCENT_1").value;
        // Set this field value
        event.value = v1;
    Now if the input is .3333 the display is now 33.33% which is correct. Sense the JAVA Script is basicly a NOP, this tells me that the PERCENT format requires some kind of trigger. Sense a FILL is NOT a trigger, the display comes out incorrect.

  • Question about 2 functions.

    OK, new question from me.
    I have two functions, bassicly they are smilar, but the problem is that I need that second function to start up or become active, after certain amount of time or when "x" reaches 1000. How can I do this?
    And second question is, both functions make objects apper on stage in exact coordinates (5 spots), how can I make that objects woun't apper on the same spot, bassicly it would check if that position is occupied, it chooses other spot. (spot choosing is performed by random)
    Oh, and third question.
    I want to make the object to be active for two seconds, and then it disapper, my thought was to make tween, but couldn't find the type of appearance.

    1. You can check the condition to determine if you should do something, i.e.
    if (x >= 1000) {
        // do something
    2. First randomise an Array [Spot 1, Spot 2, Spot 3, Spot 4, Spot 5], then place your object to the spot in the order of the array item.
    3. My favorite way is to use TweenLite.delayedCall(). For example if you want to remove something in 2 seconds time you do:
    TweenLite.delayedCall(2, remove, [anObject]);
    function remove(displayObject:DisplayObject):DisplayObject {
        return removeChild(displayObject);
    (You can use Timer class etc for this but TweenLite wins always )

  • More syntax questions about nested symbols

    I have a symbol timeline that does everything I need it to do except to access a function within the stage symbol. I would have thought that calling the function in the stage symbol from a nested symbol (which is loaded dynamically, if that makes any difference) would be something along the lines of:
    sym.getComposition().getStage().gotoNextSlide("slide5");
    but no luck. I can alert the stage itself as [Object Object], which brings up another question. Is there an always-available property of objects that one can alert or trace to make sure the correct object is being targeted? I've had no luck with the symbol's id, name, or symbolName.

    Sure. You've seen one form of the project I'm working on, though I'm at the next speedbump. Here's an excerpt of the involved parts.
    I have the stage symbol and within that symbol, I have a function:
    function gotoSlide(slideName){
              fadeTo(slideName);
    function fadeTo(slideName){
         /// this all works fine, when called from the main timeline
    In the composition, I'm loading slides from the library and on the timeline of one of those slides is the following.
    navHidden = true;
    var trueButton = sym.getSymbol("answers").$("true");
    trueButton.bind('click',goNext);
    function goNext(){
              sym.getComposition().getStage().gotoSlide("slide_05");
    I know there are other syntaxes I could use but refactoring is in the future. The console log I get is:
    Object [object Object] has no method 'gotoSlide'
    It's slide 5 in these:

  • Question about sdo_relate function

    My application has to check if a point geometry is inside (MASK='ANYINTERACT') a polygon geometry. I am trying to figure out if sdo_relate function works with rectangle only or if it works with polygon. I have wrote a few sql test and it seems to work with polygons, but I dont know how it works.
    My question is, if the geometry is not a rectangle, why dont I have to use projection to project both geometry into a plane first?
    For example if I have a polygon (-140, 35, -139, 36, -139, 35, -140, 34, -140, 35) and a point(-139.3, 35.6) how does sdo_relate finds out if the point is within the polygon without projecting them?
    Thanks.

    how does oracle connects the points in a polygon that's not on the same latitude or longitude?Your question is a little ambiguous. What do you mean by 'not on the same latitude..'? Are you talking about different coordinate systems? Or do you just mean how does Oracle know whether your point is inside the polygon or not?
    If its the former then read:
    http://download-uk.oracle.com/docs/html/B14255_01/sdo_cs_concepts.htm#i882173
    If the latter, then suffice to say that Oracle Spatial knows how to work these things out in order to return the correct result.
    Have a read of the spatial concepts documentation:
    http://download-uk.oracle.com/docs/html/B14255_01/sdo_intro.htm

  • Another beginner question about targeting functions

    I've read what I thought was an excellent thread about scope in EA, but I'm still not getting some of the basics (btw the thread was http://forums.adobe.com/message/5287753#5287753).
    I have "slides" in the symbol library and in the main composition compositionReady script I've set up a generic script for playing back sound. That script works fine when I bind it within the compositionReady script to a symbol and click, so I know the funciton itself is fine. My question, I'm programmatically loading the slides from the library as I go along and want to use the generic function I created in the compositionReady script, but I can't seem to create the proper syntax to call the script. Here's some that I have tried. What is the correct syntax? The script is on frame inside the slide symbol.
    //sym.getComposition().getStage().playSound();
    //sym.getComposition().playSound();
    //Edge.getComposition("CER_1").playSound();

    Thanks for having a look. Yea, it's getting to the script fine but it doesn't like the syntax. Console always indicates javascript error, which is what happens when Edge throws an exception because it doesn't know what to do. The article that Elaine posted on above gives me the sense that it might be best to change the function to a variable, then it would be in scope to call but I have parameters I'd like to pass with it and I don't think  I can pass a parameter with to a variabalized (word?) function. I know it's just me moving from ActionScript to Edge JavaScript and scope. Whereas I could always find a homebase in ActionScript with the stage, it seems that the stage in Edge is just another symbol and calling a function within the stage is never getting there. Elaine hints at putting outside the stage closure and it would be accessible, which, of course, has led me to start readying JavaScript books and learning more about scope etc. It seems like that is life as a developer. I  dont' get that, oh, better take a day or two to  understand that concept, oh, that function works now, next problem. ;-)

  • Few questions about sql2008 functions and commands

    hello,
    I am learning sql2008 implementation and maintenance,I am just 2 weeks bussy.there is some questions in my mind wich I can't answer it.
    1-when I can use  USE MASTER statement
    2-can a database for example (test) have many and unlimmited file groups?
    3-what is the diferrence between file and filegroup! is the term of file means  tables in filegroup?
    4-with boundary points does mean the data type when creating partition function!
    5`what is diferrence between full text index and index,where you have to use the index and wher you have to use full text index?
    6-each filegroup must have one partition or one partition can have many filegroups in partition scheme!
    7-do you have to partition every scheme or not! where do you have to partition a scheme and where not?
    8-can you give a little example with switch operator!
    9-again do you have to partition every table and index in the real world or not!
    thanks
    johan
    h.david

    Hi,
    Let me try to answer your questions:
    You need to use USE MASTER whenever you need to do some work in the MASTER database and the database context is not that.
    Yes, a database can have many filegroups. Please check this article:
    http://msdn.microsoft.com/en-us/library/ms179316.aspx
    Please check this article:
    http://msdn.microsoft.com/en-us/library/ms179316.aspx
    As per BOL:
    boundary_value is a constant expression that can reference variables. This includes user-defined type variables, or functions and user-defined functions. It cannot reference Transact-SQL expressions.
    boundary_value must either match or be implicitly convertible to the data type supplied in
    input_parameter_type, and cannot be truncated during implicit conversion in a way that the size and scale of the value does not match that of its corresponding
    input_parameter_type. For more details check
    http://msdn.microsoft.com/en-us/library/ms187802.aspx
    For simplicity: Full-Text index is used to search in a LOB/text data in a column, index is used to speed up your queries. Please check these articles:
    http://msdn.microsoft.com/en-us/library/ms142571.aspx,
    http://msdn.microsoft.com/en-us/library/ms189271.aspx
    As per BOL: When you create a partition scheme, you define the filegroups where the table partitions are mapped, based on the parameters of the partition function. You must specify enough filegroups to hold the number of partitions. You can specify that
    all partitions map to a different filegroup, that some partitions map to a single filegroup, or that all partitions map to a single filegroup. You can also specify additional, "unassigned" filegroups in the event you want to add more partitions later. For
    more info, please check
    http://msdn.microsoft.com/en-us/library/ms188730.aspx
    8. Please read the concept of partitioning here:
    http://msdn.microsoft.com/en-us/library/ms190199.aspx and for SWITCH operator, please check the sliding window example at here:
    http://msdn.microsoft.com/en-us/library/aa964122(SQL.90).aspx
    9. It depends :) but you always will have at least 1 partition!
    I hope it helps.
    J.
    There are 10 type of people. Those who understand binary and those who do not.

  • Question about Table Function inside a Package

    Hi … I am new in PL/SQL, I am trying to use a table function to create depending on a value passed to it (I am using 10g). Everything works great but the moment I add a parameter everything explode, I am creating it on a package.
    SQL that work
    CREATE OR REPLACE PACKAGE BODY financial_reports AS
    FUNCTION Fund_Amount
    RETURN financial_reports.Fund_Amount_Table
    pipelined parallel_enable IS
    cur_row financial_reports.Fund_Amount_Record;
    BEGIN
    FOR cur_row IN
    SELECT
    to_number(substr(bu5.usrdata, 1, 1)) As SECTION_ID
    ,to_number(substr(bu5.usrdata, 2, 1)) As SUB_SECTION_ID
    ,to_number(substr(bu5.usrdata, 4, 2)) AS LINE_NUMBER
    ,to_number(substr(bu5.usrdata, 7, 2)) As FUND_ID
    ,sum(be.amt) AS AMOUNT
    FROM
    linc.budgetdb_usr5@stjohnsfp bu5
    JOIN linc.budgetdb_event@stjohnsfp be ON
    bu5.keyvalue = be.acctno
    WHERE
    bu5.keyvalue like '__-__-__-____-____-_____'
    AND bu5.usrdata like '__-__-__'
    AND bu5.fieldnum = 1
    AND bu5.ispecname = 'GLMST'
    AND to_number(substr(bu5.usrdata, 7, 2)) = 1
    GROUP BY
    bu5.usrdata
    ORDER BY
    bu5.usrdata
    LOOP
    PIPE ROW(cur_row);
    END LOOP;
    END Fund_Amount;
    END financial_reports;
    SQL that do not work …
    CREATE OR REPLACE PACKAGE BODY financial_reports AS
    FUNCTION Fund_Amount (Fund_Id IN NUMBER)
    RETURN financial_reports.Fund_Amount_Table
    pipelined parallel_enable IS
    cur_row financial_reports.Fund_Amount_Record;
    fund_id_int NUMBER;
    BEGIN
    fund_id_int := Fund_Id;
    FOR cur_row IN
    SELECT
    to_number(substr(bu5.usrdata, 1, 1)) As SECTION_ID
    ,to_number(substr(bu5.usrdata, 2, 1)) As SUB_SECTION_ID
    ,to_number(substr(bu5.usrdata, 4, 2)) AS LINE_NUMBER
    ,to_number(substr(bu5.usrdata, 7, 2)) As FUND_ID
    ,sum(be.amt) AS AMOUNT
    FROM
    linc.budgetdb_usr5@stjohnsfp bu5
    JOIN linc.budgetdb_event@stjohnsfp be ON
    bu5.keyvalue = be.acctno
    WHERE
    bu5.keyvalue like '__-__-__-____-____-_____'
    AND bu5.usrdata like '__-__-__'
    AND bu5.fieldnum = 1
    AND bu5.ispecname = 'GLMST'
    AND to_number(substr(bu5.usrdata, 7, 2)) = fund_id_int
    GROUP BY
    bu5.usrdata
    ORDER BY
    bu5.usrdata
    LOOP
    PIPE ROW(cur_row);
    END LOOP;
    END Fund_Amount;
    END financial_reports;
    Error … (This works without the parameter)
    Error starting at line 43 in command:
    select * from table(financial_reports.Fund_Amount(1) )
    Error at Command Line:1 Column:14
    Error report:
    SQL Error: ORA-22905: cannot access rows from a non-nested table item
    Any help would be greatly appreciated

    try renaming your parameter so as not to confuse with what you are using in your column " to_number(substr(bu5.usrdata, 7, 2)) AS FUND_ID":
    CREATE OR REPLACE PACKAGE BODY financial_reports AS
      FUNCTION Fund_Amount (pFund_Id IN NUMBER)
        RETURN financial_reports.Fund_Amount_Table
        pipelined parallel_enable IS
        cur_row financial_reports.Fund_Amount_Record;
        fund_id_int NUMBER;
      BEGIN
        fund_id_int := pFund_Id;
        FOR cur_row IN ( SELECT to_number(substr(bu5.usrdata, 1, 1)) As SECTION_ID,
                                to_number(substr(bu5.usrdata, 2, 1)) As SUB_SECTION_ID,
                                to_number(substr(bu5.usrdata, 4, 2)) AS LINE_NUMBER,
                                to_number(substr(bu5.usrdata, 7, 2)) As FUND_ID,
                                sum(be.amt) AS AMOUNT
                           FROM linc.budgetdb_usr5@stjohnsfp bu5
                                  JOIN linc.budgetdb_event@stjohnsfp be ON bu5.keyvalue = be.acctno
                          WHERE bu5.keyvalue like '__-__-__-____-____-_____'
                            AND bu5.usrdata like '__-__-__'
                            AND bu5.fieldnum = 1
                            AND bu5.ispecname = 'GLMST'
                            AND to_number(substr(bu5.usrdata, 7, 2)) = fund_id_int
                         GROUP BY bu5.usrdata
                         ORDER BY bu5.usrdata ) LOOP
          PIPE ROW(cur_row);
        END LOOP;
      END Fund_Amount;
    END financial_reports;

  • Question about random function

    Is there a way to get 6 random numbers that not the same? I need this because I'm making a lottery from numbers 1-20. I need to make sure I don't get duplicate numbers. Will I need to make a nested loop statement? Thx for whoever answers my questions.

    Two things:
    1) That's a very bad attitude on your prof's part, I think: "use what you know". First, on general principles, he should encourage students to learn new things to solve problems. But more importantly, part of the everyday work of being a programmer (both in industry and academia) is doing research, learning how to solve a problem, and applying what you've learned. If you can't look in the API to see what it offers and try to use what it offers, then you're no good as a programmer.
    2) My guess is that he's thinking the two loops will be:
    outer loop: until you have found 6 numbers, keep trying to find new random ones, which means
         selecting a random number and then:
    inner loop: look through the existing list of selected random numbers; if you don't find the one you
         selected above add it to the end of the list; otherwise break this loop and go on to do another
         iteration of the outer loop.But who knows what he's thinking of? I hate it when the assignment is "read the teacher's mind." You also get a lot of this on job interviews: the interviewer asks a question that actually has several perfectly good responses, but you have to choose the one he likes best, because in fact the interviewer (often the "technical guy" at the business who isn't talented enough to be too busy to interview) isn't as smart as he thinks he is and only knows part of the answer.
    Anyway, see where the above takes you. If I told you any more it would be cheating.

  • Considering Purchase of Wacom Cintiq 27 HD Touch - Questions about Touch Functionality in Lightroom 5 & Photoshop CS6

    I am considering purchase of a Wacom Cintiq 27 HD Touch monitor. I have a few questions relative to two Adobe programs and their use of "touch" functionality - Lightroom 5.7 and Photoshop CS6 running on Windows 7.
    1. Have the problems related to touch functionality in Photoshop CS6 and Lightroom 5 been resolved that you see on this and Wacom's forums from a year ago?
    2. If so, is there enough value gained via touch functionality in Lightroom 5 and Photoshop CS6 to warrant the $500 difference in price between the Cintiq 27 HD vs HD Touch? (I realize that this is a subjective question based on the abundance of one's cash.)
    3. I plan to stay with CS6 as long as humanly possible to avoid a monthly software subscription, BUT I do wonder if purchasing the HD Touch now may provide additional touch functionality in future versions of these software products that are not currently available. (So this is a pie in the sky sort of question.)
    Thanks,
    Kent

    Photoshop Touch support is added in CC 2014.2.2.  However Wacom tablets like the Intuos Pro with touch can be use with prior versions of Photoshop and the Wacom Tablets Configurator can customized the tablets touch features to be used with Photoshop.  I do not use LR but I'm sure the same would be true for it. You can configure setting for many applications. The device driver knows which application its interfacing with and uses the setting set for each..
    I disable most of touch when using Photoshop.  The Main reason I have a tablet is Photoshop Brush type tools. Like eraser, clone stamp, etc nothing is better then a pen when it come to creating layer mask.  For most programs I still use a mouse and I use the Keyboard, Mouse and Pen with Photoshop....
    I never wanted a Cintig I like not having my hand  between my eyes and work. I not an artist though.

  • DML question about LAG function

    Hello,
    I am trying to get a month-to-date number on a value that is stored as YTD in the cube. That is, for today's month-to-date number, I want to subtract today's value, from last month's value. I am trying to do this with the following statement:
    data - lag(chgdims(data limit lmt(time to parents using time_parentrel)),1,time)
    I'm pretty new to DML, but I know that this is clearly not the correct formula. Does anyone have any ideas on how to do this?
    Thanks

    Dear Fred-san
    Thank you very much for your support on this.
    But, may I double check about what you mentioned above?
    So, what you were mentioning was that if some user executes the query with
    the function module (RFC_READ_TABLE), under the following conditions, he can access to
    the HR data even when he does not have the authorizations for HR transactions?
    <Conditions>
    1. the user has the authorization for HR database tables themselves
    2. RFC_READ_TABLE is called to retrieve the data from HR database
    <example>
    Data: LF_HR_TABLE like  DD02L-TABNAME value 'PA0000'.
    CALL FUNCTION 'RFC_READ_TABLE'
       EXPORTING
        query_table                = LF_HR_TABLE
      TABLES
       OPTIONS                    =
       fields                     =
       data                       =    .
    But then, as long as we call this function module for a non-critical tables such as
    VBAP (sales order) or EKKO (purchase order) within our query, it wouldn't seem to be
    so security risk to use RFC_READ_TABLE...
    Besides, each query (infoset query) has got the concept of user groups, which limits
    the access to the queries within the user group.
    ※If someone does not belong to the user group, he cannot execute the queries within that
       user group, etc
    So, my feeling is that even infoset queries does have authorization concept...
    Would you give me your thought on this?
    I also thank you for your information for SCU0.
    That is an interesting transaction
    Kind regards,
    Takashi

  • Question about Export functions

    hi,
    i'm considering getting into STP but would like to know about its export functions especially when it comes to interchange projects with other DAWs in particular Pro Tools.
    What exactly are the import / export options?
    ie: OMF, AAF, AES31, etc...
    ideally i would want to do sound editing (for film work) in STP, then transfer the edit session to Pro Tools for the mix stage.
    thanks, manioca
    MacBook Pro   Mac OS X (10.4.6)  

    If your talking about Pro Tools HD, then who gives a **** about a simple program like this one! Don't waste peoples time who don't have spare change for plugins that actually work after paying for that kind of a system. Real players know that PTHD won't hold a candle to either profesional live or studio sets and little programs like Logic and Soundtrack pro are only the backup of the process. Soundtrack Pro is particularly suited for the finished project, going backwards from it is stupid beyond words.
    [and if you don't have PTHD then you're really lost in space here, this forum is for Soundtrack Pro.]
    PMacG5 2.Ghz iBookg4 1.42   Mac OS X (10.4.7)   2.5mem Singin'ShureLynx16x M-AOzonicProKeys88Motu896ARTubesGolden FCS-Lp 7.2.☮

  • Using Multiple Subpaths - question about nested XML data

    Hello.
    I am in the process of getting my head around the nested XML data that is one layer deeper than I know how to handle - ultimately I would like to populate a Spry MenuBar from the static XML file.
    Updates & revisions to the menu would be done by simply uploading a new XML file to the server whenever something needs changed.
    The problem I am having is in regard to more than one subpath.
    I can successfully get the "Menuheading" and the "items" to show but the "subitems" that should attach to the "items" are nowhere to be found. Once this is figured out, I will begin building my menu.
    I'm not getting an XML error when testing in Safari (Mac OS 10.5.8)
    I thing my problem lies here in the head section of the page - obviously somewhere in the subPaths area:
    <script type="text/javascript">var dsItems1 = new Spry.Data.XMLDataSet("MenuXML.xml", "/menu/menuitem", { subPaths: [ "items/item", "subitem" ] });
    and here in the body section at subitem:
    <tr spry:repeat="dsItems1">
    <td>{@id}</td>
                <td>{menuheading}</td>
                <td>{items/item}</td>
                <td>{subitem}</td>
            </tr>
    ==================================================
    The end result I would like rendered in the menu is:
    ==================================================
    Menuheading
    ---- Item (hyperlink)
    ---- Item (hyperlink)
    ---- Item (hyperlink)
    ---- Item
           ------- sub submenu item (hyperlink)
    Menuheading
    ---- Item
           ------- sub submenu item (hyperlink)
           ------- sub submenu item (hyperlink)
           ------- sub submenu item (hyperlink)
    ---- Item (hyperlink)
    ---- Item (hyperlink)
    ---- Item (hyperlink)
    ...and so on.
    I have attached both files in their entirety at the bottom of the post in hopes someone can help.
    ==================================================
    Here is the relevant HTML
    ==================================================
    <head>
    <script language="JavaScript" type="text/javascript" src="includes/xpath.js"></script>
    <script language="JavaScript" type="text/javascript" src="includes/SpryData.js"></script>
    <script language="JavaScript" type="text/javascript" src="includes/SpryNestedXMLDataSet.js"></script>
    <script type="text/javascript">var dsItems1 = new Spry.Data.XMLDataSet("MenuXML.xml", "/menu/menuitem", { subPaths: [ "items/item", "subitem" ] });</script>
    </head>
    <body>
    <div spry:region="dsItems1">
    <table class="dataTable">
    <tr>
    <th width="62">Menu ID</th>
                <th width="171">Menu Heading</th>
                <th width="257">Menu Items</th>
                <th width="257">Submenu Items</th>
            </tr>
    <tr spry:repeat="dsItems1">
    <td>{@id}</td>
                <td>{menuheading}</td>
                <td>{items/item}</td>
                <td>{subitem}</td>
            </tr>
    </table>
    </div>
    </body>
    ==================================================
    A representative snippet of the XML is shown here:
    ==================================================
    <?xml version="1.0" encoding="UTF-8"?>
    <menu>
         <menuitem id="0001" type="Aboutus">
              <menuheading>About Us</menuheading>
                   <items>
                        <item id="0011">Welcome to MHBS</item>
                        <item id="0021">History</item>
                        <item id="0031">Mission</item>
                        <item id="0041">Accreditation</item>
                        <item id="0051">Directions</item>
                        <item id="0061">Calendar</item>
                        <item id="0071">Board of Directors</item>
                                     <subitem id="0111">Meet the Board</subitem>
                        <item id="0081">FAQs</item>
                   </items>
         </menuitem>
         <menuitem id="0002" type="Academics">
              <menuheading>Academics</menuheading>
                   <items>
                        <item id="0012">Meet the Faculty</item>
                        <item id="0022">Elementary</item>
                        <item id="0032">Middle School</item>
                        <item id="0042">High School</item>
                        <item id="0052">Academic Achievements</item>
                                     <subitem id="0251">Test Scores</subitem>
                                     <subitem id="0252">College Acceptance</subitem>
                        <item id="0062">Accelerated Reading</item>
                        <item id="0072">Summer Reading</item>
                        <item id="0082">Guidance and Counseling</item>
                   </items>
         </menuitem>
    ... and on and on ...
    </menu>
    Should I be doing something with the Spry.Data.NestedXMLDataSet instead?
    If so, how do I implement that?
    many thanks in advance

    Yes, you should be using the nested dataset instead.
    Did you read: http://labs.adobe.com/technologies/spry/samples/data_region/NestedXMLDataSample.html ?

  • Question about nested classes

    Hi, i currently have the following problem:
    I have 2 classes, one of which also has a nested class:
    1. Home.java (extends JApplet)
    2. Away.java (extends JPanel) has nested class, private class ButtonListener implements ActionListener
    Now in Home.java I have a Vector ( called bankaccount) which i pass to the Constructor of Away.java ( I declared the vector again there as an instance by Private Vector bankaccount;).
    My problem is that in ButtonListener I am trying to access the Vector so that i can modify it when a button has been clicked, and i thought i could just use the commands of bankaccount.add() and bankaccount.get() directly, however it seems like ButtonListener cannot access the Vector, even though i passed it along to the Constructor of the Away class.
    Any suggestions on how i get access the Vector from the ButtonListenere class?

    This is an example:
    public class Home extends JApplet
    private Away away;
    private Vector bankaccount;
    public void init()
         bankaccount = new Vector();
         away = new Away(bankaccount);
    public class Away extends JPanel
    private Vector bankaccount;
    JTextArea text1= new JTextArea(50,50);
    public Away(Vector bankaccount)
       //declare buttons,textarea,setLayout,etc
    button1.addActionListener (new ButtonListener());
    //i can set  text1.setText(( String)bankaccount.get(0));
    // here to access bankaccount, and it shows up fine, but i want
    // do it in from the class below
    private class ButtonListener implements ActionListener
              public void actionPerformed(ActionEvent event)
                         //trying to access bankaccount here by doing:
                        // but it is not doing anything
                        text1.setText(( String)bankaccount.get(0));
    }

Maybe you are looking for

  • UCS B-Series / FC 6120 / MDS 9513: Setting up FI and B-Series in UCSM

    We are receiving FC SAN connections from an MDS 9513 we do not own, within the same physical building. We have been given a range of WWNN and WWPN to create pools in UCSM. I am not a storage manager, nor much of a systems manager, but I know there ar

  • Catalyst: Mouse Pointer looks weird on one monitor

    Hi, i just installed a fresh Arch system (2.6.35-ARCH) and I'm using Xorg (1.9.0) together with the AUR-package "catalyst-test". Now when i start up a desktop environment (i tryd twm and openbox), my mouse pointer looks weird on my right monitor but

  • Querying value from a range of two values

    I have patched together a shopping cart, operating on CF8,  and am now trying to add shipping.  The client wants the shipping charges based on the cost of item, ie: 0-$499 is $20 $500 – $999 is $25.00 $999 – up $45 I built an access table (simplified

  • Viewing Subcomponent in Sales Order

    Hi All, I created a sales order with main component which is maintained in BOM. I want to view the subcomponents for the main product in that sales order. Anyway when I look at structure tab in sales order item level, I couldn't see anything. I have

  • Menu's not saving in Encore when I edit them in Photoshop

    When I use the 'edit menu in Photoshop' feature and make changes to a menu it doesn't show the changes in Encore. What's up with that?