Greater than or less than

I have two block ctr nad detail block i want to search by contrl block where i give two boxes
and one name is searh_type and other name is value_1 and create a buttom and wirte this code on when button pressed for greater then but when i press the button it was not working it will show all the data either greater on lesser please guide
declare
     l_where varchar2(4000);
begin
if :search_type = 'VALUE' then
     l_where := 'value >     :value_1' ;
else
     null;
end if;
set_block_property('order_tracker1',default_WHERE,l_where);
go_block('order_tracker1');
execute_query;
end;
Thanks And Regards
Vikas Singhal

Try this code:
declare
l_where varchar2(4000);
begin
if :search_type = 'VALUE' then
l_where := 'value > '||:value_1 ;
else
null;
end if;
set_block_property('order_tracker1',default_WHERE,l_where);
go_block('order_tracker1');
execute_query;
end;Put also a message to check if your where condition is right or not as follow
message('my where condition is '||l_where);
message(' ',no_acknowledge);Hope it helps you,
Fabrizio
If this answer is helpful or correct, please mark it. Thanks.

Similar Messages

  • Greater Than or Less Than using String Variables

    I seem to have a problem when trying to sort an ALPHABETIC LIST, seeing if one text field is greater tan or less than another.
    i.e. Lets say my variables are called FirstLetter and SecondLetter.
    FirstLetter="A", SecondLetter="B"
    So as an example and a test....Can I ask ...
    IF SecondLetter>FirstLetter Then
            Textwindow.WriteLine(SecondLetter + "  >" + FirstLetter)
    Else
            Textwindow.WriteLine(FirstLetter + " >= " + SecondLetter)
    Endif
    I seem to be fine and program working well with numeric values in variables but the '> & <' feature does not seem to work with Text ?
    Any help really appreciated
    Thanks
    Dave

    We gotta get their ASCII/UNICODE value before comparing them:
    firstLetter = "A"
    secondLetter = "B"
    If Text.GetCharacterCode(firstLetter) > Text.GetCharacterCode(secondLetter) Then
    Textwindow.WriteLine(FirstLetter + " > " + SecondLetter)
    ElseIf Text.GetCharacterCode(firstLetter) < Text.GetCharacterCode(secondLetter) Then
    Textwindow.WriteLine(SecondLetter + " > " + FirstLetter)
    Else
    Textwindow.WriteLine("They're the same " + FirstLetter + " letter!")
    EndIf
    Click on "Propose As Answer" if some post solves your problem or "Vote As Helpful" if some post has been useful to you! (^_^)

  • Does specified lsn should greater than or less than min_autonosync_lsn when setting up a "initialize from lsn" subscription?

    Hello,
    For setting up a "initialize from lsn" type subscription successfully, Does the lsn for @subscriptionlsn parameter need greater than or less than the  min_autonosync_lsn (syspublications) ?
    I read two versions of this: one is lsn >min_autonosync_lsn ,the other is lsn <min_autonosync_lsn. I agree lsn >min_autonosync_lsn.
    Thanks

    Basically it means that the lsn should be retrievable somewhere in the distribution database.  So it has to be> than the min otherwise you would need to reinitialize.
    Note that this is only important when you are mirroring the subscription database.
    looking for a book on SQL Server 2008 Administration?
    http://www.amazon.com/Microsoft-Server-2008-Management-Administration/dp/067233044X looking for a book on SQL Server 2008 Full-Text Search?
    http://www.amazon.com/Pro-Full-Text-Search-Server-2008/dp/1430215941

  • Greater than AND less than

    i want to say 'if the root current frame is greater than 40
    and less than 50...
    if (_root._currentframe= ?)
    sorry, i'm kinda crap at this! please help!...

    You need to have a double || to get the logical or, otherwise
    you get the bitwise or.
    NSurveyor, I always put brackets, simply for readability. 25
    years ago I have been programming in APL, probably the "shortest"
    programming language ever. It looked like swearing in cartoons,
    with lots of stars, bombs and knives :-) I knew very few people
    that could read and understand those programs once they were
    written, not even the authors themselves. That taught me to
    introduce
    redundancy

  • Case structure greater than or less than

    Hello.
    I am having difficulty with making a case structure that if a numerical input is greater than a number it does one thing and less it does another.
    Basically how do you work with case structures that aren't boolean, specifically if a number is greater than 38 it reassigns it as 0 (multiplies by zero something like that).
    Solved!
    Go to Solution.

    http://zone.ni.com/reference/en-XX/help/371361H-01/lvhowto/case_selector_values/
    Or use the boolean logic you are talking about.  If you use a greater than on your number and it is greater you will get a true and if it is not greater than it will be false.  You could even use the in range function (comparison pallete) to get a true or false.
    Or give more information about what you are trying to do.  The more info you give, the better answer you will get.  Otherwise we have to guess why you are trying to do it the way you are asking when there could be a better way.

  • Updates using greater than or less than logic....

    Hi, I've run into something that I can't figure out how to do through the OWB GUI. I have a source table that tells me that data changed between a given effective start and effective end dates (for example, NAME information). Given that, I want to update all rows in the person dimension tied to the matching person, where the effective date on the person dim is between the effective start and end dates on the source table.
    Using the standard update operator, it looks like the only option I have is "=", I can't specify "<=" or ">=".
    Is there any (easy) way around this?
    Thanks,
    Scott

    I'd like to expand on Bharad's join condition.
    Keep in mind that you have to use the effective start date two times (see below).
    ingrp1 a.person_id =ingrp2 b.person_id
    and ingrp1 a.effective_start_date >= ingrp2 b.effective_start_date
    and ingrp1 a.effective_startdate <= ingrp2 b.effectiveend_date
    Also, in most dimension tables the effective end date can contain NULL values which we need to take care off as well otherwise we will 'lose' records. A NVL can fix that problem, for example:
    ingrp1 a.person_id =ingrp2 b.person_id
    and ingrp1 a.effective_start_date >= ingrp2 b.effective_start_date
    and ingrp1 a.effective_start_date <= nvl( ingrp2 b.effective_end_date, sysdate)
    You can also substitute sysdate for a fixed date in the future but it's not dynamic then.

  • Sale value of group asset- sub asset more than wdv less than group total

    Hi,
    I am maintaining group asset for Income Tax Depreciation. All the asset under the same class is consider single asset for Income tax purpose. For eg value of Plant and machinery under Income tax is derived for all asset totaled together after depreciation for the year. Thus P&M is considered single asset for calculating I.T. Depreciation, even though it may contain 100 assets.
    For Income tax, for P & M class of asset depreciation for first year is with different rate and for rest years with different rate. Hence I have maintained sub asset for this group asset. Whenever a new asset is purchase, for income tax purpose it is recorded in the newly created sub asset number.
    The problem arises in sale of asset. When I am selling any machinery the sale value is deducted from the group value for IT purpose. In this case even though the value of sale is higher than the WDV of the individual asset it is adjusted in total. While configuring this in SAP I am facing following difficulties-
    1.     As the rate of depreciation is different for different years I am not able to maintain a single group asset. I have to create a sub asset. This facilitate the right depreciation calculation by different dep rate for purchases in diff year.
    2.     But as I am maintaining different Sub asset the sale value cannot exceed the balance of that particular asset, even though the total value in SAP for all the group assets is higher.
    3.     I can not allow having negative values. Negative values are not allowed to maintain in IT Records.
    Please help to resolve the issue.

    Hi,
    I am maintaining group asset for Income Tax Depreciation. All the asset under the same class is consider single asset for Income tax purpose. For eg value of Plant and machinery under Income tax is derived for all asset totaled together after depreciation for the year. Thus P&M is considered single asset for calculating I.T. Depreciation, even though it may contain 100 assets.
    For Income tax, for P & M class of asset depreciation for first year is with different rate and for rest years with different rate. Hence I have maintained sub asset for this group asset. Whenever a new asset is purchase, for income tax purpose it is recorded in the newly created sub asset number.
    The problem arises in sale of asset. When I am selling any machinery the sale value is deducted from the group value for IT purpose. In this case even though the value of sale is higher than the WDV of the individual asset it is adjusted in total. While configuring this in SAP I am facing following difficulties-
    1.     As the rate of depreciation is different for different years I am not able to maintain a single group asset. I have to create a sub asset. This facilitate the right depreciation calculation by different dep rate for purchases in diff year.
    2.     But as I am maintaining different Sub asset the sale value cannot exceed the balance of that particular asset, even though the total value in SAP for all the group assets is higher.
    3.     I can not allow having negative values. Negative values are not allowed to maintain in IT Records.
    Please help to resolve the issue.

  • User input formula variable with greater than/less than operators for KFG

    Hello all,
    I have used a formula in my query that is a difference of two key figures .For e.g:
    Difference = tax from system A  -  tax from system B.
    Now when the users run the report they should be prompted for the 'Difference' threshold for seeing the report say where difference is greater 100 or equal to 10 and so on.Currrently I have created a formula variable with 'user input' and created a 'condition' to display 'Difference' greater than the user entered value.
    However,it is required to have various selection options for setting the threshold of difference.For e.g User should be able to set say 'equal to'/'greater than/less than/not equal to operator for 'difference' in the initial selection screen of the report.
    With the current user-input formula variable I am not getting these 'greater than' etc operators.Any ideas on how to achieve this?

    Ya know, that's all well and good ... BUT ... WHAT IF you do want to sort text type columns with Greater Than and Less Than operatiors??
    SQL does it just Fine ... so WHY does APEX have the limit??? This is an Oracle BUG ... it SHOULD NOT limit the operators ... I realize "they" may be trying to be helpful with proper constraints to field searches ... but ... if SQL can do it, then ... no need for a limit.
    EG ...
    Show the records where
    the "Begin_Year-Wk" data is less than or equal to "2009-09" AND
    the "End_Year-Wk" data is greater than or equal to "2009-04"
    ... to give everything that was running in that 5 week period whether or not it starts within that time frame
    I can run this query perfectly fine via SQL ... but not in APEX ... unless I reconvert a lot of strings back to numbers, and for sorting / formatting / explain-to-user purposes, I really don't want them to be numbers.
    So ... there's gotta be a hidden tweak for operators somewhere ...

  • Filtering Interactive Reports with Greater Than Less Than Operators

    The available filter operators in the interactive reports do not include greater than or less than. How is it possible to enable an application user to filter records where greater than or less then logic is needed?
    For example the user wants to query records where sysdate falls between a start and end date.
    Regards,
    Todd

    Ya know, that's all well and good ... BUT ... WHAT IF you do want to sort text type columns with Greater Than and Less Than operatiors??
    SQL does it just Fine ... so WHY does APEX have the limit??? This is an Oracle BUG ... it SHOULD NOT limit the operators ... I realize "they" may be trying to be helpful with proper constraints to field searches ... but ... if SQL can do it, then ... no need for a limit.
    EG ...
    Show the records where
    the "Begin_Year-Wk" data is less than or equal to "2009-09" AND
    the "End_Year-Wk" data is greater than or equal to "2009-04"
    ... to give everything that was running in that 5 week period whether or not it starts within that time frame
    I can run this query perfectly fine via SQL ... but not in APEX ... unless I reconvert a lot of strings back to numbers, and for sorting / formatting / explain-to-user purposes, I really don't want them to be numbers.
    So ... there's gotta be a hidden tweak for operators somewhere ...

  • Time Machine wants 16 days to do an initial backup.  ps shows PRI = 33 with NI = 0.   But I can not get sudo renice to set PRI less than 15.  And renice sets NI directly with strange behavior for PRI. Any suggestions?

    Time Machine said it would take 16 days to do an initial backup, and indeed, after many days it is less than a quarter done.   (The problem started when I put in a new bank disk for Time Machine to write to for its backup file.)
    Activity Monitor shows that the process name is   backups   with Process ID   6060.
    Then putting this PID in Terminal UNIX command ps gave:
    EdsMacPro-1:~ ed$ ps -l -p 6060
      UID   PID  PPID        F CPU PRI NI       SZ    RSS ...
        0  6060     1  1004004   0  33  0  2556488  29040 ...
    Wow!  A priority of 33! 
    Don't know how that happened, but the way to fix that (I thought) is with renice. 
    But renice doesn't work.
    After a lot of playing with renice and ps, it looks as though renice can not make the priority better than (no less than) 15.
    And the parameter you put in, that according to the man page that is supposed to be priority, turns out to be "nice index", with priority changed by sometimes subtracting or sometimes adding either this number or twice this number - down to a limit of priority no less than 15.
    EdsMacPro-1:~ ed$ ps -l -p 6060
      UID   PID  PPID        F CPU PRI NI       SZ    RSS ...
        0  6060     1  1004004   0  33  0  2556488  29040 ...
    EdsMacPro-1:~ ed$ sudo renice 5 -p 6060
    EdsMacPro-1:~ ed$ ps -l -p 6060
      UID   PID  PPID        F CPU PRI NI       SZ    RSS  ...
        0  6060     1  1004004   0  28  5  2555964  29028  ...
    EdsMacPro-1:~ ed$ sudo renice -5 -p 6060
    EdsMacPro-1:~ ed$ ps -l -p 6060
      UID   PID  PPID        F CPU PRI NI       SZ    RSS  ...
        0  6060     1  1004004   0  38 -5  2555964  29028  ...
    EdsMacPro-1:~ ed$ sudo renice -15 -p 6060
    EdsMacPro-1:~ ed$ ps -l -p 6060
      UID   PID  PPID        F CPU PRI NI       SZ    RSS  ...
        0  6060     1  1004004   0  48 -15  2555964  29028 ...
    EdsMacPro-1:~ ed$ ps -l -p 6060
      UID   PID  PPID        F CPU PRI NI       SZ    RSS  ...
        0  6060     1  1004004   0  48 -15  2555964  29028 ...
    EdsMacPro-1:~ ed$ sudo renice -n -5 -p 6060
    EdsMacPro-1:~ ed$ ps -l -p 6060
      UID   PID  PPID        F CPU PRI NI       SZ    RSS  ...
        0  6060     1  1004004   0  53 -20  2555964  29028 ...
    EdsMacPro-1:~ ed$
    This is with OSX 10.7.5 and Terminal 2.2.3 on an early 2009 Mac Pro with lots of memory.
    What am I dong wrong, and any suggestions for how to fix my Time Machine process?

    The backup file size is 1.67 TB.*
    That's across the internal bus of a 2009 quad-core Mac Pro - which is pretty fast.
    Copying an hour's worth of MPEG-2 HD takes about a minute.
    I do a fresh backup from scratch about once a year, and the last time it finished over night.
    This time the first Time Machine backup is only about 1/5 complete after many days, and Activity Monitor shows essentially no use of disk drives or of CPU.  And in the first note I pointed out what is gleaned by using Terminal to execute the UNIX ps command. The priority of the running Time Machine process looks incorrect to me. 
    I could be wrong, but I think the problem is process priority, not file size.
    I am unable to set priority to 0 or a negative number.  Can someone straighten me out on how to do that?
    [*The machine has four 1.5 TB disk drives in it plus lots of memory.  Two of the physical drives are configured as one 3 TB backup drive (RAID concatanated).]

  • Issues with less than and grater than condition in prompts in OBIEE 11g,

    Hi all,
    i am facing the prombles with less than grater than conditions in OBIEE 11g.
    i created two date prompts with presentation variables datefrom and dateto
    and i used these prompts in fileters like this using grater than and less than symbol.
    filters are as below:
    lastupdated date is grater than or equal to @{datefrom}{1/1/1950}
    lastupdated date is less than or equal to @{dateto){1/1/1950}
    and created two prompts
    creation datefrom >=
    creation dateto<=
    when i passing the dates 05/12/2004 and 05/12/2005 in prompts after clicking the apply button in OBIEE 11g it feches all the records but i need records between these dates. and one more thing is after clicking apply button the two date fields getting the same date..
    am i do any thing wrong in the above ???
    please let me know friends..
    waiting for ur replyyyyyy..
    Thanks
    Edited by: BI_user on Oct 12, 2011 2:10 AM

    Hi,
    Create date prompts with operator as = not >= (or) <= as you need to save that value in presentation variable and you are filtering report using those variable filters.
    Regards,
    Srikanth

  • Less than or equal to broken?

    Download the vi and check out the internals, as they will explain exactly what I'm trying to do.
    Briefly, I am writing a deMUX for a signal that has digital components
    of 0.25V, 0.5V, 1V, 2V, and 4V. The max signal being 7.75V and the min
    being 0V. For example, if the input is 0.25V, the 5 bit digital output
    will be 00001; if the input is 0.50V, the digital output will be 00010;
    if the input is 0.75, then the digital output will be 00011; ... and if
    the input is 7.75, then the digital output will be 11111.
    In order to make the system realistic I have added tolerances to the
    search. So, the tolerance I picked is 0.1V (which is well less than the
    required 1/2 of the smallest voltage increment of 0.25V, which is
    0.125V). Thus, any of the 32 possible voltages +/- 0.1V should decode
    correctly according to the <= circuit I have set up toward the
    bottom of my while loop in the attached vi. It does work for most, but
    it does not work for 1.1V, 2.1V, and 3.1V... and possibly some others.
    For these listed numbers, the comparison acts as a less than, rather
    than a less than or equal to.
    Let me know if you need more information.
    Cheers,
    Joe
    Attachments:
    Full.vi ‏39 KB

    To solve your problem, all you need is to "quantize" the number to your smallest step (0.25 in your case) and convert it to an integer.
    The attached code will probably produce the output you want.
    Message Edited by altenbach on 12-21-2005 09:28 AM
    LabVIEW Champion . Do more with less code and in less time .
    Attachments:
    FullMOD.vi ‏16 KB
    FullMOD.png ‏3 KB

  • I have a manual that contains headings and index entries that contain less than and greater than characters, and . The Publish to Responsive HTML5 function escapes these correctly in the main body of the text but does not work correctly in either the C

    I have a manual that contains headings and index entries that contain less than and greater than characters, < and >. The Publish to Responsive HTML5 function escapes these correctly in the main body of the text but does not work correctly in either the Contents or the Index of the generated HTML. In the Contents the words are completely missing and in the index entries the '\' characters that are required in the markers remain in the entry but the leading less than symbol and the first character of the word is deleted; hence what should appear as <dataseries> appears as \ataseries\>. I believe this is a FMv12 bug. Has anyone else experienced this? Is the FM team aware and working on a fix. Any suggestions for a workaround?

    The Index issue is more complicated since in order to get the < and > into the index requires the entry itself to be escaped. So, in order to index '<x2settings>' you have to key '\<x2settings\>'. Looking at the generated index entry in the .js file we see '<key name=\"\\2settings\\&gt;\">. This is a bit of a mess and produces an index entry of '\2settings\>'. This ought to be '<key name=\"&amp;lt;x2settings&amp;gt;\" >'. I have tested this fix and it works - but the worst of it is that the first character of the index entry has been stripped out. Consequently I cannot fix this with a few global changes - and I have a lot of index entries of this type. I'm looking forward to a response to this since I cannot publish this document in its current state.  

  • Is there replacement for (less than) and (greater than) in Oracle 10g?

    Hi,
    In the User Java Application using Oracle's > (less than) or > (greater than) is not working.
    Can anyone help me onthis for any feature in Oracle 10g instead of using less than or greater than
    Thanks and Regards

    Hi,
    What do yyou mean by "it's not working"?
    Maybe you could use sign function, instead.
    with t as (select 2 x, 3 y from dual union all
               select 2 x, 1 y from dual union all
               select 2 x, 2 y from dual)
    select t.*
      from t
    where sign(y - x) = - 1;
             X          Y
             2          1
    1 row selected.Regards
    Peter

  • Camel Query : Calender list : Get Items agains given date that must be greater than and eqaul to start date and greater less than or equal to end date ?

    Camel Query : Calender list : Get Items agains given date that must be greater than and eqaul to start date and greater less than or equal to end date ?
    A Snap of Employee holiday list
    Case : Anne juul Sondergaar is on leave from 05-06-2014 to 07-06-2014
    I need a query to check wheither Anne juul is on leave at 06-06-2014 ????
    I am using this query that return nothing
    SPQueryquery =
    newSPQuery();
                                query.Query =
    @"<Where>
    <And>
    <And>
    <Leq>
    <FieldRef Name='Til' />
    <Value Type='DateTime'>"
    + WorkingStartDate.ToString("yyyy-MM-dd")
    + @"</Value>
    </Leq>
    <Geq>
    <FieldRef Name='Fra' />
    <Value Type='DateTime'>"
    + WorkingStartDate.ToString("yyyy-MM-dd")
    + @"</Value>
    </Geq>
    </And>
    <Eq>
    <FieldRef Name='Medarbejdere' />
    <Value Type='Lookup'>"
    + EmployeeName.Trim() +
    @"</Value>
    </Eq>
    </And>
    </Where>"
                                query.ViewFields =
    " <FieldRef Name='ID' />";
    Ahsan Ranjha

    Hello,
    Download CAML query builder from below location and use it to build your query:
    http://social.msdn.microsoft.com/Forums/sharepoint/en-US/f7b36ebc-6142-404a-8b04-9c87de272871/where-can-i-download-the-u2u-caml-query-builder-for-sharepoint-2010may-i-know-the-exact-link?forum=sharepointgeneralprevious
    Hemendra:Yesterday is just a memory,Tomorrow we may never see
    Please remember to mark the replies as answers if they help and unmark them if they provide no help

Maybe you are looking for

  • J2ME Icons Problems

    I bought "Beginnign Mobile Game Programming" by Michael Morrison, and I'm working through his very first program example. Its a basic MIDlet that displays the color depth, alpha levels, screen size, and free memory on the screen. My problem is that i

  • Issue in iStore.....urgent

    Hi All, I am working on iStore Module.. I have issue in ItemDetail page that displays the item information like Part Number Description Your Price ....etc after that if related items available, it display that item information also in same page My is

  • Enable autoarchiving for Oracle 10g RAC db

    Hello What are the steps to enable autoarchiving for Oracle 10g cluster database? It is currentrly in noarchivelog mode. Thank you, Yelena

  • JDialog

    Hello all, I have JDialog window needs to on fixed position on screen. It should not be resized or moved to new location by user. Help is needed..... THanks

  • DIAdem dac combined with NI PCIe 6259 doesn't send out data

    Hi, I have a NI PCIe 6259 card & DIAdem 11.2.0 (2010 version) on a windows 7 PC. Analog inputs & analog + digital outputs are configurated in MAX 9.8.0f0. (Global virtual channels) When I run a dac, analog inputs works perfect. Both analog and digita