Filters on columns

Hello,
I have the following problem:
For example:
When you have a time dimension and a product dimension and a fact table with quantity sold.
Now I want to build this report:
1st column: all products
2nd column: quantity sold (year || month = prompted) (for example: quantity sold in Oct 2007)
3rd column: quantity sold (year >= prompt) (for example: quantity sold since 2005)
Is this possible to build?
I can do this by selecting 2 times the quantity sold and then give them both a different case when expression. But then I have to give in hard coded the year and the months, but I want that the end user gets a prompt. Is it possible to build in a prompt in an expression? and is this the way to do it, or are there some other possibilities?

@Venkat,
Sorry, it doesn't work... when I push the button filter and choose the year from the left pane and choose "is prompted" then it does not generate any code, it generates: FILTER(expr USING ()). I don't think this is ok. Is this a bug perhaps?
@ChinoTauro,
I am working with OBIEE 10.1.3.3 indeed and there it is possible.
Go to edit formula in your column and there you must see the filter button.
If not you can try entering the following formula: FILTER(expr USING filter_expressions) for my example this means: FILTER(Fact.QuantitySold USING (TimeDimension.Year = '2007'))
Or when this doesn't work you always can make a case when statement
Like: CASE WHEN TimeDimension.Year = '2007' THEN Fact.QuantitySold END
(this is what I was doing in first place.
@All
Only unfortunately this doesn't work for prompts... does anyone know what the syntax must be to use a prompt?

Similar Messages

  • Filtering Multiple Columns at once....

    Hi All,
    I was wondering if anybody had a smart way of filtering multiple columns. I know you can use excel formulas (index, v and h lookup etc),  to achieve this but i need to improve performance and would like to reduce the formulas in my design
    Example
                        A                B            C             D                E        F
                    Income     Budget     Profit       Profit
    1 Area 1    100           50            10            5
    2 Area 2    150           25             3             1
    On the canvas I will have combox with the values Income and Profit and a scorecard component looking at columns E and F
    When a user selects Income, data in A and B moves to E and F
    When a suer selects Porfit, data in C and D mooves to E and F
    Any suggestions would be appreciated.....
    Bija

    HI Bija
    Try using Filtered Rows as insertion type... and also try using list box instead of combo box if you have space as we should always try to apply WYSIWYG principle and combo box is not very good
    hope this helps
    Regards,
    Waqas

  • Filterable="true" - no filters on columns

    hi,
    how can i return filter caps on top of each column of table.
    there have been during the creation of table, then it disappeared at some moment
    so that i can't return it noway
    ldev 11.1.2.3
    when i create a new table, all filtable fields are in place....
    <af:table value="#{bindings.DcaRegisterLinesV1.collectionModel}" var="row" width="1200"
    rows="#{bindings.DcaRegisterLinesV1.rangeSize}" binding="#{registerBean.tabLines }"
    emptyText="#{bindings.DcaRegisterLinesV1.viewable ? 'No data to display.' : 'Access Denied.'}"
    filterModel="#{bindings.DcaRegisterLinesV1Query.queryDescriptor}" rowSelection="single"
    queryListener="#{bindings.DcaRegisterLinesV1Query.processQuery}" filterVisible="true" varStatus="vs"
    partialTriggers="::cb3 ::cb5 ::cb7 ::cb8 ::cb9"
    fetchSize="#{bindings.DcaRegisterLinesV1.rangeSize}" rowBandingInterval="0" id="t2">
    <af:column headerText="#{bindings.DcaRegisterLinesV1.hints.AgreementNm.label}" id="c8" filterable="true" sortable="true"
    width="150">
    <!--af:outputText value="#{row.AgreementNm}" id="ot4"/-->
    <af:inputText value="#{row.bindings.AgreementNm.inputValue}" simple="true"
    required="#{bindings.DcaRegisterLinesV1.hints.AgreementNm.mandatory}"
    columns="#{bindings.DcaRegisterLinesV1.hints.AgreementNm.displayWidth}"
    maximumLength="#{bindings.DcaRegisterLinesV1.hints.AgreementNm.precision}"
    shortDesc="#{bindings.DcaRegisterLinesV1.hints.AgreementNm.tooltip}" id="it1">
    <f:validator binding="#{row.bindings.AgreementNm.validator}"/>
    </af:inputText>
    </af:column>

    Hi,
    the setting is on the columns. Easiest to undo the change is
    1. Select af:table in Structure Window
    2. Open Property Insoector
    3. Press pencil Icon on top of Property Inspector
    4. check the filter check box
    Frank

  • UWL configuration: trying to add filtering to columns

    Hi everybody,
      is it possible to add filters to the UWL which act dynamically? I can add filters in my xml configuration and these work fine on quite simple columns like currency for example. But I really like to add a filter in which users can enter an amount in a field and the workitems will be sorted accordingly.
    For example. When you click the Show Filters option on the right hand side of the screen, the portal will shown the filter option based on different ranges of dates. I'd like to add another option which makes it possible to filter on amount (or whatever attribute I choose).
    Anyone had the same problem?
    Kind regards
    Laurens

    Hi,
    As far as I know you can't define filters at runtime. You have to define the filter in the XML configuration file as explained in the [documentation|http://help.sap.com/saphelp_nw70ehp1/helpdata/en/c5/b76cf747544b02be90233522280da3/frameset.htm].
    Regards,
    Pierre

  • A MVC datatable with dropdown filtering per column search with pagination example?

    Hello All,
    Just starting out a big project with MVC 3 and I've been searching for a while for any step by step example of creatintg a dynamic/ajax datatable that has real time filtering of the result set via dropdowns for mvc?  Is there a ready made solution already
    available for the MVC framework?
    Thanks,

    Hello,
    Thank you for your post.
    Glad to see this issue has been resolved and thank you for sharing your solutions & experience here. It will be very beneficial for other community members who have similar questions.
    Your issue is out of support range of VS General Question forum which mainly discusses
    WPF & SL designer, Visual Studio Guidance Automation Toolkit, Developer Documentation and Help System
    and Visual Studio Editor.
    If you have issues about ASP.NET MVC app in the future, I suggest that you can consult your issue on ASP.NET forum:
    http://forums.asp.net/
     for better solution and support.
    Best regards,
    Amanda Zhu [MSFT]
    MSDN Community Support | Feedback to us
    Develop and promote your apps in Windows Store
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

  • Need Help on Filtering a column

    Hi below is my requirement.
    ColA ColB ColB
    In the above, both the column 2 and 3 are the same columns, but i need to filter the column 3 alone based on another column. Please help.

    Hi,
    Write a case statement on 3rd column ...
    case when table1.status = 'Complete' then value(2nd col) end
    or
    case when table1.status = 'Complete' then value(2nd col) else null end
    Updated Post
    Can you paste your code (case statement)
    case when table_name.status ='Complete' then table_name.value end
    or
    case when table_name.status ='Complete' then table_name.value else null end
    Cheers,
    Aravind
    Edited by: Aravind Addala on May 17, 2011 11:48 PM

  • Different filters to data in 2 different columns

    Oracle BI 11g
    Hi,
    I have 1 fact table Sales (ID, Date, VersionID, Count) and 2 dimension table - Calendar (Date, Year, Month, Week, Day, ...), Versions (ID, Name).
    I've created Time Hierarchy on table Calendar, so I can use AGO function. I made new logical column "Count (1 month ago)". It works correctly.
    Now I need create Analysis with columns: Month, Count, Count (1 month ago). BUT! In column "Count" I need to see only Budget version values, and in column "Count (1 month ago)" I need to see only Actual version values.
    I try to use filter for column "Count" - "Version is equal to Budget", but it works for all Analysis, but not for column "Count".
    How can I solve this problem?

    Hi,
    in column formula in the criteria tab we have filter option.This is useful for filtering that column only.
    syntax:
    Filter(measure using dimensioncolumn)

  • How to access sort direction and filter value of columns?  Can I catch the 'filtered' or 'sorted' event?

    We have some columns being added to a table.  We have set the sortProperty and the filterProperty on each of our columns.
    This allows us to both filter and sort.
    We want to be able to access the columns filter value and sort value after the fact.  Can we access the table and then the columns and then a columns properties to find these two items?  How can I access the sort direction and filter value of columns?
    We would also like to store the filter value and the sort direction, and re-apply them to the grid if they have been set in the past.  How can we dynamically set the filter value and sort direction of a column?
    Can I catch or view the 'filtered' or 'sorted' event?  We would like to look at the event that occurs when someone sorts or filters a column.  Where can I see this event or where can i tie into it, without overwriting the base function?

    Hey everyone,
    Just wanted to share how I implemented this:
    Attach a sort event handler to table - statusReportTable.attachSort(SortEventHandler);
    In this event handler, grab the sort order and sorted column name then set cookies with this info
    function SortEventHandler(eventData)
        var sortOrder = eventData.mParameters.sortOrder;
        var columnName = eventData.mParameters.column.mProperties.sortProperty;
        SetCookie(sortDirectionCookieName, sortOrder, tenYears);
        SetCookie(sortedColumnCookieName, columnName, tenYears);
    Added sortProperty and filterProperty to each column definition:
    sortProperty: "ColName", filterProperty: "ColName",
    When i fill the grid with data, i check my cookies to see if a value exists, and if so we apply this sort:
    function FindAndSortColumnByName(columnName, sortDirection (true or false))
        var columns = sap.ui.getCore().byId('statusReportTable').getColumns();
        var columnCount = columns.length;
        for(var i = 0; i < columnCount; i ++)
            if(columns[i].mProperties.sortProperty == columnName)
                columns[i].sort(sortDirection);

  • Filtering a Look up column on page load.

    I'm trying to filter a look up column using something like CAML to only show me a subset of the values in a list. Basically when the New or Edit Form loads I'd like to parse a value out of the URL (in my case the Document Set Name) and then filter a the
    look up. 
    To understand what I'm trying to do: The business requirement is to create a look up column to the same library we're working in that only shows documents within the current Document Set (very similar to a folder if your not familiar) as Options. 
    If anyone can think of an easier way to accomplish this or something similar please let me know. Otherwise if anyone has experience dynamically filtering look up columns, I'm curious to hear how you accomplished it. 
    Thanks.

    try these links:
    http://howididit-sharepoint.blogspot.in/2012/04/filtering-lookup-columns.html
    http://sharepoint-works.blogspot.in/2012/02/cascading-dropdown-or-filtered-values.html
    http://www.codeproject.com/Articles/203818/SharePoint-Filtering-Lookup-column-using-Java
    you can use cascading dropdown using spservice
    jquery.

  • How to Create a new column from two different result sets

    How to Create a new column from two different result sets, both the result set uses the different date dimensions.

    i got solutions for this is apply filters in column formula it self, based on the requirement.

  • Query Print Layout column sum in report footer

    Hi Experts,
    I am utilizing a query and created the layout via Query Print Layout. I am using sort and group functions which filters my column sums for a certain field conditions. My problem is that when I want to make a total column sum for all the repetitive footers' column sum, the system shows a message that only repetitive areas can be average/ sum.
    Is this the standard behaviour of the system? Or is this a limitation if we are using the print layout via Query print layout. Any workaround to get the final total for all pages column sum?
    Please advise.
    Thanks,
    Don

    hello
    Don
    what u want actually i dint understood as i now but u need colsum of ur repetitive fields or repetitive footer fields
    I).if u want repetitive footer all columns sum take the contact of those fields ex:(concat(F_a+F_B -
    )) so u can get ur total for repetitive footer fields
    II).if u want repetitive area lines colsum for every field u take as colsum with respect to the unique id of repetitive area fields
    regards
    Jenny

  • Numerous ALV Issues - Saved Initial View shows table with no columns

    Saved a personal View and made it initial. View was saved by Sorting and FIltering certain columns. When I retrive the view, it shows the tabke has no columns at all.
    This is in addition to the Problem in getting DropdownbyKey inside a ALV Table Cell in DropdownByKey inside ALV Table - Problem with Value set
    Regards,

    You have forgotten to set a cell variant. I had the same with setting a ProgressIndicator cell-editor to a table column as default editor. This causes the column to be hidden on the table while it did show up in the settings dialog. I removed the set_editor( lr_progressindicator) and created a cell variant instead with this lr_progressindicator. You then need to add this cell variant to your column. By default it will select the standard viewtext-cell-editor (which can only be textview and inputfield, like when you create a table yourself in a view), but if you use a cell variant, it will display the required cell editor if you set it (last line of the code).
    <b>In your case, replace lr_progressindicator by your ref_dropdownkey.</b>
      DATA: lr_column_settings    TYPE REF TO if_salv_wd_column_settings,
            lr_column             TYPE REF TO cl_salv_wd_column,
            lr_column_header      TYPE REF TO cl_salv_wd_column_header,
            lr_cellvar            TYPE REF TO cl_salv_wd_cv_standard,
            l_cellvar             TYPE string,
            lr_progress_indicator TYPE REF TO cl_salv_wd_uie_progr_indicator.
      lr_column_settings ?= wd_this->mr_table.
      lr_column = lr_column_settings->get_column( 'STATUSBAR' ).
      lr_column_header = lr_column->get_header( ).
      lr_column_header->set_text( 'Completed' ).
    CREATE OBJECT lr_cellvar.
      l_cellvar = 'CV_SB'.
      lr_cellvar->set_key( l_cellvar ).
      CREATE OBJECT lr_progress_indicator.
      lr_progress_indicator->set_percent_value_fieldname( 'STATUSBAR' ).
      lr_progress_indicator->set_tooltip( 'completed' ).
      lr_cellvar->set_editor( lr_progress_indicator ).
      lr_column->add_cell_variant( lr_cellvar ).
      lr_column->set_selected_cell_variant( l_cellvar ).
    I hope this will solve your issues.

  • How not to sort datagrid column on double click

    Hello,
    I am currently building an application containing a datagrid for data representation. I've created a custom datagridheader in order to add a input text for filtering the columns (see code below).
    My goal is to hide the textinput, and then show it on a double click on the header. So i would like to know how to avoid the sort of this column each time i double click.?
    <?xml version="1.0" encoding="utf-8"?>
    <s:GridItemRenderer xmlns:fx="http://ns.adobe.com/mxml/2009"
                        xmlns:s="library://ns.adobe.com/flex/spark"
                        xmlns:mx="library://ns.adobe.com/flex/mx" resize="onColumnResize(event)" clipAndEnableScrolling="true" doubleClick="managefilterField(event)">
        <fx:Declarations>
            <!--- The default value of the <code>sortIndicator</code> property.
            It must be an IFactory for an IVisualElement.       
            <p>This value is specified in a <code>fx:Declaration</code> block and can be overridden
            by a declaration with <code>id="defaultSortIndicator"</code>
            in an MXML subclass.</p>
            @langversion 3.0
            @playerversion Flash 10
            @playerversion AIR 2.0
            @productversion Flex 4.5
            -->
            <fx:Component id="defaultSortIndicator">
                <s:Path data="M 3.5 7.0 L 0.0 0.0 L 7.0 0.0 L 3.5 7.0" implements="spark.components.gridClasses.IGridVisualElement">
                    <fx:Script>
                        <![CDATA[
                            import spark.components.DataGrid;
                            import spark.components.Grid;
                             *  @private
                            public function prepareGridVisualElement(grid:Grid, rowIndex:int, columnIndex:int):void
                                const dataGrid:DataGrid = grid.dataGrid;
                                if (!dataGrid)
                                    return;
                                const color:uint = dataGrid.getStyle("symbolColor");
                                arrowFill1.color = color;
                                arrowFill2.color = color;
                        ]]>
                    </fx:Script>
                    <s:fill>
                        <s:RadialGradient rotation="90" focalPointRatio="1">   
                            <!--- @private -->
                            <s:GradientEntry id="arrowFill1" color="0" alpha="0.6" />
                            <!--- @private -->
                            <s:GradientEntry id="arrowFill2" color="0" alpha="0.8" />
                        </s:RadialGradient>
                    </s:fill>
                </s:Path>
            </fx:Component>
            <!--- Displays the renderer's label property, which is set to the column's <code>headerText</code>.
            It must be an instance of a <code>TextBase</code>, like <code>s:Label</code>.
            <p>This visual element is added to the <code>labelDisplayGroup</code> by the renderer's
            <code>prepare()</code> method.   Any size/location constraints specified by the labelDisplay
            define its location relative to the labelDisplayGroup.</p>
            <p>This value is specified with a <code>fx:Declaration</code> and can be overridden
            by a declaration with <code>id="labelDisplay"</code>
            in an MXML subclass.</p>
            @langversion 3.0
            @playerversion Flash 10
            @playerversion AIR 2.0
            @productversion Flex 4.5
            -->
            <s:Label id="labelDisplay"
                     verticalCenter="1" left="0" right="0" top="0" bottom="0"
                     textAlign="start"
                     fontWeight="bold"
                     verticalAlign="middle"
                     maxDisplayedLines="1"
                     showTruncationTip="true" />
        </fx:Declarations>
        <fx:Script>
            <![CDATA[
                import net.awl.ismp.console.components.misc.FilterCriteria;
                import net.awl.ismp.console.events.ColumnFilteredEvent;
                import net.awl.ismp.console.events.ColumnResizedEvent;
                import mx.events.ResizeEvent;
                import spark.components.gridClasses.IGridVisualElement;
                import mx.core.IVisualElement;
                import spark.components.DataGrid;
                import spark.components.GridColumnHeaderGroup;
                import spark.components.gridClasses.GridColumn;
                import spark.primitives.supportClasses.GraphicElement;
                // chrome color constants and variables
                private static const DEFAULT_COLOR_VALUE:uint = 0xCC;
                private static const DEFAULT_COLOR:uint = 0xCCCCCC;
                private static const DEFAULT_SYMBOL_COLOR:uint = 0x000000;
                private static var colorTransform:ColorTransform = new ColorTransform();
                 *  @private
                private function dispatchChangeEvent(type:String):void
                    if (hasEventListener(type))
                        dispatchEvent(new Event(type));                   
                protected function onColumnResize(event:ResizeEvent):void
                    dispatchEvent(new ColumnResizedEvent(ColumnResizedEvent.COLUMNRESIZED_EVT,this.width,this.column.columnInde x));
                //  maxDisplayedLines
                private var _maxDisplayedLines:int = 1;
                [Bindable("maxDisplayedLinesChanged")]
                [Inspectable(minValue="-1")]
                 *  The value of this property is used to initialize the
                 *  <code>maxDisplayedLines</code> property of this renderer's
                 *  <code>labelDisplay</code> element.
                 *  @copy spark.components.supportClasses.TextBase#maxDisplayedLines
                 *  @default 1
                 *  @langversion 3.0
                 *  @playerversion Flash 10
                 *  @playerversion AIR 1.5
                 *  @productversion Flex 4.5
                public function get maxDisplayedLines():int
                    return _maxDisplayedLines;
                override protected function stateChanged(oldState:String, newState:String, recursive:Boolean):void
                    trace("state changed from : "+oldState+" to "+newState);
                    super.stateChanged(oldState, newState, recursive);
                 *  @private
                public function set maxDisplayedLines(value:int):void
                    if (value == _maxDisplayedLines)
                        return;
                    _maxDisplayedLines = value;
                    if (labelDisplay)
                        labelDisplay.maxDisplayedLines = value;
                    invalidateSize();
                    invalidateDisplayList();
                    dispatchChangeEvent("maxDisplayedLinesChanged");
                //  sortIndicator
                private var _sortIndicator:IFactory;
                private var sortIndicatorInstance:IVisualElement;
                [Bindable("sortIndicatorChanged")]
                 *  A visual element that's displayed when the column is sorted.
                 *  <p>The sortIndicator visual element is added to the <code>sortIndicatorGroup</code>
                 *  by this renderer's <code>prepare()</code> method.  Any size/location constraints
                 *  specified by the sortIndicator define its location relative to the sortIndicatorGroup.</p>
                 *  @default null
                 *  @langversion 3.0
                 *  @playerversion Flash 10
                 *  @playerversion AIR 1.5
                 *  @productversion Flex 4.5
                public function get sortIndicator():IFactory
                    return (_sortIndicator) ? _sortIndicator : defaultSortIndicator;
                 *  @private
                public function set sortIndicator(value:IFactory):void
                    trace("setSortIndicator");
                    if (_sortIndicator == value)
                        return;
                    _sortIndicator = value;
                    if (sortIndicatorInstance)
                        sortIndicatorGroup.includeInLayout = false;
                        sortIndicatorGroup.removeElement(sortIndicatorInstance);
                        sortIndicatorInstance = null;
                    invalidateDisplayList();
                    dispatchChangeEvent("sortIndicatorChanged");
                 *  @private
                 *  Create and add the sortIndicator to the sortIndicatorGroup and the
                 *  labelDisplay into the labelDisplayGroup.
                override public function prepare(hasBeenRecycled:Boolean):void
                    trace("prepare !!");
                    super.prepare(hasBeenRecycled);
                    if (labelDisplay && labelDisplayGroup && (labelDisplay.parent != labelDisplayGroup))
                        labelDisplayGroup.removeAllElements();
                        labelDisplayGroup.addElement(labelDisplay);
                    trace(sortIndicator);
                    trace("sortIndicatorInstance : "+sortIndicatorInstance);
                    const column:GridColumn = this.column;
                    if (sortIndicator && column && column.grid && column.grid.dataGrid && column.grid.dataGrid.columnHeaderGroup)
                        const dataGrid:DataGrid = column.grid.dataGrid;
                        const columnHeaderGroup:GridColumnHeaderGroup = dataGrid.columnHeaderGroup;
                        if (columnHeaderGroup.isSortIndicatorVisible(column.columnIndex))
                            if (!sortIndicatorInstance)
                                sortIndicatorInstance = sortIndicator.newInstance();
                                sortIndicatorGroup.addElement(sortIndicatorInstance);
                                chromeColorChanged = true;
                                invalidateDisplayList();
                            // Initialize sortIndicator
                            sortIndicatorInstance.visible = true;
                            const gridVisualElement:IGridVisualElement = sortIndicatorInstance as IGridVisualElement;
                            if (gridVisualElement)
                                gridVisualElement.prepareGridVisualElement(column.grid, -1, column.columnIndex);
                            sortIndicatorGroup.includeInLayout = true;
                            sortIndicatorGroup.scaleY = (column.sortDescending) ? 1 : -1;
                        else
                            if (sortIndicatorInstance)
                                sortIndicatorGroup.removeElement(sortIndicatorInstance);
                                sortIndicatorGroup.includeInLayout = false;
                                sortIndicatorInstance = null;
                private var chromeColorChanged:Boolean = false;
                private var colorized:Boolean = false;
                 *  @private
                 *  Apply chromeColor style.
                override protected function updateDisplayList(unscaledWidth:Number, unscaledHeight:Number):void
                    //trace("update display list");
                    // Apply chrome color
                    if (chromeColorChanged)
                        var chromeColor:uint = getStyle("chromeColor");
                        if (chromeColor != DEFAULT_COLOR || colorized)
                            colorTransform.redOffset = ((chromeColor & (0xFF << 16)) >> 16) - DEFAULT_COLOR_VALUE;
                            colorTransform.greenOffset = ((chromeColor & (0xFF << 8)) >> 8) - DEFAULT_COLOR_VALUE;
                            colorTransform.blueOffset = (chromeColor & 0xFF) - DEFAULT_COLOR_VALUE;
                            colorTransform.alphaMultiplier = alpha;
                            transform.colorTransform = colorTransform;
                            var exclusions:Array = [labelDisplay, sortIndicatorInstance];
                            // Apply inverse colorizing to exclusions
                            if (exclusions && exclusions.length > 0)
                                colorTransform.redOffset = -colorTransform.redOffset;
                                colorTransform.greenOffset = -colorTransform.greenOffset;
                                colorTransform.blueOffset = -colorTransform.blueOffset;
                                for (var i:int = 0; i < exclusions.length; i++)
                                    var exclusionObject:Object = exclusions[i];
                                    if (exclusionObject &&
                                        (exclusionObject is DisplayObject ||
                                            exclusionObject is GraphicElement))
                                        colorTransform.alphaMultiplier = exclusionObject.alpha;
                                        exclusionObject.transform.colorTransform = colorTransform;
                            colorized = true;
                        chromeColorChanged = false;
                    super.updateDisplayList(unscaledWidth, unscaledHeight);
                 *  @private
                override public function styleChanged(styleProp:String):void
                    var allStyles:Boolean = !styleProp || styleProp == "styleName";
                    super.styleChanged(styleProp);
                    if (allStyles || styleProp == "chromeColor")
                        chromeColorChanged = true;
                        invalidateDisplayList();
                protected function managefilterField(event:MouseEvent):void
                    trace("double click sortIndicator : "+this.sortIndicatorInstance);
                    this.filterInput.visible=!this.filterInput.visible;
                    this.filterInput.includeInLayout=this.filterInput.visible;
                    this.filterSpacer.visible=this.filterInput.visible;
                    this.filterSpacer.includeInLayout=this.filterInput.visible;
                    if(!this.filterInput.visible)
                        this.filterInput.text="";
                        dispatchEvent(new ColumnFilteredEvent(ColumnFilteredEvent.COLUMNFILTERED_EVT,new FilterCriteria(this.column.dataField,this.filterInput.text)));
                    this.filterInput.setStyle("borderColor",0xFF6319);
                    this.filterInput.setStyle("focusColor",0xFF6319);
                    //this.filterInput.setStyle(
                protected function onTextInputSelection(event:MouseEvent):void
                    event.stopImmediatePropagation();
                    this.filterInput.setStyle("borderColor",0xFF6319);
                    this.filterInput.setStyle("focusColor",0xFF6319);
                protected function onKeyUp(event:KeyboardEvent):void
                    if(event.charCode==Keyboard.ENTER)
                        stage.focus=null;
                protected function onFocusOut(event:FocusEvent):void
                    this.filterInput.setStyle("borderColor",0x00ff00);
                    this.filterInput.setStyle("focusColor",0x70B2EE);
                    dispatchEvent(new ColumnFilteredEvent(ColumnFilteredEvent.COLUMNFILTERED_EVT,new FilterCriteria(this.column.dataField,this.filterInput.text)));
            ]]>
        </fx:Script>
        <s:states>
            <s:State name="normal" />
            <s:State name="hovered" />
            <s:State name="down" />
        </s:states>     
        <!-- layer 1: shadow -->
        <!--- @private -->
        <s:Rect id="shadow" left="-1" right="-1" top="-1" bottom="-1" radiusX="2">
            <s:fill>
                <s:LinearGradient rotation="90">
                    <s:GradientEntry color="0x000000"
                                     color.down="0xFFFFFF"
                                     alpha="0.01"
                                     alpha.down="0" />
                    <s:GradientEntry color="0x000000"
                                     color.down="0xFFFFFF"
                                     alpha="0.07"
                                     alpha.down="0.5" />
                </s:LinearGradient>
            </s:fill>
        </s:Rect>
        <!-- layer 2: fill -->
        <!--- @private -->
        <s:Rect id="fill" left="0" right="0" top="0" bottom="0">
            <s:fill>
                <s:LinearGradient rotation="90">
                    <s:GradientEntry color="0xFFFFFF"
                                     color.hovered="0xBBBDBD"
                                     color.down="0xAAAAAA"
                                     alpha="0.85" />
                    <s:GradientEntry color="0xD8D8D8"
                                     color.hovered="0x9FA0A1"
                                     color.down="0x929496"
                                     alpha="0.85" />
                </s:LinearGradient>
            </s:fill>
        </s:Rect>
        <!-- layer 3: fill lowlight -->
        <!--- @private -->
        <s:Rect id="lowlight" left="0" right="0" top="0" bottom="0">
            <s:fill>
                <s:LinearGradient rotation="270">
                    <s:GradientEntry color="0x000000" ratio="0.0" alpha="0.0627" />
                    <s:GradientEntry color="0x000000" ratio="0.48" alpha="0.0099" />
                    <s:GradientEntry color="0x000000" ratio="0.48001" alpha="0" />
                </s:LinearGradient>
            </s:fill>
        </s:Rect>
        <!-- layer 4: fill highlight -->
        <!--- @private -->
        <s:Rect id="highlight" left="0" right="0" top="0" bottom="0">
            <s:fill>
                <s:LinearGradient rotation="90">
                    <s:GradientEntry color="0xFFFFFF"
                                     ratio="0.0"
                                     alpha="0.33"
                                     alpha.hovered="0.22"
                                     alpha.down="0.12"/>
                    <s:GradientEntry color="0xFFFFFF"
                                     ratio="0.48"
                                     alpha="0.33"
                                     alpha.hovered="0.22"
                                     alpha.down="0.12" />
                    <s:GradientEntry color="0xFFFFFF"
                                     ratio="0.48001"
                                     alpha="0" />
                </s:LinearGradient>
            </s:fill>
        </s:Rect> 
        <!-- layer 5: highlight stroke (all states except down) -->
        <!--- @private -->
        <s:Rect id="highlightStroke" left="0" right="0" top="0" bottom="0" excludeFrom="down">
            <s:stroke>
                <s:LinearGradientStroke rotation="90" weight="1">
                    <s:GradientEntry color="0xFFFFFF" alpha.hovered="0.22" />
                    <s:GradientEntry color="0xD8D8D8" alpha.hovered="0.22" />
                </s:LinearGradientStroke>
            </s:stroke>
        </s:Rect>
        <!-- layer 6: highlight stroke (down state only) -->
        <!--- @private -->
        <s:Rect id="hldownstroke1" left="0" right="0" top="0" bottom="0" includeIn="down">
            <s:stroke>
                <s:LinearGradientStroke rotation="90" weight="1">
                    <s:GradientEntry color="0x000000" alpha="0.25" ratio="0.0" />
                    <s:GradientEntry color="0x000000" alpha="0.25" ratio="0.001" />
                    <s:GradientEntry color="0x000000" alpha="0.07" ratio="0.0011" />
                    <s:GradientEntry color="0x000000" alpha="0.07" ratio="0.965" />
                    <s:GradientEntry color="0x000000" alpha="0.00" ratio="0.9651" />
                </s:LinearGradientStroke>
            </s:stroke>
        </s:Rect>
        <!--- @private -->
        <s:Rect id="hldownstroke2" left="1" right="1" top="1" bottom="1" includeIn="down">
            <s:stroke>
                <s:LinearGradientStroke rotation="90" weight="1">
                    <s:GradientEntry color="0x000000" alpha="0.09" ratio="0.0" />
                    <s:GradientEntry color="0x000000" alpha="0.00" ratio="0.0001" />
                </s:LinearGradientStroke>
            </s:stroke>
        </s:Rect>
        <!--<s:Rect id="fill" left="0" right="0" top="0" bottom="0">
            <s:fill>
                <s:LinearGradient rotation="90">
                    <s:GradientEntry color.normal="0xf9f9f9" color.hovered="0xfcfdfa"
                                     color.down="0xdceac2" alpha="0.85" />
                    <s:GradientEntry color.normal="0xeaeaea" color.hovered="0xdceac2"
                                     color.down="0xd2e1b5" alpha="0.85" />
                </s:LinearGradient>
            </s:fill>
        </s:Rect>-->
        <!--<s:VGroup left="7" right="7" top="5" bottom="5" gap="6" verticalAlign="middle">
            <s:TextInput width="100%" />
            <s:HGroup width="100%">
                <s:Group id="labelDisplayGroup" width="100%" />
                <s:Group id="sortIndicatorGroup" includeInLayout="false" />
            </s:HGroup>
        </s:VGroup>-->
        <s:VGroup verticalAlign="middle" left="7" top="5" right="7" bottom="5" gap="2" >
            <s:TextInput id="filterInput" width="100%" visible="false" includeInLayout="false" keyUp="onKeyUp(event)" focusOut="onFocusOut(event)" click="onTextInputSelection(event)"/>
            <s:Spacer id="filterSpacer" visible="false" includeInLayout="false" height="5" />
        <s:HGroup width="100%" height="100%" verticalAlign="middle">
            <s:Group id="labelDisplayGroup" width="100%" />
            <s:Group id="sortIndicatorGroup" includeInLayout="false" />
        </s:HGroup>
        </s:VGroup>
    </s:GridItemRenderer>

    Based on your idea, i've intercepted the click event and I use stopImmediatePropagation.
    THen i added an image to sort the column. So if the image is clicked the sort is ok.

  • Sorting & Filtering in the same table

    Hello,
    i had table with 5 entries in it.
    First Column  -     a, ba, ab, aa, bb
    Second Column - 4, 2, 1, 3, 5
    I had sucessfully implemented Sorting & Filtering functionality to that table.
    single Action:
    1) when I sort 'First' column, as expected it is sorting that column - display 5 rows
    2) when I filter 'First' column with value 'a', as expected it is filtering that column - display 4 rows (as 'a' is in 4 entries)
    Double Action:
    1) when I Filter 'First' column with value 'a', result displayed is 4 rows, then on that 4 entries when sorted the second column -- reuslt is good 4 entries (ie the sorting is done on the filtered entries)
    2)Vice vesa, when i sort 'Second' column & Filtered the first column - the displayed result is not correct
    First Option: (2 actions one after another) when sort second colum and then filtered the First column - result should be the sorted & filtered values of second column ignoring the first.(ie result should be -- a, aa, ab, ba, but filtering result is not sorted). How can i achive this?
    if first option is not possible then second option
    Second option: when i sort the second column & filter the first column,  then the result should be -- Filted the first column & sort the second column and then the result should display (it should be like sorting is done on the filtered values).
    Conclusion: If I filter a column, then filtered entries displayed should be in a sorting order (may be ascending).
    Thanks
    Maha
    Edited by: Maha Hussain on Aug 6, 2009 12:02 PM
    Edited by: Maha Hussain on Aug 6, 2009 12:18 PM
    Edited by: Maha Hussain on Aug 6, 2009 12:25 PM
    Edited by: Maha Hussain on Aug 6, 2009 12:56 PM

    Hi Maha,
    Please go through this pdf you will get the solution definitely,
    https://www.sdn.sap.com/irj/scn/index?rid=/library/uuid/f024364b-3086-2b10-b2be-c0ed7d33fe65
    thanks,
    viswa

  • Find all tables in db with column name of a particular string?

    I'm looking for all tables in a db that have a certain column name. How can I find this?

    John,
    thanks for your answer.
    John Mcginnis wrote:
    The quick search field in the schema browser is doing client-side filtering of the list of objects. This means we can only filter on things that we already have fetched from the database, like the object name. We have no current plans to extend the types of information that can filter on, although it is possible we might add the ability to filter based on a few other types of information that we generally fetch with the object name. However, filtering by column name would require pre-fetching the lists of columns for all tables and as such is not likely to be added to the schema browsers search field.
    I'm sure you guys had a Toad review to understand how things are done there.....so
    My 2 cents are: instead of pre-fetching the columns of all tables why don't you add a button below the table drop-down list which should fetch the tables based on the filter columns condition - exactly like Toad.
    Thanks,
    Dani

Maybe you are looking for