How to display a empty (non-existing) column and info in LAST row

Hello!
I´m trying to create the code that diplays all authors (author.name), empty COLUMN, NR_OF_BOOK_PER_AUTHOR.
I want the LAST ROW to display: (column1) the word 'Sum:', (column2) nr of authors, (column3) total sum of all books
Headache: How do I display the EMPTY column and how do I get the LAST ROW to display column1) 'Sum:', (column2) nr of authors, (column3) total sum of all books
It should look like this:
AUTHOR EMPTY NR_OF_BOOKS_PER_AUTHOR
I can list all authors and NR_OF_BOOKS_PER_AUTHOR using this code:
SELECT A.NAME, COUNT(B.ROWID)
FROM AUTHOR A, BOOK B
WHERE B.AUTHOR_ID = A.ID
GROUP BY A.NAME
ORDER BY COUNT(B.ROWID)
I can count the numbers of authors (should be displayed in last row column2) using:
SELECT COUNT(name)
FROM author
and I can list the total amount of books (should be displayed in last row column3) using:
SELECT COUNT(title)
FROM book
But I come up short with how to display the EMPTY column and the last row containing (column1) the word 'Sum:', (column2) nr of authors, (column3) total sum of all books
Any suggestions?
Best regards,
Daniel

I want the LAST ROW to display: (column1) the word 'Sum:', (column2) nr of authors, (column3) total sum of all booksHave a look at GROUP BY with CUBE or ROLLUP.
Cheers, APC

Similar Messages

  • How to display single dimension members in Columns and rows

    Item category on rows Item brand on columns, Different levels in the Item hierarchy , can it be presented as above in the pivot table ?
    I have Item dimension with the below hierarchy :
    Item
    |- All Items
    |-- CAT-Beauty Products
    | |-- SEG-Skin Care
    | |-- BD-Andes
    | -- CAT-Beverages
    | |-- SEG-Bottled Water
    | |--BD-Agua Vide
    | -- CAT-Grocery
    | |-- SEG-Meats
    | |- BD-Harris
    I need to display All 'CAT' elements in rows and all its children (SEG and BD elements) in columns in a pivot table.
    Could you please help me to form the MDX query to display the data in ADF Pivot table.
    Sample query that I used:
    SELECT
    {[Item].[CAT-Beauty Products].Siblings}
    ON COLUMNS,
    {[CAT-Beauty Products].members}
    ON ROWS
    FROM Vcp_Tu1.Supply
    This is giving the below error message:
    Statement Executed with Warnings.
    Repeated dimension [Item] in MDX Query
    Unexpected Essbase error 1200549
    Edited by: Swathi on Jun 7, 2011 11:42 PM

    Sorry you can't do that. as a work around you could create attribute dimensions for the parent and the could cposstab them, or split the dim into two dimensions

  • When trying to download yosemite it sais that i do not have enough memory. when i look at my memory use it shows that 111.00gb of space is used by movies but when i go th the movie folder it is empty. how can i remove the non existant movies.

    when trying to download yosemite it sais that i do not have enough memory. when i look at my memory use it shows that 111.00gb of space is used by movies but when i go th the movie folder it is empty. how can i remove the non existant movies.

    Freeing Up Space on The Hard Drive
      1. See Lion/Mountain Lion/Mavericks' Storage Display.
      2. You can remove data from your Home folder except for the /Home/Library/ folder.
      3. Visit The XLab FAQs and read the FAQ on freeing up space on your hard drive.
      4. Also see Freeing space on your Mac OS X startup disk.
      5. See Where did my Disk Space go?.
      6. See The Storage Display.
    You must Empty the Trash in order to recover the space they occupied on the hard drive.
    You should consider replacing the drive with a larger one. Check out OWC for drives, tutorials, and toolkits.
    Try using OmniDiskSweeper 1.8 or GrandPerspective to search your drive for large files and where they are located.
    You will need a minimum of 10-12 GBs of free space to install Yosemite, however, that is a bare minimum and should be at least twice that amount.

  • Displaying a non existent column from a Table.

    Hi
    I have an SQL Query that returns back a count of all the
    entities
    select count(*)'COUNTER',
    id_entity 'ENTITY'
    from  claim 
    where id_status = 'O'
    group by id_status,id_entity 
    order by id_entity ASC
    Output
    COUNTER ENTITY
    169     AGL
    6       DBC
    28      DELI would like to put a non existent column called 'Type' with a counter
    of 0,so that the output looks like :
    COUNTER ENTITY
    0       TYP
    169     AGL
    6       DBC
    28      DELIs this possible ? What do I need to change in my select clause
    for this?
    Please help

    monalalwani, do you mean something like this?
    you have -
    1 select count(*) as counter, deptno
    2 from emp
    3* group by deptno
    UT1 > /
    COUNTER DEPTNO
    5 10
    5 20
    6 30
    -- but want counter = 0 for dept 0
    UT1 > select count(*) as counter, deptno
    2 from emp
    3 group by deptno
    4 union
    5 select 0, 00
    6 from dual
    7 /
    COUNTER DEPTNO
    0 0
    5 10
    5 20
    6 30
    HTH -- Mark D Powell --

  • One can create an index on a non-existent column in a table

    I am using Oracle 10.2.0.3 on Windows 2003. I wanted to create an index on columnb of
    Tablea. When I use statement like:
    Create index index1 on tablea (‘columnb’) …
    Oracle created index: index1. However, when I looked tat the column in user_ind_columns it had some weird colculn like SYS_NCxxxx. For sometime, I had
    No idea what was going on. My index was not being used in queries at all. Then it dawned on me that I should not put single quotes around columnb. Once I removed quotes, things worked as expected.
    But why does Oracle allow index on a non-existent column?

    we cannot create the index on nonexistent column of table We can. Its called a function-based index. Here's how we do it.
    Also read Howard's reply, right above yours.
    SQL> desc t
    Name                                      Null?    Type
    OWNER                                     NOT NULL VARCHAR2(30)
    OBJECT_NAME                               NOT NULL VARCHAR2(30)
    SUBOBJECT_NAME                                     VARCHAR2(30)
    OBJECT_ID                                 NOT NULL NUMBER
    DATA_OBJECT_ID                                     NUMBER
    OBJECT_TYPE                                        VARCHAR2(19)
    CREATED                                   NOT NULL DATE
    LAST_DDL_TIME                             NOT NULL DATE
    TIMESTAMP                                          VARCHAR2(19)
    STATUS                                             VARCHAR2(7)
    TEMPORARY                                          VARCHAR2(1)
    GENERATED                                          VARCHAR2(1)
    SECONDARY                                          VARCHAR2(1)
    SQL> create index t_idx on t( substr(object_name, 1, 5));
    Index created.
    SQL> select column_name from user_ind_columns where index_name = 'T_IDX';
    COLUMN_NAME
    SYS_NC00014$
    SQL> select index_type from user_indexes where index_name = 'T_IDX';
    INDEX_TYPE
    FUNCTION-BASED NORMAL
    SQL>

  • How to display the value of a column in a chart at the top of each column

    How to display the value of each column in a chart at the top of each column?

    Like this?
    Done using chart Inspector.
    For details, see Chapter 7,  Creating Charts from Numerical Data in the Numbers '09 User Guide. The guide may be downloaded via the Help menu in Numbers.
    Regards,
    Barry

  • HT1420 How can I deauthorize a non-existant system. My hard drive died so I bought a new one, reinstalled the OS and iTunes but iTunes seems to think this is a new computer.

    How can I deauthorize a non-existant system. My hard drive died so I bought a new one, reinstalled the OS and iTunes but iTunes seems to think this is a new computer.

    Try deauthorizing the computer even if you haven't authorized it. If you've already authorized it, deauthorize it twice and then authorize it again.
    (67626)

  • UIX: How to display more items in 1 column on the same row

    Hi
    I have a uix table with a couple of columns.
    Now I want to display more elements in 1 column, but on the same row
    E.g.
    article | quantity <> | price
    The quantity column has also to buttons to increase/decrease the quantity. Something like:
    <column>
    <columnFormat displayGrid="true" cellNoWrapFormat="true" columnDataFormat="numberFormat"/>
    <columnHeader>
    <sortableHeader text="Quantity" required="yes"/>
    </columnHeader>
    <contents>
    <messageTextInput id="${ui:concat('PurchaseInvoiceLinesView3:Quantity:',uix.current.tableIndex)}" model="${ui:cond(uix.current.isNewRow,null,uix.current.PurchaseInvoiceLinesQuantity)}" text="${uix.current.PurchaseInvoiceLinesQuantity}" name="Quantity" promptAndAccessKey="Quantity" rows="1" maximumLength="6" columns="8">
    <onSubmitValidater>
    <decimal/>
    </onSubmitValidater>
    </messageTextInput>
    <button text="&lt;" onClick="..."/>
    <button text="&gt;" onClick="..."/>
    </contents>
    </column>
    But both buttons appear on a new line. Resulting in:
    [   1]
    <
    >
    The useSeperateRows attribute is by default false, so that should be ok. Any ideas to get the buttons on the same row?
    Regards.

    Hi,
         If all of your line items are getting displayed in different pages, to my knowledge, there may be two possibilities.
    1) May be the size of the main window can accomodate only one line item. If one item data fills up the window, then there wont' be any space for the next line item data to be accomodated in the same window in the same page, so, the system triggers the next page. Like-wise for each item data. If this is the case, increase the height of the main window to display items in same page.
    2) Check the driver program. Find the Write_form block, which is written inside an item loop. May be there is a Form-control Function module( Control_form with parameter 'NEW-PAGE' ) being called after the write_fom block, within the loop. If this is the case, remove the control_form FM section to make the data display in same page.
    Best Regards,
    Kumaar.S

  • AppleScript - Writing to non-existent directories, and non-existent files..

    All,
    AppleScript - Writing to non-existent directories, and non-existent files...
    Creating directories several levels deep on the fly.
    How do we write to a file that does not exist, buried deep down in a hierarchy of directories that don't exist either...
    In trying to do this I explored two options. One used AppleScript, assisted by UNIX, which was simplicity itself, the other one used only AppleScript and was considerably more complex, and slower.
    http://www.mac-specialist.com/r/asckdirs.html
    Hope these are useful,
    Best Regards,
    Bill Hernandez
    Plano, Texas

    Simplified code examples - lacking extensive error checking -
    UNIX example 001:
    set file_Name to "Sales Figures.txt" -- File to create.
    set file_Path to "2006 Sales:Forecast:Fruits:Flordia:Oranges:Large" -- Folder to create.
    set UNIXfilePath to (quoted form of (POSIX path of file_Path))
    try
    do shell script "mkdir -p " & UNIXfilePath -- Attempt to create a folde, and respective intermediary folder(s).
    end try
    try
    do shell script "touch " & UNIXfilePath & "/" & file_Name -- Attempt to create a blank file.
    end try
    UNIX example 002:
    set file_Name to "Sales Figures.txt" -- File to create.
    set file_Path to "2006 Sales:Forecast:Fruits:Flordia:Oranges:Large" -- Folder to create.
    try
    do shell script "mkdir -p " & (quoted form of (POSIX path of file_Path)) -- Attempt to create a folde, and respective intermediary folder(s).
    end try
    -- Create a file, and enter some text.
    set FREF to open for access file (file_Path & ":" & file_Name) with write permission
    write "Beispieltext" to FREF
    close access FREF
    AppleScript example:
    set file_Name to "Sales Figures.txt" -- File to create.
    set file_Path to "2006 Sales:Forecast:Fruits:Flordia:Oranges:Large" -- Folder to create.
    -- Obtain list of text items of 'file_Path'.
    set {oAStID, AppleScript's text item delimiters} to {AppleScript's text item delimiters, ":"}
    set filePathList to text items of file_Path
    set AppleScript's text item delimiters to oAStID
    tell application "Finder"
    set folder_Path to name of startup disk -- Obtain name of boot disk.
    repeat with i in filePathList -- Cycle through list.
    try
    make new folder at folder_Path with properties {name:i} -- create folder.
    set folder_Path to folder_Path & ":" & i -- Create new path for next new folder.
    end try
    end repeat
    end tell
    -- Create a file, and enter some text.
    set FREF to open for access file (folder_Path & ":" & file_Name) with write permission
    write "Beispieltext" to FREF
    close access FREF
      Mac OS X (10.4.4)  

  • How to display an image in an alv grid in each corresponding row?

    Hi,
    please tell me how to  display an image in an alv grid in each corresponding row, like;;
    tony            23   newyork      <image>
    Mkitharyan  63   washington  <image>
    NOT BY HOTSPOTS/URL.

    you can put image in each cell you want:
    data lo_cmp_usage type ref to if_wd_component_usage.
      lo_cmp_usage =   wd_this->wd_cpuse_alv( ).
      if lo_cmp_usage->has_active_component( ) is initial.
        lo_cmp_usage->create_component( ).
      endif.
      DATA lo_INTERFACECONTROLLER TYPE REF TO IWCI_SALV_WD_TABLE .
      lo_INTERFACECONTROLLER =   wd_this->wd_cpifc_alv( ).
        DATA lo_value TYPE ref to cl_salv_wd_config_table.
        lo_value = lo_interfacecontroller->get_model(    ).
    data col type ref to  CL_SALV_WD_COLUMN.
    col = lo_value->IF_SALV_WD_COLUMN_SETTINGS~GET_COLUMN( 'IMAGE' ).
    data image type ref to cl_salv_wd_uie_image.
    CREATE OBJECT image.
    image->SET_SOURCE_FIELDNAME( 'IMAGE' ).
    COL->SET_CELL_EDITOR( image  ).

  • How to display polygons both with line contour and filled interior?

    How to display polygons both with line contour and filled interior?
    Java3D 1.3, Java 1.4.1-rc

    Hi,
    I just started with Java3D last week.
    I assume you mean drawing polygons with outlines (wireframe) in one color and polygon face filling with another color. If so, I've got the same question! (I usually think of "contour" to refers to plotting surface intensity of independent data like temperature or elevation, but I don't think you mean this.)
    The only solution I've found so far is to make two shapes with the same geometry.
    Here's an example - an outlined and filled cube. I made it using a generalize class DualShape which is two shapes with the same geometry, but one filled and one as a line.
    It works, although I can't say I understand the setPolygonOffset(), knowing what value to set. Without the command, the depthbuffer can't consistently decide which should be in front between the fills and lines so it looks bad.
    I certainly think it would be nicer to do both internally, like:
    pa.setPolygonMode(pa.POLYGON_LINE || pa.POLYGON_FILL);
    And then have setFillColor and setLineColor for each.
    I don't know why they don't allow this - maybe OpenGL can't do it like this so Java3D follows.
    If anyone has any better ideas I'd like to hear about it.
    Tom Ruen
    class DualCube extends DualShape // cube with outline and fill colors
    public DualCube(float ax, float ay, float az, //cube lower corner
    float bx, float by, float bz, //cube upper corner
    float br, float bg, float bb, //border color
    float fr, float fg, float fb) //fill color
    setGeometry(new CubeGeometry(ax,ay,az,bx,by,bz),br,bg,bb,fr,fg,fb);
    class DualShape extends BranchGroup //general shape with outline and fill colors
    Appearance ap1,ap2;
    PolygonAttributes pa1,pa2;
    ColoringAttributes ca1,ca2;
    Shape3D s1,s2;
    public void setGeometry(Geometry geo, float br, float bg, float bb, float fr, float fg, float fb)
    //filled shape:
    addChild(s1=new Shape3D(geo, ap1=new Appearance()));
    ap1.setPolygonAttributes(pa1=new PolygonAttributes()); pa1.setPolygonMode(pa1.POLYGON_FILL);
    ap1.setColoringAttributes(ca1=new ColoringAttributes()); ca1.setColor(fr,fg,fb);
    //lined (wire) shape:
    addChild(s2=new Shape3D(geo, ap2=new Appearance()));
    ap2.setPolygonAttributes(pa2=new PolygonAttributes()); pa2.setPolygonMode(pa2.POLYGON_LINE);
    ap2.setColoringAttributes(ca2=new ColoringAttributes()); ca2.setColor(br,bg,bb);
    pa2.setPolygonOffset(-1000); //Uncertain what "float" value to use!
    class CubeGeometry extends IndexedQuadArray //cube geometry data
    private static final int[] faces =
    0,3,2,1,
    0,1,5,4,
    1,2,6,5,
    2,3,7,6,
    3,0,4,7,
    4,5,6,7
    private static float[] verts = new float[24];
    public CubeGeometry(float ax, float ay, float az, //lower limit
    float bx, float by, float bz) //upper limit
    super(8, IndexedQuadArray.COORDINATES , 24);
    int n;
    n=0; verts[n]=ax; verts[n+1]=ay; verts[n+2]=az;
    n=3; verts[n]=bx; verts[n+1]=ay; verts[n+2]=az;
    n=6; verts[n]=bx; verts[n+1]=by; verts[n+2]=az;
    n=9; verts[n]=ax; verts[n+1]=by; verts[n+2]=az;
    n=12; verts[n]=ax; verts[n+1]=ay; verts[n+2]=bz;
    n=15; verts[n]=bx; verts[n+1]=ay; verts[n+2]=bz;
    n=18; verts[n]=bx; verts[n+1]=by; verts[n+2]=bz;
    n=21; verts[n]=ax; verts[n+1]=by; verts[n+2]=bz;
    setCoordinates(0, verts);
    setCoordinateIndices(0, faces);

  • Web Service to Query with 21 Columns and up to 1000 Rows

    Hi Experts,
    I have a web service to a query that returns a table of 21 Columns and up to 1000 Rows.
    I would like to display this data in an UI element such List view / Spreadsheet table.
    When I am doing so, I have the following issues:
    1. With the Spreadsheet table I can't set the header of the columns to the name of the column in the query.
    2. with both elements I would like to have a paging capability which I am not sure if is even possible.
    3. With both elements I am not able to set the width of each column as I need, and also not able to define the correct formating (date / string....)
    Is it possible to have what I am looking for with these elements? Or there are other UI elements for it?
    Thanks in advanced,
    DoronS

    Hi Charles,
    Actually, I am using Xcelsius as you said, and wanted to use it also as I mentioned since in the Web Intelligence I could not find the way to have a good filtering mechanism.
    Meaning, there is an option to add filters based on the fields that are in the query. But you can only choose one value per filter filed. If I want filter the data with more than one value it is impossible. Furthermore, there is no way to use free text filtering.
    Do you know in what BO Tool I will be able to provide such filtering capabilities?
    DoronS

  • How to store data from textfile to vector and delete a selected row.

    Can someone teach me how to store data from textfile to vector and delete a selected row. And after deleting, i want to write the changes in my textfile.
    Do someone has an idea? :)

    nemesisjava wrote:
    Can someone teach me how to store data from textfile to vector and delete a selected row. And after deleting, i want to write the changes in my textfile.
    Do someone has an idea? :)What's the problem? What have you done so far? What failed?
    What you described should be pretty easy to do.

  • Extra monitor w/laptop in office, when out of office how do I prevent Firefox from displaying on the non-existant 2nd screen?

    When I am out of my office using my laptop, upon launching Firefox, it displays all of the tabs from the previous session on the non-existent extra monitor which is set up as a screen extention for when I am in my office. All of the other programs that I park on the extra monitor (Outlook for example) display on the laptop's screen when the extra monitor is not attached. Is this a bug? Or, must I not save my open tabs when exiting Firefox if I am going to use the laptop w/o the monitor?

    Thanks for your suggestion. I sort of came to that conclusion as I was typing the original question. However if there is anyone out there who has a solution that is not dependent on my remembering to do something before I exit Firefox, it will be welcomed.

  • How to display axis labels on both x and y-axis of a column chart

    hi,
     i have an urgent requirement of having axis labels on both x and y axis
    In x-axis i got it by sorting order also but in y-axis i'm unable to do
    i need in y-axis ,my column values are L1,L2,L3,----L10these shuold display in y-axis in sorting order and 0 in axis should remain as it is ..........how to take the interval ....? as of now i'm using Auto
    my y-axis values shud look like 0,L1,L2,L3,L4,----L10can anyone get perfect solution
    thanx in advance
    lucky

    Hi Lucky,
    Per my understanding that you want to display the values(Column1) like  "L1,L2,L3....L10" which comes from the "Series group" in the Y-Axis label and keep the row group in "Category group" to
    display in the x-axis and Numric column(1,2,3,4) in the "Value", right?
    Gernerally the lable display in the y-axis is automatically based on the value of the Numric column in the "Value" and it default is numbric labels.
    I have tested on my local environment and in your scenario, i suggest to hide the axis lable of the y-axis and create an tablix to only show the one column contains the values (L1,L2,L3,L3) to display in the place of the hidden y-axis label.
    Detais information about to design an new y-axis label ae below for your reference:
    Create an tablix to display only the row group of the "Column1" ( for the
    Column1 may have duplicate values, you can create parent row group for this column and hide the detail column by setting the "Column Visibility").
    Right click the y-axis to select the "Vertical Axis Properties" and select the "Labels" on the left pane to check the "Hide Axis labels"
    Select the Chart Area and in the properties set value of left=0 under the CustomPosition:
    Set the border style=None for both the Chart and Column1's row group
    Drag the tablix at the position near the hidden y-axis and set the size of both the chart and the tablix to make the value in the tablix row group(Column1) to be align with the y-axis label:
    Right click the "Chart legend" to delete or hide the legend
    If you still have any problem, please feel free to ask.
    Regards,
    Vicky Liu
    Vicky Liu
    TechNet Community Support

Maybe you are looking for

  • I can't save a picture to my camera roll from an email

    I emailed a picture from my MBP to myself then downloaded the email on my IPhone 4S. When I tried to open the picturethe only options I had were to email the pic, post to FB or Twitter or print it out. There used to be an option of saving th picture

  • Text in a Layer

    In a layer I have a number of lines of text, which is Indented Left. The layer fits exactly into the designed space, including its Right Vertical scroll. There is no Horizontal scroll. It's set to 'auto'. When I view the text in the Design window, it

  • Implementing Forms look and feel into oracle 10g

    hello, im using oracle 10.1.2.0.2 i've been trying to implement this look and feel project hours ago here are the steps that i followed: # Copy the corresponding JAR file to your /forms/java directory. [copied it to C:\DevSuiteHome_1\forms\java\ and

  • Project Analytic's and PO

    Hello Has anyone worked on creating a report using project cost and project commitment subject area? We have a requirement, where the user wants to see project costs, commitments and the associated invoice and purchase order numbers. This information

  • Employee photo upload issue

    Hello Experts, i am uploading a photo wih the help of abaper but problem is when i run t code OAC0 and create repository for that storage type should be type as R/3 database .but when I  am selecting it is not coming another option is comes HTTP CONT