Need a help on this scenario

Hi,
Scenario: monthly data needs to be divided into weekly data acording to the number of weeks in that month.
eg: create table Sdata ( joindate DATE, members number(8));
Insert into Sdata (joindate,members)values ('28-apr-11',8);
Joindate Members
28-apr-11 8
I need the output as weekly wise (equally dividing the members according to the number of weeks in that month). Joindate will be the start date of the week.
Joindate Members
04-apr-11 2
11-apr-11 2
18-apr-11 2
25-apr-11 2
Can someone help me on this.
Thanks
Padma

Hi, Padma,
Padu wrote:
Scenario: monthly data needs to be divided into weekly data acording to the number of weeks in that month.
eg: create table Sdata ( joindate DATE, members number(8));
Insert into Sdata (joindate,members)values ('28-apr-11',8);
Joindate Members
28-apr-11 8
I need the output as weekly wise (equally dividing the members according to the number of weeks in that month). Joindate will be the start date of the week.
Joindate Members
04-apr-11 2
11-apr-11 2
18-apr-11 2
25-apr-11 2Sorry, I don't understand.
Post a little sample data (CREATE TABLE and INSERT statements, relevant columns only) from all tables.
Also post the results you want from that data, and an explanation of how you get those results from that data, with specific examples.
Always say which version of Oracle you're using.
Do your weeks always begin on Monday? If so
TRUNC (dt, 'IW')will map all dts in the same week to the first point in that week.
For example
SELECT  TRUNC ( DATE '2011-04-28'
              , 'IW'
FROM    dual;produces April 25, 2011 (00:00:00), which is the last Monday on or before the given DATE.

Similar Messages

  • Ok i have indesign CS6 and all files are stored on a 10.7.5 MAC server.  This just started happening.  When I open a file indesigns is creating a textfile in the same folder?  I need some help on this.

    Ok i have indesign CS6 and all files are stored on a 10.7.5 MAC server.  This just started happening.  When I open a file indesigns is creating a textfile in the same folder?  I need some help on this.

    Ask in the ID forum and be much more specific about your configuration. there could be any number of reasons why manifests, temp files or restore files are created.
    Mylenium

  • Need to do a remote wipe of my iphone - stolen 24 hrs ago and . Need urgent help on this. Thanks - Pinaki

    Need to do a remote wipe of my iphone - stolen 24 hrs ago  Need urgent help on this. Thanks - Pinaki
    < Personal Information Edited By Host >

    Follow the steps in this article:
    iCloud: Erase your device
    Sign in to icloud.com/#find with your Apple ID (the one you use with iCloud), then click Find My iPhone.If you’re using another iCloud app, click the app’s name at the top of the iCloud.com window, then click Find My iPhone.If you don’t see Find My iPhone on iCloud.com, your account just has access to iCloud web-only features. To gain access to other iCloud features, set up iCloud on your iOS device or Mac.
    Click All Devices, then select the device you want to erase.If you have Family Sharing set up, your family members’ devices appear below their names.
    In the device’s Info window, click Erase [device].
    To erase:
    An iOS device: Enter your Apple ID password. If the device you’re erasing has iOS 7 or later, enter a phone number and message. The number and message will be displayed on the screen after the device is erased.

  • Error 1603: Need some help with this one

    When installing iTunes I first get an error box saying
    "Error 1406: Could not write value to key \Software\classes\.cdda\OpenWithList\iTunes.exe. Verify that you have sufficient access to that key, or contact your support personnel."
    The second one (after I click on Ignore on the last box) I get it this one:
    "Error: -1603 Fatal error during installation.
    Consult Windows Installer Help (Msi.chm) or MSDN for more information"
    Strange thing is that I do have full access to my computer (or atleast in all other cases I have had since I am the only one with an account on it).
    I have done my best in trying to solve it myself but I'm running out of ideas. I have downloaded latest versions from the website and tried installing Quicktime separately. I have also tried removing Quicktime using add/or remove programs though I just I didn't dare to take full removal because it said something about system files.
    Anyway I really need some help with this, anyone got any ideas?
    Greets,
    Sixten
      Windows XP Pro  

    Do you know how to count backwards? Do you know how to construct a loop? Do you know what an autodecrementor is? Do you know how to use String length? Do you know Java arrays start with index 0 and run to length-1? Do you know you use length on arrays too? Do you know what System.out.println does?
    Show us what you have, there isn't anything here that isn't easily done the same as it would be on paper.

  • Need urgent help on this error "oracle.jbo.AttrValException: JBO-27019"

    This is regarding Print Quote eror.
    "oracle.jbo.AttrValException: JBO-27019"
    I am facing the above error .(I am new to OA Framework) whenever i tried to add a new column to the select query 'Comp_info' .
    My development has come to an Halt really :(
    The code is :
    <?xml version="1.0" encoding='windows-1252'?>
    <!DOCTYPE ViewObject SYSTEM "jbo_03_01.dtd">
    <!-- $Header: LinesVO.xml 115.3 2003/12/30 07:01:46 asetti noship $-->
    <ViewObject
    Name="LinesVO"
    BindingStyle="Oracle"
    CustomQuery="true"
    RowClass="oracle.apps.aso.print.server.LinesVORowImpl"
    ComponentClass="oracle.apps.aso.print.server.LinesVOImpl"
    MsgBundleClass="oracle.jbo.common.JboResourceBundle"
    FetchMode="FETCH_AS_NEEDED"
    Passivate="None"
    UseGlueCode="false" >
    <SQLQuery><![CDATA[
    SELECT
    qte.ui_line_number line_number
    ,qte.padded_concatenated_segments item_number
    ,qte.item_description item_description
    ,qte.uom_code Order_Quantity_Uom
    ,DECODE(qte.line_category_code, 'RETURN', qte.quantity*(-1), qte.quantity) Ordered_Quantity
    ,qte.line_category_code
    ,qte.service_ref_line_id
    ,UPPER(qte.service_ref_type_code) srv_ref_type_code
    ,DECODE(qte.line_category_code, 'RETURN', qte.line_list_price*(-1), qte.line_list_price) unit_list_price
    ,DECODE(qte.line_category_code, 'RETURN', qte.line_adjusted_amount*(-1), qte.line_adjusted_amount) line_adj_price
    ,DECODE(qte.line_category_code, 'RETURN', qte.line_quote_price*(-1), qte.line_quote_price) unit_selling_price
    ,DECODE(qte.line_category_code, 'RETURN', qte.extended_list_price*(-1), qte.extended_list_price) line_total_list_price
    ,DECODE(qte.line_category_code, 'RETURN', qte.extended_adjusted_amount*(-1), qte.extended_adjusted_amount) line_total_adj_amt
    ,DECODE(qte.line_category_code, 'RETURN', qte.extended_selling_price*(-1), qte.extended_selling_price) line_total
    ,line_number old_line_number
    ,to_char(qte.start_date_active,nvl(FND_PROFILE.VALUE('ICX_DATE_FORMAT_MASK'), 'DD-MON-RRRR')) start_date_active
    ,to_char(qte.end_date_active,nvl(FND_PROFILE.VALUE('ICX_DATE_FORMAT_MASK'), 'DD-MON-RRRR')) end_date_active
    ,qte.service_duration
    ,qte.service_period
    ,qte.item_type_code
    ,decode(qte.item_type_code, 'MDL', NVL(qte.complete_configuration_flag, 'N'), 'Z') Model_Status
    ,qte.quote_line_id qlid
    ,qte.quote_header_id
    ,DECODE(qte.line_category_code,
    'RETURN',
    (select qte.quantity * (nvl(sum(decode(apav.applied_flag,'Y',decode(apav.charge_type_code,NULL,0,apav.adjusted_amount),0) ), 0))
    FROM aso_price_adjustments_v apav
    where qte.quote_line_id = apav.quote_line_id )*(-1),
    (select qte.quantity * (nvl(sum(decode(apav.applied_flag,'Y',decode(apav.charge_type_code,NULL,0,apav.adjusted_amount),0) ), 0))
    FROM aso_price_adjustments_v apav
    where qte.quote_line_id = apav.quote_line_id )) line_charges
    ,DECODE(qte.line_category_code,
    'RETURN',
    (decode(qte.item_type_code,
    'MDL',
    decode (qte.config_header_id,
    NULL,
    qte.extended_selling_price,
    (select sum(QUOTE_LINES.LINE_QUOTE_PRICE * QUOTE_LINES.QUANTITY)
    from ASO_QUOTE_LINES_ALL QUOTE_LINES,
    ASO_QUOTE_LINE_DETAILS QUOTE_LINE_DETAILS
    where quote_line_details.config_header_id=qte.config_header_id
    and quote_line_details.quote_line_id =quote_lines.quote_line_id)),
    qte.extended_selling_price))*(-1),
    (decode(qte.item_type_code,
    'MDL',
    decode (qte.config_header_id,
    NULL,
    qte.extended_selling_price,
    (select sum(QUOTE_LINES.LINE_QUOTE_PRICE * QUOTE_LINES.QUANTITY)
    from ASO_QUOTE_LINES_ALL QUOTE_LINES,
    ASO_QUOTE_LINE_DETAILS QUOTE_LINE_DETAILS
    where quote_line_details.config_header_id=qte.config_header_id
    and quote_line_details.quote_line_id =quote_lines.quote_line_id)),
    qte.extended_selling_price))) model_total
    ,qte.attribute3 Comp_Info
    FROM
    aso_pvt_quote_lines_bali_v qte
    ]]></SQLQuery>
    <DesignTime>
    <Attr Name="_isCodegen" Value="true" />
    <Attr Name="_version" Value="9.0.3.11.21" />
    <Attr Name="_CodeGenFlagNew" Value="36" />
    </DesignTime>
    <ViewAttribute
    Name="LineNumber"
    IsQueriable="false"
    IsPersistent="false"
    Precision="4000"
    Type="java.lang.String"
    AliasName="UI_LINE_NUMBER"
    ColumnType="VARCHAR2"
    Expression="UI_LINE_NUMBER"
    SQLType="VARCHAR" >
    <DesignTime>
    <Attr Name="_DisplaySize" Value="4000" />
    </DesignTime>
    </ViewAttribute>
    <ViewAttribute
    Name="ItemNumber"
    IsQueriable="false"
    IsPersistent="false"
    Precision="30"
    Type="java.lang.String"
    AliasName="LINE_SEGMENT"
    ColumnType="VARCHAR2"
    Expression="LINE_SEGMENT"
    SQLType="VARCHAR" >
    <DesignTime>
    <Attr Name="_DisplaySize" Value="30" />
    </DesignTime>
    </ViewAttribute>
    <ViewAttribute
    Name="comp_product"
    IsQueriable="false"
    IsPersistent="false"
    Precision="30"
    Type="java.lang.String"
    AliasName="comp_product"
    ColumnType="VARCHAR2"
    Expression="comp_product"
    SQLType="VARCHAR" >
    <DesignTime>
    <Attr Name="_DisplaySize" Value="30" />
    </DesignTime>
    </ViewAttribute>
    <ViewAttribute
    Name="ItemDescription"
    IsQueriable="false"
    IsPersistent="false"
    Precision="240"
    Type="java.lang.String"
    AliasName="LINE_DESC"
    ColumnType="VARCHAR2"
    Expression="LINE_DESC"
    SQLType="VARCHAR" >
    <DesignTime>
    <Attr Name="_DisplaySize" Value="240" />
    </DesignTime>
    </ViewAttribute>
    <ViewAttribute
    Name="OrderQuantityUom"
    IsQueriable="false"
    IsPersistent="false"
    IsNotNull="true"
    Precision="3"
    Type="java.lang.String"
    AliasName="LINE_UOM_CODE"
    ColumnType="VARCHAR2"
    Expression="LINE_UOM_CODE"
    SQLType="VARCHAR" >
    <DesignTime>
    <Attr Name="_DisplaySize" Value="3" />
    </DesignTime>
    </ViewAttribute>
    <ViewAttribute
    Name="OrderedQuantity"
    IsQueriable="false"
    IsPersistent="false"
    IsNotNull="true"
    Precision="255"
    Type="oracle.jbo.domain.Number"
    AliasName="LINE_QTY"
    ColumnType="VARCHAR2"
    Expression="LINE_QTY"
    SQLType="NUMERIC" >
    <DesignTime>
    <Attr Name="_DisplaySize" Value="22" />
    </DesignTime>
    </ViewAttribute>
    <ViewAttribute
    Name="LineCategoryCode"
    IsQueriable="false"
    IsPersistent="false"
    Precision="30"
    Type="java.lang.String"
    AliasName="LINE_CATEGORY_CODE"
    ColumnType="VARCHAR2"
    Expression="LINE_CATEGORY_CODE"
    SQLType="VARCHAR" >
    <DesignTime>
    <Attr Name="_DisplaySize" Value="30" />
    </DesignTime>
    </ViewAttribute>
    <ViewAttribute
    Name="ServiceRefLineId"
    IsQueriable="false"
    IsPersistent="false"
    Type="oracle.jbo.domain.Number"
    AliasName="SERVICE_REF_LINE_ID"
    ColumnType="VARCHAR2"
    Expression="SERVICE_REF_LINE_ID"
    SQLType="NUMERIC" >
    <DesignTime>
    <Attr Name="_DisplaySize" Value="22" />
    </DesignTime>
    </ViewAttribute>
    <ViewAttribute
    Name="SrvRefTypeCode"
    IsQueriable="false"
    IsPersistent="false"
    Precision="30"
    Type="java.lang.String"
    AliasName="SRV_REF_TYPE_CODE"
    ColumnType="VARCHAR2"
    Expression="SRV_REF_TYPE_CODE"
    SQLType="VARCHAR" >
    <DesignTime>
    <Attr Name="_DisplaySize" Value="30" />
    </DesignTime>
    </ViewAttribute>
    <ViewAttribute
    Name="UnitListPrice"
    IsQueriable="false"
    IsPersistent="false"
    Precision="255"
    Type="oracle.jbo.domain.Number"
    AliasName="LINELIST_PRICE"
    ColumnType="VARCHAR2"
    Expression="LINELIST_PRICE"
    SQLType="NUMERIC" >
    <DesignTime>
    <Attr Name="_DisplaySize" Value="22" />
    </DesignTime>
    </ViewAttribute>
    <ViewAttribute
    Name="LineAdjPrice"
    IsQueriable="false"
    IsPersistent="false"
    Type="oracle.jbo.domain.Number"
    AliasName="LINE_ADJ_PRICE"
    ColumnType="VARCHAR2"
    Expression="LINE_ADJ_PRICE"
    SQLType="NUMERIC" >
    <DesignTime>
    <Attr Name="_DisplaySize" Value="22" />
    </DesignTime>
    </ViewAttribute>
    <ViewAttribute
    Name="UnitSellingPrice"
    IsQueriable="false"
    IsPersistent="false"
    Precision="255"
    Type="oracle.jbo.domain.Number"
    AliasName="LINE_NET_PRICE"
    ColumnType="VARCHAR2"
    Expression="LINE_NET_PRICE"
    SQLType="NUMERIC" >
    <DesignTime>
    <Attr Name="_DisplaySize" Value="22" />
    </DesignTime>
    </ViewAttribute>
    <ViewAttribute
    Name="LineTotalListPrice"
    IsQueriable="false"
    IsPersistent="false"
    Type="oracle.jbo.domain.Number"
    AliasName="LINE_TOTAL_LIST_PRICE"
    ColumnType="VARCHAR2"
    Expression="LINE_TOTAL_LIST_PRICE"
    SQLType="NUMERIC" >
    <DesignTime>
    <Attr Name="_DisplaySize" Value="22" />
    </DesignTime>
    </ViewAttribute>
    <ViewAttribute
    Name="LineTotalAdjAmt"
    IsQueriable="false"
    IsPersistent="false"
    Type="oracle.jbo.domain.Number"
    AliasName="LINE_TOTAL_ADJ_AMT"
    ColumnType="VARCHAR2"
    Expression="LINE_TOTAL_ADJ_AMT"
    SQLType="NUMERIC" >
    <DesignTime>
    <Attr Name="_DisplaySize" Value="22" />
    </DesignTime>
    </ViewAttribute>
    <ViewAttribute
    Name="LineTotal"
    IsQueriable="false"
    IsPersistent="false"
    Precision="255"
    Type="oracle.jbo.domain.Number"
    AliasName="LINE_TOTAL_NET_PRICE"
    ColumnType="VARCHAR2"
    Expression="LINE_TOTAL_NET_PRICE"
    SQLType="NUMERIC" >
    <DesignTime>
    <Attr Name="_DisplaySize" Value="22" />
    </DesignTime>
    </ViewAttribute>
    <ViewAttribute
    Name="OldLineNumber"
    IsQueriable="false"
    IsPersistent="false"
    Precision="255"
    Type="oracle.jbo.domain.Number"
    AliasName="LINE_NUMBER"
    ColumnType="VARCHAR2"
    Expression="LINE_NUMBER"
    SQLType="NUMERIC" >
    <DesignTime>
    <Attr Name="_DisplaySize" Value="22" />
    </DesignTime>
    </ViewAttribute>
    <ViewAttribute
    Name="StartDateActive"
    IsQueriable="false"
    IsPersistent="false"
    DiscrColumn="true"
    Precision="255"
    Type="java.lang.String"
    AliasName="START_DATE_ACTIVE"
    ColumnType="VARCHAR2"
    Expression="START_DATE_ACTIVE"
    SQLType="VARCHAR" >
    <DesignTime>
    <Attr Name="_DisplaySize" Value="7" />
    </DesignTime>
    </ViewAttribute>
    <ViewAttribute
    Name="EndDateActive"
    IsQueriable="false"
    IsPersistent="false"
    Precision="255"
    Type="java.lang.String"
    AliasName="END_DATE_ACTIVE"
    ColumnType="VARCHAR2"
    Expression="END_DATE_ACTIVE"
    SQLType="VARCHAR" >
    <DesignTime>
    <Attr Name="_DisplaySize" Value="7" />
    </DesignTime>
    </ViewAttribute>
    <ViewAttribute
    Name="ServiceDuration"
    IsQueriable="false"
    IsPersistent="false"
    Type="oracle.jbo.domain.Number"
    AliasName="SERVICE_DURATION"
    ColumnType="VARCHAR2"
    Expression="SERVICE_DURATION"
    SQLType="NUMERIC" >
    <DesignTime>
    <Attr Name="_DisplaySize" Value="22" />
    </DesignTime>
    </ViewAttribute>
    <ViewAttribute
    Name="ServicePeriod"
    IsQueriable="false"
    IsPersistent="false"
    Precision="3"
    Type="java.lang.String"
    AliasName="SERVICE_PERIOD"
    ColumnType="VARCHAR2"
    Expression="SERVICE_PERIOD"
    SQLType="VARCHAR" >
    <DesignTime>
    <Attr Name="_DisplaySize" Value="3" />
    </DesignTime>
    </ViewAttribute>
    <ViewAttribute
    Name="ItemTypeCode"
    IsQueriable="false"
    IsPersistent="false"
    Precision="30"
    Type="java.lang.String"
    AliasName="ITEM_TYPE_CODE"
    ColumnType="VARCHAR2"
    Expression="ITEM_TYPE_CODE"
    SQLType="VARCHAR" >
    <DesignTime>
    <Attr Name="_DisplaySize" Value="30" />
    </DesignTime>
    </ViewAttribute>
    <ViewAttribute
    Name="ModelStatus"
    IsUpdateable="false"
    IsQueriable="false"
    IsPersistent="false"
    Precision="1"
    Type="java.lang.String"
    ColumnType="VARCHAR2"
    Expression="ModelStatus"
    SQLType="VARCHAR" >
    </ViewAttribute>
    <ViewAttribute
    Name="Qlid"
    IsQueriable="false"
    IsPersistent="false"
    IsNotNull="true"
    Precision="1"
    Type="oracle.jbo.domain.Number"
    AliasName="QLID"
    ColumnType="VARCHAR2"
    Expression="QLID"
    SQLType="NUMERIC" >
    <DesignTime>
    <Attr Name="_DisplaySize" Value="22" />
    </DesignTime>
    </ViewAttribute>
    <ViewAttribute
    Name="QuoteHeaderId"
    IsQueriable="false"
    IsPersistent="false"
    IsNotNull="true"
    Type="oracle.jbo.domain.Number"
    AliasName="QUOTE_HEADER_ID"
    ColumnType="VARCHAR2"
    Expression="QUOTE_HEADER_ID"
    SQLType="NUMERIC" >
    <DesignTime>
    <Attr Name="_DisplaySize" Value="22" />
    </DesignTime>
    </ViewAttribute>
    <ViewAttribute
    Name="LineCharges"
    IsQueriable="false"
    IsPersistent="false"
    Precision="255"
    Type="oracle.jbo.domain.Number"
    AliasName="LINE_TOTAL_CHARGES"
    ColumnType="VARCHAR2"
    Expression="LINE_TOTAL_CHARGES"
    SQLType="NUMERIC" >
    <DesignTime>
    <Attr Name="_DisplaySize" Value="22" />
    </DesignTime>
    </ViewAttribute>
    <ViewAttribute
    Name="ModelTotal"
    IsQueriable="false"
    IsPersistent="false"
    Precision="255"
    Type="oracle.jbo.domain.Number"
    AliasName="MODEL_TOTAL"
    ColumnType="VARCHAR2"
    Expression="MODEL_TOTAL"
    SQLType="NUMERIC" >
    <DesignTime>
    <Attr Name="_DisplaySize" Value="22" />
    </DesignTime>
    </ViewAttribute>
    <ViewAttribute
    Name="Comp_Info"
    IsQueriable="false"
    IsPersistent="false"
    Precision="30"
    Type="java.lang.String"
    AliasName="Comp_Info"
    ColumnType="VARCHAR2"
    Expression="Comp_Info"
    SQLType="VARCHAR" >
    <DesignTime>
    <Attr Name="_DisplaySize" Value="30" />
    </DesignTime>
    </ViewAttribute>
    <ViewLinkAccessor
    Name="ServiceToOrderLineVO"
    ViewLink="oracle.apps.aso.print.server.ServiceToOrderLineVL"
    Type="oracle.jbo.RowIterator"
    IsUpdateable="false" >
    </ViewLinkAccessor>
    <ViewLinkAccessor
    Name="ServiceToInstBaseVO"
    ViewLink="oracle.apps.aso.print.server.ServiceToInstBaseVL"
    Type="oracle.jbo.RowIterator"
    IsUpdateable="false" >
    </ViewLinkAccessor>
    <ViewLinkAccessor
    Name="QuoteLineChargesVO"
    ViewLink="oracle.apps.aso.print.server.QuoteLineChargesVL"
    Type="oracle.jbo.RowIterator"
    IsUpdateable="false" >
    </ViewLinkAccessor>
    <ViewLinkAccessor
    Name="QuoteLineTaxesVO"
    ViewLink="oracle.apps.aso.print.server.QuoteLineTaxesVL"
    Type="oracle.jbo.RowIterator"
    IsUpdateable="false" >
    </ViewLinkAccessor>
    <ViewLinkAccessor
    Name="LineTemplateVO"
    ViewLink="oracle.apps.aso.print.server.LineTemplateVL"
    Type="oracle.jbo.RowIterator"
    IsUpdateable="false" >
    </ViewLinkAccessor>
    <ViewLinkAccessor
    Name="LineAttachmentVO"
    ViewLink="oracle.apps.aso.print.server.LineAttachmentVL"
    Type="oracle.jbo.RowIterator"
    IsUpdateable="false" >
    </ViewLinkAccessor>
    </ViewObject>
    It gives me an error as "oracle.jbo.AttrValException: JBO-27019: Get method for attribute "comp_info" in LinesVO_HeaderLinesVL_LinesVO could not be resolved.
    I have added the getter and setter as well in the RowImpl.java file but still its givn this error.
    I need to add many more columns after this error is solved.
    I tried all permutation n combination but all in vain.
    Any help on this would be highly appreciated.
    Thanks,
    Ajit

    Ajit,
    Writing getter/setter methods manually is not a good idea, when jdev provides u that facility. Moreover in ur case i m getting a feeling as if ur VO mappings are corrupted. Can u try one thing ,assuming this is a custom VO,Delete the VO from the project and delete all related files in myclasses and my projects.Recreate the VO with all the attributes and try if same error is coming.
    --Mukul                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • Hi All... Need ur help in this.

    Iam desiging pop-up window, where it takes text from one textfield and pastes into other.. here is the code.. im not able to finish the code of properly, as im vry new to java.. plz help on this. Thanks in advance..
    import javax.swing.*;
    import java.awt.*;
    import java.awt.event.*;
    public class MyPopUp extends JApplet implements ActionListener
         Component fSelectedComponent;
         JFrame frame;
         JPopupMenu popup;
         JMenuItem one,two,three;
         Container cp;
         MouseAdapter fAdapter;
         JTextField source,dest;
         public void init()
              JFrame frame = new JFrame("Popup Example");
         frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
              cp = getContentPane();
              source = new JTextField();
              dest = new JTextField();
              popup = new JPopupMenu();
              one = new JMenuItem("Add To ClipBoard");
              one.addActionListener(this);
              two = new JMenuItem("Confirm");
              two.addActionListener(this);
              three = new JMenuItem("Reset");
              three.addActionListener(this);
              popup.add(one);
              popup.add(two);
              popup.add(three);
              cp.add(source,BorderLayout.NORTH);
              cp.add(dest,BorderLayout.SOUTH);
         MouseListener mouseListener = new MouseAdapter() {
         private void showIfPopupTrigger(MouseEvent mouseEvent) {
         if (mouseEvent.isPopupTrigger()) {
         popup.show(mouseEvent.getComponent(),
                        mouseEvent.getX(),
                        mouseEvent.getY());
         public void mousePressed(MouseEvent mouseEvent) {
         showIfPopupTrigger(mouseEvent);
         public void mouseReleased(MouseEvent mouseEvent) {
         showIfPopupTrigger(mouseEvent);
         frame.addMouseListener (mouseListener);
         frame.setSize(350, 250);
         frame.setVisible(true);
         public void actionPerformed(ActionEvent me)
              if(me.getSource() == one)
                   dest.setText((source.getText()).toString());
                   source.setText("Clicked on Add to ClipBoard");
              if(me.getSource() == two)     {
                   dest.setText((source.getText()).toString());
                   source.setText("Confirm");
              if(me.getSource() == three)     {
                   dest.setText((source.getText()).toString());
                   source.setText("Reset");
    }

    What exactly are you trying to do here? didn't get it!!

  • Need help with this scenario....

    Hi, here I want the out amount to be calculated with the variable ranges..
    I attached the report output.
    I took doc.no and doc.date in column,
    restricted doc.date with current day ( date changed to  05.05.2006)
    2 variables as manual entry, 2 variables as customer exit.
    with those manual entry variables i calculated different dates for 2 customer exit variables using ABAP
    everything is going fine till here.
    when i drag amount in a selection n restrict it with range of customer exit variables in doc.date
    the output does not shows the value for the range
    its just show the output  for the particular date 
    dates
    05.05.2006
    05.04.2006
    i want the output to show the total sum of amount for 30 days (or the no. which user enters)

    Hi Praveen,
    i hope this is what your requirement(sample output as below):-
    Customer
    Amount(01.05.2006 - 05.05.2006)
    Amount(06.05.2006 - 10.05.2006)
    C1
    $100
    $500
    C2
    $200
    $700
    if so, can we do this way: on KF1, restrict the document date with user input variable 1
    and KF2 with user input variable 2.
    if user enters first user input variable as  01.05.2006 - 05.05.2006
    and the same way for the second one. in that case, no  need of further logic to determine the variable ranges.
    Let us know if this works?
    Regards,
    Sakthi.

  • Auto Loading on FDM - Need help with this scenario

    Okay, I just waNt to know if there is a better way to load data from FDM to HFM.
    We have txt files containing data for every month. For example, there 12 files for year 2007 (1 file per month) for one country and similarly we have data arranged in this manner for every country.
    Now, what we are doing is that we are taking every file (every month) and loading it one after the other doing the FDM process of import, validate, export and check. This process is taking too long because we have to load monthly data for every year AND for every country. Too many files to load.
    Now, how can batch loading solve this problem. Where is the script written on FDM to do this process. Currently, the files for importing (monthly files) are NOT located in Inbox but a different directory. Would copying all these files into Inbox make it any better?
    This could save our company enormous amount of time loading and so I would certainly appreciate a better work around?
    There must be a way by which these loading of every file can be automated. Let me know. I have no idea about the script that is used but is the script present on the FDM admin manual for batch loading what we have to copy paste? Thanks.
    -- Adi

    Adi,
    This is why I originally stated that more advanced scripting might be needed.
    If there is an error, it stops at the error. You can then either manually run a report or check the fish status inside of the FDM web interface. If you wanted something to automatically be done when an error is encounted, the more advance scripting is required.
    As for the invalid map, it would stop just as it would from the web interface. The BatchLoader assumes you have all your information correct and that loads will be sucessfull.
    There is a feature called 'AutoMapCorrect' that is explained in the Admin doc as well. It is used to push all non-mapped data to a particular value. You then would need more advanced scripting to either let you know it automapped values, or run batch reports manually. Then you would need to correct the 'pushed' mapping to actual values and reload the data (import, validated, export, check)
    Thank you.

  • Essbase Gurus this is the time to help for this scenario in securityfilters

    Hi Gurus,
    I have one scenario in ASO(11v) ,I have to create security filters for two users
    for eg:
    GEO Account  30000
    wen we drill down
    india turnover 10000
    paris turnover 100000
    UK turnover noacess
    I created "GEO","india","paris"
    this security filter is working fine for one user
    but i need second filter like below
    in total sumof aggregation it doesnt show that is diffrent for both users (UK turnoover dont show in upper level)
    Actually UK have the measure but we have to restrict that measure for some users
    like below
    for another user
    GEO Account 20000
    wen we drill down
    india turnover 10000
    paris turnover 100000
    UK turnover noacess
    i m struggling here I tried with different options but no use ,my client wnt this requirement ,plz ur help gr8forly Appriciated
    Thanks
    Edited by: user98631 on Dec 18, 2009 4:31 AM

    Its amazing how the same off the wall question pops up around the same time. There is another thread about this. A security filter alone will not get you want you want.
    The best solution I can offer is to create multiple rollups that give you what you want, and use metadata security to restrict the users from seeing the geo member. Have the filter only allow them to see their rollup.
    I guess in an out of the box solutions would be to have one cube with all the data then multiple cubes partitioned to the soruce cube with the data for specific rollups. Allow the users to only see the cube that has the rollup they need.

  • Need some help with this Design.  Not sure if it can be done.

    I am a full time RVer. I have a complex system installed in my RV. I am trying to share a wireless or use my AE to feed internet to the devices in my rack and allow my Apple TV to connect to my MBP over gigabit for streaming reasons.
    Is there a way to share my internet to the AE so that it will feed the 3 ports? Can I somehow connect to a hotspot and share that internet connection to the other devices on my network wired and wireless?? I am mainly concerned with getting internet to the ATV while connected to it via ethernet for the gigabit connection.
    It seems that I can connect the AE to a hotspot or WAP, but then I loose the ability to turn bridged mode off so that it will hand out DHCP ip addresses to the ethernet devices. I cannot extend any network unless the hotspot is using an apple device for its WAP. This is what apple told me when I was trying to extend my Linksys WAP4400N.
    Any ideas or advice here would be great. I am just stuck for a solution to what I want to accomplish.
    Thanks

    One possible solution....(if I understand correctly what you're trying to accomplish with what you have to work with) I'm assuming that the Linksys has no internet connection in the RV and isn't really needed in my idea below.....or do you have a satellite connection (or some other internet source besides a public wireless network?
    You could have your MBP join the wireless network, set up internet sharing (see OS X help) and share from airport to ethernet, connect an ethernet cable from MBP to WAN port on the Extreme, set the Extreme's connection sharing to "share a public IP", ignore the double NAT error (or you may be able to bridge it, I can't remember if the MBP will hand out several IPs but I think it will), and plug your Apple TV into a LAN port on the Extreme. Come to think about it, you really don't even need the Extreme unless you need other clients to connect, just plug the Apple TV into the MBP.
    hope it helps

  • Need a help with this max query

    select SEARCH_ID, SEARCH_KEYWORD, COUNT, ASSET_TYPE from RELEVANCY_TABLE
    where SEARCH_KEYWORD = 'search_keyword'
    and ASSET_TYPE is not null
    558
    search_keyword
    3
    desk
    559
    search_keyword
    7
    table
    I actually need to get the asset_type for which count is the maximum. In this case it should be 'table'. Any help?

    adfSonal wrote:
    Is there any other way? I have to write this query in Java. So I will prefer avoiding rank or such functions.
    Won't I get the desired result just using select, where, max, rownum clauses?
    What do you mean by "I have to write this query in Java"? Any ways the query will be run against a Oracle DB, correct?
    Any ways using ROWNUM
    select *
    from   (
            select search_id
            ,      search_keyword
            ,      count
            ,      asset_type
            from   relevancy_table
            where  search_keyword = 'search_keyword'
            and    asset_type is not null
            order
            by     count desc
    where  rownum = 1

  • I have set a new password today and i cant remember it cause the password i used to get access to my phone is a very hard one to remember i need som help cause this is the first time ever i have encounter

    if anybody can help i would appriecent it cause earlier this morning a deaf guy came across my phone and got access to it so i changed it a few times till i decided to create a hard password that nobody cant remember but since i was being a dumbasss for it i guess its my fault

    LOST PASSCODE
    You should be able to remove the passcode by restoring the device.
    Connect the device to the computer with which you normally sync and open iTunes.
    Note: If iTunes prompts you to enter the passcode, try another computer that you have synced with. Otherwise, go to "If you have never synced your device with iTunes", below.
    Right-click the device in the left column and select Back up.
    When the backup is complete, select Restore.
    When finished, restore from your most recent backup.
    Otherwise read this
    If that doesn’t work  you will need to perform a factory restore to remove it. Or read:
    Enter Wrong passcode
    http://support.apple.com/kb/ht1212

  • I NEED SERIOUS HELP WITH THIS, i cant even USE my ipod, whatsoever....

    I just got a new IPOD classic 80 GB for my birthday. I needed to update my itunes. Keep in mind, i had 7.3 before trying to update. So its downloaded, and as i start the process....not even 4 seconds in a screen comes up saying
    "Another Installation is in progress. You must complete that one before contuining this one" along with a screen saying "MsiExec.exe has encountered a problem...". i've restarted my computer, uninstalled my itunes thinking that may have been causing the problem. i have no idea what program i need to install or is in the process already! the only thing i think i possibly need to register my ipod. this has been happening for about 2 hours and i'd really like some advice in solving the issue.

    Registering your iPod just puts you in the Apple systems for tech support, etc. So it doesn't really change anything with your computer.
    What I'd recommend, though is to completely uninstall all the software and reinstall like in this article. But if that doesn't work, I find that installing through another user account can usually resolve the issue for me (since it actually installs systemwide instead of just user specific).
    I hope I was helpful,
    iTunes Helper.

  • Concentric Circles---I need some help on this one...

    I'm trying to figure out how to change the color of my concentric rings. Here is my code:
    import java.applet.*;
    import java.awt.*;
    public class SvnRings extends Applet {
    public void paint(Graphics g) {
    int RectLeft, RectTop, RectHeight, RectWidth;
    int AppletHeight = this.getSize().height;
    int AppletWidth = this.getSize().width;
    for (int i=8; i >= 0; i--) {
    if ((i % 2) == 0) g.setColor(Color.red);
    else g.setColor(Color.white);
    RectHeight = AppletHeight*i/8;
    RectWidth = AppletWidth*i/8;
    RectLeft = AppletWidth/2 - i*AppletWidth/16;
    RectTop = AppletHeight/2 - i*AppletHeight/16;
    g.fillOval(RectLeft, RectTop, RectWidth, RectHeight);
    Can anyone tell me what I am forgeting?

    Well, what colours do you want them to be?
    You could generate them randomly, based on a sequence or from an array. I'll do the latter 'cos it's easiest.
    // 9 colours (for the 9 rings)
    private Color[] colors = new Color[] {Color.RED, Color.ORANGE, Color.YELLOW, Color.GREEN, Color.BLUE, Color.CYAN, Color.PURPLE, Color.PINK, Color.WHITE};
    for(int idx = 8; idx >= 0; idx--) {
      g.setColor(colors[idx]);
    }If you want a mathematical approach then you've got to create a new color in each iteration of the loop based on the loop value.
    Hope this helps.

  • Need some help with this code.

    var myDoc = app.documents[0]
    var mySel = app.selection[0]
    var myStory = mySel.parentStory; // Now we are pointing to the entire story
    var myHolidayStyle1 = "Holiday-Header" // Header 'day of the week'
    var myHolidayStyle2 = "Holiday-Sub-Heading-Date" // Header 'month and day'
    var myHolidayStyle3 = "Holiday-Header-Body" // Lead Paragraph 'default paragraph style'
    if (mystory = "Monday" ) {
        paragraphs(0).appliedparagraphstyles = myHolidayStyle1;
    else if (mystory = "Tuesday") {
        mystory.paragraphs(0). appliedparagraphstyles = myHoldiayStyle1;
    else if (mystory = "Wednesday") {
        mystory.papragraph(0).appliedparagraphstyles = myHolidayStyle1;
    else if (mystory = "Thursday") {
        mystory.paragraphs(0).appliedparagraphstyles = myHolidayStyle1;
    else if (mystory = "Friday")  {
        mystory.paragraphs(0).appliedparagraphstyle = myHolidayStyle1;
    else if (mystory = "Saturday") {
        mystory.paragraphs(0).appliedparagrahstyles = myHolidayStyle1;
    else if (mystory = "Sunday") {
        mystory.paragraphs(0).appliedparagraphstyles = myHolidayStyle1;
    // it finds if in the selection of the month and day if they equal for example Decmeber 15 then applies the HolidaySub-Heading-Date
    if   (mystory = "December 15") {
        mystory. paragraphs(1).appliedparagraphstyles = myHolidayStyle2;
    else if (mystory = "December 15") {
        mystory. paragraphs(1).appliedparagraphstyles = myHolidayStyle2;
    else if (mystory = "December 16") {
        mystory. paragraphs(1).appliedparagraphstyles = myHolidayStyle2;
    else if (mystory = "December 17") {
        mystory. paragraphs(1).appliedparagraphstyles = myHolidayStyle2;
    else if (mystory = "December 18") {
        mystory. paragraphs(1).appliedparagraphstyles = myHolidayStyle2;
    else if (mystory = "December 19") {
        mystory. paragraphs(1).appliedparagraphstyles = myHolidayStyle2;
    else if (mystory = "December 20") {
        mystory. paragraphs(1).appliedparagraphstyles = myHolidayStyle2;
    else if (mystory = "December 21") {
        mystory. paragraphs(1).appliedparagraphstyles = myHolidayStyle2;
    else if (mystory = "December 22") {
        mystory. paragraphs(1).appliedparagraphstyles = myHolidayStyle2;
    else if (mystory = "December 23") {
        mystory. paragraphs(1).appliedparagraphstyles = myHolidayStyle2;
    else if (mystory = "December 24") {
        mystory. paragraphs(1).appliedparagraphstyles = myHolidayStyle2;
    else if (mystory = "December 25") {
        mystory. paragraphs(1).appliedparagraphstyles = myHolidayStyle2;
    // If text doesn't  equal Day of the week like Monday and doesn't equal month and date like Decmber 14
    // then the document loops into doing the the rest of the document in Holiday-Header-Body
    // not sure if this loop will stop once it reaches another day of the week and then repeat the above tasks again.
    if (mystory =!  [myHolidayStyle0], [myHolidayStyle1]) { // not sure if I did this IF selection not equal Holidaystyle 0 and style 1 then perform loop, correctly???
        for (loop=0; loop<myStory.paragraphs.length; loop++)
      myStory.paragraphs[loop].appliedParagraphStyle = myHolidayStyle3;
    =============================
    ==========================
    I'm getting a error saying Paragraph is not a function, but nor is mystory.paragraph(0) , so i'm just trying to figure out what synax goes before that.
    =============================
    The text that is bold is the prolbem i'm having. I just got  a Javascript bible on how to program in javascript. How would i make that function work. I'm sure its simple. I'm just hoping I have If some Then ({) command follow by what I want it to do is correct. And I'm understanding this. there is so many different syntax's to choose from, any help would be appreciated. I work for a Newspaper company, and Indesign CS3 Javascript coding is a bit diffrent from normal javascript.

    Okie, I'm making progress now. Because well it didnt crash, but then again, LOL the script didnt apply the paragraph styles when I selected the text!
    any suggestions?
    I'm also getting a weird error now with the loop, but I also dont think its working because maybe the myStyle and myStle1 aren't applying themselves correctly, in the first part of the script.
    this is the Error Message:
    Error Number : 30477
    Error String: Invalid value of set propert 'appliedParagraphStyle'. Expected ParagraphStyle or String, but Recieved nothing.
    Line: 110
    Source: myStory.paragraphs[loop].appliedParagraphStyle = myStyle3;
    //var myDoc = app.documents[0]
    var mySel = app.selection[0];
    var myStory = mySel.parentStory; // Now we are pointing to the entire story
    var myStyle = app.activeDocument.paragraphStyles.item ( "Holiday-Header" ) ;
    var myStyle1 = app.activeDocument.paragraphStyles.item ( "Holiday-Sub-Heading-Date" ) ;
    var myStyle3 = app.activeDocument.paragraphStyles.item ( "Holiday-Header-Body" ) ;
    if (myStory.contents == "Monday" ) {
        myStory.paragraphs.appliedParagraphStyle = myStyle;
    else if  (myStory.contents == "Tuesday") {
        myStory.paragraphs[0]. appliedParagraphStyle = myStyle;
    if  (myStory.contents == "Wednesday") {
        myStory.papragraph[0].appliedparagraphstyle = myStyle;
    else if (myStory.contents == "Thursday") {
        myStory.paragraphs[0].appliedparagraphstyle = myStyle;
    if  (myStory.contents == "Friday")  {
        myStory.paragraphs[0].appliedparagraphstyle = myStyle;
    else if (myStory.contents == "Saturday") {
        myStory.paragraphs[0].appliedparagrahstyle = myStyle;
    if  (myStory.contents == "Sunday") {
        myStory.paragraphs[0].appliedparagraphstyle = myStyle;
    // it finds if in the selection of the month and day if they equal for example Decmeber 15 then applies the HolidaySub-Heading-Date
    if   (myStory.contents == "December 2") {
        myStory. paragraphs[1].appliedparagraphstyle = myStyle1;
    else if (myStory.contents == "December 3") {
        myStory. paragraphs[1].appliedparagraphstyle = myStyle1;
    if   (myStory.contents == "December 4") {
        myStory. paragraphs[1].appliedparagraphstyle = myStyle1;
    else if (myStory.contents == "December 5") {
        myStory. paragraphs[1].appliedparagraphstyle = myStyle1;
    if   (myStory.contents == "December 6") {
        myStory. paragraphs[1].appliedparagraphstyle = myStyle1;
    else if (myStory.contents == "December 7") {
        myStory. paragraphs[1].appliedparagraphstyle = myStyle1;
    if   (myStory.contents == "December 8") {
        myStory. paragraphs[1].appliedparagraphstyle = myStyle1;
    else if (myStory.contents == "December 9") {
        myStory. paragraphs[1].appliedparagraphstyle = myStyle1;
    if   (myStory.contents == "December 10") {
        myStory. paragraphs[1].appliedparagraphstyle = myStyle1;
    else if (myStory.contents == "December 11") {
        myStory. paragraphs[1].appliedparagraphstyle = myStyle1;
    if   (myStory.contents == "December 12") {
        myStory. paragraphs[1].appliedparagraphstyle = myStyle1;
    else if (myStory.contents == "December 13") {
        myStory. paragraphs[1].appliedparagraphstyle = myStyle1;
    if   (myStory.contents == "December 14") {
        myStory. paragraphs[1].appliedparagraphstyle = myStyle1;
    else if (myStory.contents == "December 15") {
        myStory. paragraphs[1].appliedparagraphstyle = myStyle1;
    if  (myStory.contents == "December 16") {
        myStory. paragraphs[1].appliedparagraphstyle = myStyle1;
    else if (myStory.contents == "December 17") {
        myStory. paragraphs[1].appliedparagraphstyle = myStyle1;
    if  (myStory.contents == "December 18") {
        myStory. paragraphs[1].appliedparagraphstyle = myStyle1;
    else  if (myStory.contents == "December 19") {
        myStory. paragraphs[1].appliedparagraphstyle = myStyle1;
    if  (myStory.contents == "December 20") {
        myStory. paragraphs[1].appliedparagraphstyle = myStyle1;
    else if (myStory.contents == "December 21") {
        myStory. paragraphs[1].appliedparagraphstyle = myStyle1;
    if  (myStory.contents == "December 22") {
        myStory. paragraphs[1].appliedparagraphstyle = myStyle1;
    else if (myStory.contents == "December 23") {
        myStory. paragraphs[1].appliedparagraphstyle = myStyle1;
    if  (myStory.contents == "December 24") {
        myStory. paragraphs[1].appliedparagraphstyle = myStyle1;
    else if (myStory.contents == "December 25") {
        myStory. paragraphs[1].appliedparagraphstyle = myStyle1;
    // If text doesn't  equal Day of the week like Monday and doesn't equal month and date like Decmber 14
    // then the document loops into doing the the rest of the document in Holiday-Header-Body
    // not sure if this loop will stop once it reaches another day of the week and then repeat the above tasks again.
    // not sure if I did this IF selection not equal mystyle and mystyle1 then perform loop, is done correctly???
    if (myStory.contents !=  (myStyle && myStyle1)) {
       for (loop=0; loop<myStory.paragraphs.length; loop++)
      myStory.paragraphs[loop].appliedParagraphStyle = myStyle3;
        I'm truly grateful for the Support and Assistance everyone has been providing me, I'm learning, and I thank you all for your help.

Maybe you are looking for

  • Two response objects within one servlet...

    Heya guys, quite new to java and got stuck for the whole day on this. I need to combine two responses inside one servlet. One response retrieves picture from the database and it works fine. Another one retrieves text from database also works fine on

  • Hooking a 110v imacg5 to a 220v socket...

    I bought an ibook g4 and an imac g5 in mexico, where i live, but now im studying in Argentina, and these guys have 220v, and we have 110 in mexico and usa. i know i can hook my ibook with no problems, and i bought my imac a transformer but the thing

  • Sharing a DB connection

    Hi, I have created a Database connection for a single page in my site but now I need to use that same connection for other pages. When I open the page I want to use it on it is not listed in the Database tab of the Application panel. How can I share

  • Getting 5.1 from Fatal1ty with "Home Theater Cable"

    I have the "Home Theater Cable" but my reciever "Denon 205" only have 5.1 EXT.in so the "side left and the side right aren't pluged. When i test the different speakers, i hear sound from "center, FR, RR, FL and SW. But I dont hear anything from RL?Ca

  • Create directory-linked user in GW2014

    Hi, I want to create a directory-linked user or enable this link after the creation of an user. Didn't find a sample in sdk-doc. Somebody can help? Have test to create a simple user with json and xml. Works fine after support from Preston. https://fo