Problem of application of construction...

I have a setting in my proc called xParam and I try to incorporate in one of my sliders. Here is my current cursor:
select *
from tablex
where id in (1,2) and xParam = 'ALL' or
          id = 1 and xParam = 'FIRST' or 
          id = 2 and xParam = 'SECOND'
and     com_sec = 3
So, basically, what I'm trying to do is have the cursor include all lines of tablex where IDs are 1 and 2 If the value passed in xParam is 'ALL', include all the lines where id is equal to 1 if the value passed in xParam is 'FIRST', etc..

Oracle: 10g

Some examples of data to give a better idea:
--tablex

ID    COM_SEC   FNAME   LNAME
1            3         Bob       Johnson
2           3          John       Smith
1            2         Chris       Carter
1           2          Bill          Curtis
2           3         David        Lee
2           2         Brett        Nicks
If the value passed xParam is 'ALL' I want to include all of the data in the table, if the value passed to the parameter's 'FIRST' I want as the next set of results:
ID    COM_SEC   FNAME   LNAME
1            3         Bob       Johnson

--Result set if xParam is 'SECOND'
2           3          John       Smith
2           3         David        Lee
So my question is that my request generated correctly? The instructions 'or' in the slider will work the way I need them for (aka to achieve the desired result). The reason I ask is b/c the statements do not seem to work correctly in my real proc the way I want to that they.

Published by: user652714 on December 29, 2009 09:15

user652714 wrote:
I have a setting in my proc called xParam and I try to incorporate in one of my sliders. Here is my current cursor:

Discover the parenthesis. They work the same way in math ;)

select  *
  from  tablex
  where xParam = 'ALL'
     or (id = 1 and xParam = 'FIRST')
     or (id = 2 and xParam = 'SECOND')
/

Or if you use:

select  *
  from  tablex
  where id = case xParam
               when 'ALL' then id
               when 'FIRST' then 1
               when 'SECOND' then 2
             end
/

SY.

Published by: Solomon Yakobson on December 29, 2009 09:19

Tags: Database

Similar Questions

  • Serious problems or applications for construction

    I have tried to build an application but cannot do run without errors very waves

    The simplest example of an exe with the problem, it is a single, including a digital control, the NI_AALBase.lvlib Mean.vi and a digital indicator for the outcome.

    My first attempt, before including Mean.vi as dynamic/support vi gives the message:

    "lack of Subvi NI_AALBase.lvlib:Mean.vi in viname.vi" (viname is the name of the vi I built

    Once included in the dynamic source files & support section the message "helpfully" becomes:

    "The VI is not executable. The full Version of labview development is necessary to correct the errors. »

    As with other instances of this on the forums the VI is perfectly OK on the machine, with which it was built.

    I'm dead certain that he is associated with the screws of NI_AALBase.lvlib and NI_AALPro.lvlib as there is a message in double 'useful' for each instance of the any of them in VI.

    What are these messages arranged by and how to solve?

    I checked that the dll is included in the record of support for the building, and I even tried to copy the dll and the rough live + vilibs in the correct relative locations on the pc on which I'm trying to install.

    I'm completely puzzled help (or documentation?) would be greatly appreciated!

    My labview is 8.2.1

    See you soon

    Dan

    It turns out the original 8.2.1 TIME I installed was not correct - I can't realize... a few screws would go with it but not those with the screw inside analysis. Somehow the installation was absent from most of the components (not actually offer to install * all * but always installed in the heart of the runtime)

    Redownloaded the 8.2.1 package and installed from scratch... problem solved.

    Errors of diagnosis could be much better for that - if she had told me that I didn't have the appropriate runtime installed he recorded one day...

    Thanks for the help guys

    Concerning

    Dan

  • Problem with applications of discount shaped on Apple Watch my daughter

    Not too long ago, my daughter won a Apple Watch of our local orthodontist. This is a fun gift for the do - http://miamiorthodontist.com/miami-invisalign-provider-february-2016-contest-win ner /

    Anyway, she has problem with applications to fitness form/heart rate on his Apple Watch. Could it be because she wears it too tight or too loose on her wrist?

    Hello

    Yes - your daughter might be affected by problems due to wear his watch with a bad fit.

    For best results when the monitoring exercise, it is important that the watch to fit comfortably against the top of his wrist. To help with this, Apple suggests that users clamping shows before workouts and he release again thereafter.

    General daily wear, for best results of functions which the detection of the wrist, the Taptic engine and the heart rate sensor, the back of his see also needs to be in contact with his skin. Wear it with the right person (neither too tight nor too loose, with room for his skin to breathe) should be comfortable enough, allowing the sensors work correctly:

    More information:

    Use the activity on your Apple Watch - Apple Support

    Use of the workout on your Apple Watch - Apple Support

    Your heart rate. What it means, and where on Apple Watch you will find. -Apple Support

  • Problem with Application.cfm

    Hi all
    I am facing problem with Application.cfm file. When I try to use the Application.cfm file, the whole page gets distorted with Internet Explorer. However, the page appears correctly with Firefox. If I change the name of Application1.cfm, the page is properly aligned in Internet Explorer, but my goal to download then fails.
    Any idea, why did this happen.

    Oraa wrote:
    >
    > No idea, why did this happen.
    >

    When you use your file Applciation.cfm view source in the browser and you
    will see the problem. IE is too sensitive to what anyone, including
    white space before the doctype. If the doctype is not the
    very first thing the browser receives, IE will go into quirks mode which
    often radically changes how it renders a web page. Firefox is more
    standards and ignores the outdoor spaces before the doctype.

    The Solution:
    Use one of the whitespace in ColdFusion, such as package management features
    all Applicaiton.cfm your code in a block of ... then
    no space extra is sent to the browser.

    Saves on bandwidth to!

  • Problems of application files

    As a filmmaker, I use a variety of different Applications for my work

    Many apps DON'T work - and also to update or add additional content - only if they are in the APPLICATION FOLDER

    This creates a huge amount of applications in the folder and the pier is crowded and barely visible

    I have subfolders in the form of TEXT, AUDIO. VIDEO. PHOTO. UTILS to reduce congestion, apply for other work, launching ask for return in the application, other do not work.

    I understand that there must be a reason of General programming to do, but it is not convenient for people using many applications (therefore spend a large sum of cash).

    I am using freeware XMENU that gives me a little ability to find these folders in the top tool bar like in the old days in Sys9

    However, the problem persists. Although I alias a few apps and put it in these folders don't some just work properly or even not at all forecing me to use the main folder of the APPLICATION

    Is there a way (perhaps using TERMINAL) to force all applications to work even if they are located in a subfolder in the folder of the Application

    Thank you

    I think that is controlled by the developer of the software. As to why I have no idea, but I don't think there is a setting global, even in using the machine to override how the application was written.

  • IPad after update, problems with applications

    After the Ipad update to 9.1.2, we have a problem, whenever we are entering an App, emails, photos, etc., we lose the connection with the application. We will and simply press a button, then let's just out of the app again. We are unable to read the email, see photo etc. Anyone has a solution for this.

    In addition the application which is suppose to update, will not update

    Hello abcglad,

    If I understand correctly, you are able to open your apps, but what you do in them makes it insensitive so you press the Home button to exit the application, and then go back into it to make it work. This looks like a software issue to me, we should be able to solve. I would start by quit all applications running on your iPad. Normally, simply quit the application affected, but in this case because it seems to be all of them, I'd leave all.

    Force an app to close the iOS

    1. press the Home button twice quickly. You will see small glimpses of your applications recently used.
    2. slide to the left to find the application you want to close.
    3. push upward on the overview of the application to close.

    When you have finished that force the iPad to restart with the Home and Sleep/Wake buttons as described in the following article and the question again:

    iOS: switch off and on (restart) and reset
     
    If the problem persists, save your device in iTunes, then restore it like new and verify that it works.
     
    How to clear your iOS device and then set up as a new device or restore from backups

    If this is the case, restore your backup either check it still works and just reinstalled software or circumvent the problem in the backup file itself. Thank you for using communities of Apple Support, all the best!

  • Problems installing InstallShield of construction after the upgrade of MS 2010

    Hi all

    I've recently updated one of my MS 2009-2010 MS .NET applications. Now that I use MS 2010, my (THE InstallShield with Visual Studio 2010) installer will not compile. Specifically, I get the following errors:

    Error	1	-4072: Error retrieving dependency Microsoft_VC100_CRT_x86. DF495DFD_79F6_34DF_BB1E_E58DB5BDCF2C:0 to c:\program files (x 86) \common files\merge modules\MStudioCommon.2010.msm	ISEXP: error:-4072: Error retrieving dependency Microsoft_VC100_CRT_x86. DF495DFD_79F6_34DF_BB1E_E58DB5BDCF2C:0 to c:\program files (x 86) \common files\merge modules\MStudioCommon.2010.msm.

    Error 2 -4072: Error retrieving dependency Microsoft_VC100_ATL_x86. DF495DFD_79F6_34DF_BB1E_E58DB5BDCF2C:0 to c:\program files (x 86) \common files\merge modules\MStudioUI.2010.msm ISEXP: error:-4072: Error retrieving dependency Microsoft_VC100_ATL_x86. DF495DFD_79F6_34DF_BB1E_E58DB5BDCF2C:0 to c:\program files (x 86) \common files\merge modules\MStudioUI.2010.msm

    Hello Steven-

    I'm going to guess that you have recently installed Service Pack 1 for Visual Studio 2010.  It seems that the SP1 for VS 2010 replaces the two merge modules you mentioned and replaces them with modules to fusion with different signatures.  Because the Studio 2010 measure merge modules were built against the version no SP1 de Visual Studio 2010, the build errors that you see the result.

    I have attached the version no SP1 merge below these modules.  You should be able to add them to your Setup project and did build errors.  Please let me know if you have any problems or questions.

    NickB

    National Instruments

  • Problem running application using odeoslver in Mathscript

    Nice day.

    So, my goal is to create a Labview application (which will be used for the other computer) which allows me to run mathscript code which turns into a calls a function to solve a problem of ode.

    I don't understand why it does not work... I use the "current directory" function to see where Labview is in charge of the search for the function and I introduce later in this directory (manually).

    The application returns the paths, but returns no results in addition to those...

    The program works great when I use it in the application...

    The script function is presented as an image.

    Thanks in advance...


  • Sony Xperia M4 aqua - problem with applications in google play store

    Hello

    I have a problem with some applications in the google game store (for example: MSQRD or world leader). I would like to download them but I can´t find in the google store. If I try to run download them the internet version of the game google store I can find, but there is always something like "your device is not compatible with this application. I had an old phone HTC desice X and I found a statement that I have to keep my old phone. So I did, but it remains doesn´t work. I Don t really know where is the problem.

    Could someone help me please?

    @LucieK

    There is nothing wrong with your phone, the problem is the application, sometimes developers restrict applications for specific phones and/or regions/countries, you need to communicate with them in that regard.

  • Problem with applications blackBerry App

    I understand that the Blackberry Op system is not iOS or Android and I'm not a crazy fanatic when it comes to apps, but there are two that I use regularly and they are a problem - namely Vodacom and ABSA bank.    Is it possible that I don't know to do to get these applications to work on a Blackberry?

    I use 1Mobile android sideload apps Market and found apps both Vodacom and ABSA bank (from ABSA Bank Limited) in 1mobile.com. Here is the link http://1mobile.com/search/?keyword=absa&is_get=1

    But I don't install on myZ30.

  • Problem with 'Application of Test' in the provider Portal

    In step 2 of the new Application Wizard presentation, I think that the feature of "Test application" is broken. It seems not actually display the data, what he says it is.  It does in fact demand, but without the data. I have install a quick PHP script which is simply this:

    
    

    and the answer is:

    HTTP/1.1 200 OKContent-Type: text/htmlContent-Length: -1
    
    Array() 
    

    Even using $_REQUEST gives the same result - is not just a matter of using GET instead of POST or something like that.

    Can it be fixed please?

    Just in case someone else is a similar problem and searching for answers, I sent the RIM and got the following response:

    This was identified shortly after the Dynamic test page went live last Wednesday.  A fix will be included in the next update.
    

    When I followed, noted that the update should be around March 17.

  • Problem of application using Push battery drain

    Hello

    I use push via BIS connection and have an another entry point to manage events to push (the same sample application Blackberry Ant provides). But I need to display popup dialog box whenever I get a push notification, this is why I use the dispatcher lock and event with the other entry point.

    But by using the dispatcher of events with the other entry point my other app continues to run even if it does not receive push messages (I checked the background apps and it showed my replacement), which is causing the battery to drain. Does anyone have an alternative solution or better suggestion for this problem.

    Kind regards

    gmuhammad.

    Found the solution:

    http://supportforums.BlackBerry.com/T5/Java-development/alert-a-BlackBerry-Smartphone-user-from-a-BA...

    You must use the Application instead of the UIApplication class if you want to display popup windows, dialog or background boxes.

    Thanks to: peter_strange

  • Problems downloading applications with error 0x800706ba.

    Whenever I try to download an application, I get the error 0x800706ba. So far, I have not been able to download apps.

    Original title: problem downloading apps

    Hi Mary,

    We can refer to this article and check if that helps.

    What to do if you have problems with a soft: http://windows.microsoft.com/en-in/windows-8/what-troubleshoot-problems-app

    Thank you.

  • Hang the problem with applications. Fixed by going to the taskbar or by minimizing and maximizing return

    Hello world

    I have a weird problem with Adobe applications. Mamy times especially when doing drag or double click, applications get stuck. And if I move my mouse away from the application to the taskbar, it kicks back. Or sometimes I have to minimize and maximize return.

    It happens when I use my Tablet intuos with pen. So if it gets stuck, I noticed as soon as I change the feather to the touch, it begins to function normally. Otherwise, I have to hover on the taskbar or minimize and optimize the thing.

    I tried to re install creative cloud and applications, I tried to delete / re install drivers Wacom.

    not sure if it's a cc or a Wacom or Windows 10 problem. ID appreciate any help. It drives me crazy that am not not able to work.

    I thank nk so

    Hi Irfani7193203,

    Please let us know what Adobe application you talk too much.

    Until then, you can consult the links below:

    Resolve Windows system errors, freezes | Adobe software

    Applications Adobe Creative Cloud close immediately after the launch

    Waiting for your response.

  • LR6 installation problem: Manager application Adobe has closed unexpectedly.

    I have a problem when installing on my Mac of LR6, at the end of the installation Adobe Application Manager crashed. I already control the host, the certification of CA and the firewall file and everything is ok. What can I do?

    Thanks a lot, I solved it by putting the author permission on the folder of the Application Manager.

Maybe you are looking for

  • iOS 10 with Apple tv

    How you turn off mirroring function with iOS 10 and Apple TV? I just he plays on my Apple TV, so I can continue to use my phone or my iPad.  It's very annoying to not have a switch like iOS 9

  • How to prevent the opening evertime I start Firefox 29,0 DictionarySearch add-on

    With this 29,0 update, whenever I run the FF application, the DictionarySearch add-on also opens and I don't want to see it. Before 29,0, DictionarySearch did not open whenever I launched Firefox. How to stop the add-on of DictionarySearch open a tab

  • Satellite L300 - 22 X and recovery disk

    I have a Toshiba Satellite L300-22 X I tried to restore new parameters and he said: I have a missing file, so it can not restore so I turned off my laptop that he loaded a black screen saying: Please insert the disk my laptop didn't come with a disk

  • 1620CDS HARD drive insulator pad

    I stripped (Doh!) my 1620CDS satellite - to change a very noisy fan and reconstruction ended up with a thin wafer rubbery to remember being so ontop of the HARD drive, it seemed to me. However, when the plate is in a position to clear the small hole

  • install the software for my mobile phone gives an error saying I need to install adobe reader, I already

    help with my samsung cell phone I am trying to add software for my laptop LG LW60 that the software program is for my samsung omnia cell phone. the program is SCH-i910, whenever I try to add the software it tells me to download ADOBE READER 8 or late