Several ranges in a query

Is it possible to allow the end user to specify several ranges in a query variable? Standard variable types are : single value, several values and range, so I think it could not be done directly. But maybe this problem is common and a good solution already exists?
Thanks in advance.

Hi Andrey,
I assume that you mean you want to set filter values on a characteristic.  You want several filters, some or all of which are ranges (between filters).
I can tell you how to do this in BEx Analyzer (queries embedded in Excel workbooks).  Users can do this manually using the Set Filter interface and selecting the Value Ranges from the drop down box at the top left.  If both ends of the range are in the master data, they can select each end of the range.  If the ranges they want are not in the master data, then they simply type in the range with a semicolon ( between the two values.
If you want to do this programmatically, so the user does not have to use the Set Filter interface, it is possible, but problematic.  It requires quite a bit of Visual Basic coding and is not recommended.  See https://websmp201.sap-ag.de/~sapidb/011000358700011836292001
which includes a warning against implementing just this sort of thing (see page 2).
If you want to do this for a Web report, I'm not an expert in that area.  Hopefully someone else who is can respond.
- Pete

Similar Messages

  • Can I use SYSDATE in the WHERE clause to limit the date range of a query

    Hi,
    Basicaly the subject title(Can I use SYSDATE in the WHERE clause to limit the date range of a query) is my question.
    Is this possible and if it is how can I use it. Do I need to join the table to DUAL?
    Thanks in advance.
    Stelios

    As previous poster said, no data is null value, no value. If you want something, you have nvl function to replace null value by an other more significative value in your query.<br>
    <br>
    Nicolas.

  • Can we create range variable for Query Key Date

    Hello Gurus,
    Can we create a range variable for Query Key Date ? when I tried to give a range of values for Query Key Date, I am unable to find Range Values option. I found only Single Values.
    so, Please let me know if we can use Range variables for Query Key Date ??
    Thanks in advance,
    Regards,
    Aarthi

    Hi Aarthi,
    This is relevant for the time dependant master data that is being pulled in thw query. Like if you are using a nav attr in the query and this nav attr is time dependant, then which record (from the char master data) is to be pulled into the report, depends upon the key date that you specify.
    The default key date value is the date on which the query is executed, that is <Today>.
    Hope this helps...

  • Calculated Age and Age Ranges in a Query

    Hello,
    We are using 3.5 Query Designer.
    I am trying to create age ranges in a query. The InfoProvider at this point (I've gone very simple) is InfoObject, 0PERSON.
    I've created a calculated key figure (CKF) called age which I have used a formula to define. The age is calculating correctly. Age has  'Calculate Result As...' = Summation. And in the 'Enhance', 'Time of Calculation' is set to Before aggregation. Number of decimal places set to 0. Now I've created a CKF, AGE_GE_40 which has as its formula 'COUNT(('Age' >= 40)). I've created an additional CKF, AGE_LE_39 which has a formula 'COUNT(('Age'<=39))'. Both of these have the 'Summation' set in the calculation section. The query contains 0GENDER, 0PERSON with AGE_GE_40 and AGE_LE_39 and Number of records as the key figures in the columns. When executed initially, all of the result rows are correct. The problem is when I remove 0PERSON, the result rows only give me 1 per gender. This seems like an easy thing to do, why is it not working?
    Thanks for any help,
    Diane Merrill

    Diane,
    For each row in the query data, there is only one age value calculated, which is the aggregration of all records which fulfills the row's characteristic value combination. Thus, when there is Gender & Person columns in the query, each row calculates an age value for the Gender/Person combination, which is essentially the same as for each person, because each person has one gender value. However, when you remove person from the columns, there will be only two values for gender, and the age is calculated as the sum of ages for all records with the same gender value. To reveal more on this, you can add the Age key figure into the query columns, and run the query with only the gender (i.e. without person). Once you see the age value for each row, it should be clear to you.
    Please reward points if this is helpful.
    Wayne

  • Date Range Selection in Query Templates

    Hi,
    Can someone please tell me how to use <b>Date Range Selection</b> Tab details in SQL Query and TAG Query (Using Examples).
    Thanks in advance
    Muzammil P.T

    >>>>>>>>>>
    Re: Date Range Selection in Query Templates   
    Posted: Feb 15, 2007 6:43 AM    in response to: Muzammil Ahamed       Reply      E-mail this post 
    Hi Muzammil,
    In data range section you can have multiple options like setting start datetime and end datetime.. And you can set the shift (or) time period and also the format of the time periods.
    Primarily we use the start date and end date querying to fetch data between two time labels. I can explain this one with example..
    You have batch production table with columns Production Time, Batch Id, Production Qty. Then you want all the details between the 02/02/2007 to 05/02/2007.
    Solution :
    1.Map 02/02/2007 with Start date.
    2.Map 05/02/2007 with end dare.
    Now these two become the variables [SD] and [ED].
    Now you have mentioned the date range, but you need to mention for which column these things to be applied. For that
    3.In Query tab enter Production Time column name in Date column at the bottom.
    Now you have written query like Select * from batch prodcution where production time > 02/02/2007 and production time < 05/02/2007.
    4. Even those values you mapped (SD and ED) you can change from the front page through Java script.
    Like wise you have so many other advantages also.
    If you have any other specific doubt let me know.
    Thanks,
    Rajesh.
    PS : Please ward points if answer is useful. <<<<<<<<
    Message was edited by:
            David Dreyer

  • How to define variable for value range in Bex Query?

    Hi
    How to define variable for Keyfig. value range on runtime like characteristic in Bex Query?
    Example: On runtime user select one of the following condition:
    1)User want to those records where amount is greater than $1000
    2)User want to those records where amount is greater than $1000 and less than $5000
    3)User want to those records where amount is greater than and equal to $1000

    Hi ,
    Need to Use exceptions & conditions for this scenario's  & need to create variable for exceptions based on condtions.
    Below document provides steps how to make selections at run time for a kfg.
    http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/60b33a28-dca2-2d10-f3b2-d2096b460b1e?QuickLink=index&overridelayout=true&48842368468641
    Regards,
    Seshu.P

  • User Prompt for Date Range in Bex Query Analyzer

    I have a workbook that has two queries. The queries both require the user to enter a date range upon refresh. I want the user to be able to hit refresh, enter the date input into the dialog box and then both queries to use this date range for their input. I have seen this in other book, but when I click refresh on my book it only runs the first query. How do I get the second query to use the first queries input?

    use the same variable in both the queries. this will let the user enter the date in a single variable and this will refresh both the queries.
    rgds, Ghuru

  • Passing the Date range within the query

    Hi ,
    In my query , I have two date characteristic, and while doing the selection I have to do selection on only one date field.
    This selection is a date range selection , So I have used a selection variable for this.
    Can anyone please let me know if it is possible to pass the selection range to other variable. Is it possible to use Customer exit to pass the complete range.
    Thanks
    Altair

    Hi,
    You can do it in the user exit.And that is the only approach to transfer the values of one variable to other variable .
    Search this forum for the code. you will find  lot of postings.
    With rgds,
    Anil Kumar Sharma .P

  • Update several rows with single query (easy question, I guess)

    Hi all!
    I have table with two columns - name and value.
    I populate it with several sql queries:
    insert into settings (name, value) values ('company_name', 'My Company');
    insert into settings (name, value) values ('company_address', 'Company Address 12');
    insert into settings (name, value) values ('company_city', 'South Park');
    How can update rows with company_name and company_city in single query?
    Thank you in advance!

    How can update rows with company_name and company_city in single query?I guess something like this was meant:
    update settings set value = ??? where name in ('company_name ', 'company_city');But it's still unclear to me what should be used instead of question marks... :)
    Regards.

  • Opendoc date range into Bex query

    We are having an issue when trying to pass a date range in an Opendoc link. The report is built off a BEx query,  within the report we have an Opendoc link into a child version of the report. I can pass all the other prompts with no issue except for one which is the date range.
    I am defining the date range as "[19000101]..[19000101]" but we keep getting this error message:
    Has anyone lese had this issue?
    Thanks

    Hi,
    Try This
    "[Date(2014,04,01)]..[Date(2014,04,11)]"
    "[Date(yyyy,MM,dd)]..[Date(yyyy,MM,dd)]"
    http://help.sap.com/businessobject/product_guides/boexir4/en/xi4_opendocument_en.pdf#page=26
    http://<servername>:<port>/BOE/OpenDocument/opendoc/openDocument.jsp?iDocID=Aa6GrrM79cRAmaOSMGoadKI&sID
    Type=CUID&sRefresh=Y&lsRTime+Period:=[2000..2004)
    http://<servername>:<port>/BOE/OpenDocument/opendoc/openDocument.jsp?iDocID=Aa6GrrM79cRAmaOSMGoadKI&sID
    Type=CUID&sRefresh=Y&lsRparamStringDR=[h..i]&lsRparamNumberDR=[7..8]&lsRparamCurrencyDR=[3..4]&lsRparamDat
    eDR=[Date(2003,6,7)..Date(2003,6,8)]&lsRparamDateTimeDR=[DateTime(2003,6,1,7,1,1)..Date
    Time(2003,6,1,8,1,1)]&lsRparamTimeDR=[Time(1,1,7)..Time(1,1,8)]&lsRparamUnbound1=(..6)&lsRpara
    mUnbound2=[6..)&lsRparamStringR=[a..d]&lsRparamNumberR=[1..3]&lsRparamCurrencyR=[1..3]&lsRparam

  • Free Characteristic, range value, filtering query for iveiw in WAD

    Using the web application designer I am adding a query (BW 3.5) to a sales portal (EP 6.0) of all projected wins (custom characteristic on opp header).  Sales has requested I provide in by mth and by qtr.  I created value ranges in my projected win characteristic in the query of 4/1-4/30,5/1-5/31 etc. and have attempted to use the
    Filter
    Navigation block
    and
    Drop down and radio were I get every date of the month and not just the ranges I created.
    Can I do this through a query and and the WAD or do I have to do some custom work.
    Will award points!
    Maggie

    Hi,
    the feature you are requesting is called "Master Data Planning". Unfortunately it is not supported by SAP. Please use the term "master data planning " to search this forum and you will find some threads about this issue.
    Hope this helps
    Matthias Nutt
    SAP Consulting Switzerland

  • Deleting several rows from a query

    I have a query with several rows that have a field with the
    string "2 by 4" that I would like to delete. There are other rows
    where this same field is "2 by 2" and I don't want to delete those
    rows.
    What's the syntax? Can I use structdelete? Or is this
    data-structure an array?

    Use the where clause of your sql to select only the records
    you want. If you actually need all the records you are getting now,
    and you also want a subset of those records, use query of queries
    to get your subset.

  • Ranges (intervals) in query

    Dear Experts,
    There is a requirement to design a Query with Graph where I want to show on X-Axis the value range from zero to ten (0-10), then ten to twenty (10-20) and so on. The intervals are not constant for example, after 10-20, next interval could be 20-25, and then 25-30,....... And, the "Number of Records" (which is a key-figure) should be summarised within these above intervals.
    Kindly care to share your invaluable thoughts on how to achieve this.
    Thanks,
    Shalini.

    Hi Khaled,
    I have to build a graph where x axis represents interval values say 0-10, 10 20 so on and in y axis i have to show source percentage. To achieve this i have to first design in bex query.These intervals shuld summarise the number of cases done i.e., if number of cases done is 9 it shuld show "9" within the interval of 0-10 and so on. Source % means number of cases done divided by grand total. It will come in "y" Axis.
    Hope i made my self clear
    Thanks for your reply
    Shalini

  • SCCM2012: Can you create a Query-based "User Collection" using an IP Subnet (or IP Address range) in the Query?

    The topic says it all (I hope).  I am new to 2012 and I have tried to accomplish this feat all day, which includes researching online, but I have had zero success in finding anything helpful.
    Obviously I can create "Device Collections" based on the IP Subnets, and I can do a "Direct Rule" in "User Collections" for the desired IP Subnet, but I do not want to do this because I need the results to update if/when
    any changes occur during a "scheduled/incremental update".
    The only thing I could find for the "User Collections" was this:
    select *  from  SMS_R_User where SMS_R_User.FullUserName = SMS_R_User.UserName and SMS_R_System.IPAddresses like "111.11.1%"
    EXAMPLE (Query for Devices):
    select *  from  SMS_R_System where SMS_R_System.IPAddresses like "111.11.1%"
    Is there a way to Query SCCM (2012) and display the Usernames of computers that login to the (sole) Domain through a specified (or desired) IP Subnet?

    Why do you want to install software by location for a user? Why do you care?
    Why would you want to create a collected of Users with software installed? PCs have the SW install not users so how would you use it?
    Garth Jones | My blogs: Enhansoft and
    Old Blog site | Twitter:
    @GarthMJ
    I was asked to setup these (Device and User Collections) in this manner so we can limit future distributions/deployments of Applications (and/or Packages) and (OS) Images by these groupings.  Apparently there will be occasions where deployments will need
    to be segmented as such because the company wants to have them grouped in this manner.  If there is a better option available than this, which I would not doubt since I am new to SCCM 2012, then I would appreciate the information.
    IMO, you need to go back to the person asking and get and better understand of exactly what they want and more importantly why.  Making a collection, just in case doesn't make sense.
    Garth Jones | My blogs: Enhansoft and
    Old Blog site | Twitter:
    @GarthMJ

  • A period from outside of restricted period range appears on query

    Hi,
    I have a problem with an unwanted period (001.2009) which appears on the planning query.
    We are using dynamic periods to determine periods for actual and planning figures and right now the periods should be: 001.2009 - 009.2009 for actuals and 010.2009 - 012.2010 for forecast. However 001.2009 is displayed as the first period for forecast. The column for january is completely empty and it isn't open for planning.
    I restrict the periods for actuals and forecast with a user exit variable which gets it's values from TVARVC -table. I'm experiencing this problem only in development and test -environments and production system is working perfectly with the exactly similar implementation. This implicates that this problem exists because of a bug or program error. Maybe this is because of some note that have been implemented.
    However, I'd just like to know if anyone here has experienced this kind of problem with these "phantom periods" which appear on reports or planning layouts without any apparent reason? If so, please tell me about your experiences and how you managed to solve the issue?
    -Miikka
    Edited by: Miikka Åkerman on Oct 1, 2009 12:32 PM

    This was a program error solved in SPS20

Maybe you are looking for

  • PF No. Not getting displayed in payslip

    Dear All, The PF No. is not getting displayed in the payslip. In pe51 transaction for the form created under Single fields i can see the table maintained as p0587as Table and Table field as EEPFM. The master data is maintained for this employees in I

  • Changing SMTP Server Ports When Setting Up New Accounts

    My ISP, COX Communications, blocks port 25 for email accounts not using their SMTP servers. When setting up a mail account how do you change the port? I know how it's done when you have the account set up, but not when you're trying to set up the acc

  • How to fetch the data from a standard report to a user defined report

    Hi, i m using a standard report RFEBKA00 which uses CHAR300 variable(it is not used in selection screen). can u help me , to collect the data from CHAR300 and to use it in my own report. Message was edited by:         jaya raman

  • Can no longer connect to my network - AirPort Extreme

    Hi everyone. I have a small network in my home office and as of lately cannot connect on the wireless side for some reason. My setup: I have a linksys wrt54g router connected to my modem. I have an Intel MacMini connected to the router via ethernet.

  • APP ::::It clearning my open items, But spool and check dislay problem

    Hi Gurus,  Thanks for your time, When i run APP, it will clearing all my open items from my house bank,  when i try to display the check register it will show no check information.  and i want view print preview my vendors summary information, advice