Please help to build an sql from the given expression to build case condition with Where clause

if  @rollno is not null then
Select top  1 studentid  from student where rollno =:@rollno
else
if @regno is not null then
Select top  1 studentid  from student where regno =:@regno
Please help me to create  the above condition as  a single  sql statement . I will pass two argument in to the sql.
With Thanks
Pol
polachan

Select top 1 studentid from student
where (rollno =:@rollno or :@rollno is null)
and (regno =:@regno or :@regno is null)
The above expression will work in SQL server
I'm not sure you're using sql server as syntax like :@regno are not t-sql valid
so you can try the above and if it doesnt work please try in the relevant forums for more help in case you're using a different RDBMS
Please Mark This As Answer if it solved your issue
Please Mark This As Helpful if it helps to solve your issue
Visakh
My MSDN Page
My Personal Blog
My Facebook Page

Similar Messages

  • I have forgotten the answers to my security questions please help, i cannot purschase anything from the appstore without it

    i have forgotten the answers to my security questions and cannot purchase anything from the appstore witout it please help!

    Security questions come under the KISS theory...
    Like...
    Color of my first car.  If you don't remember the color of your first car, pick another simple question.

  • Please help me shut down imessage from the computer?

    Hello,
    I've recently sold my Iphone and unfortunatelly iMessage is still activated on it so I'm not receiving messages from my Iphone friends... I've tried and deleted the phone as one of my products on apples account but this didn't helped I have my apple account info and the serial number of the phone as well as the telephone number it's connected to... Thank you in advance for any help guys!
    Apple account: [email protected]
    Serial number: 7R1131M4A4S
    Phone number: +46 761110115

    Asked and answerd many times...
    http://support.apple.com/kb/ts5185

  • When I tgry to drop a video from the main screen to a time line with no secuence i receive an error with no number, just tell me the progran stop working and the program closes can you help me please

    please someone who help me please
    when I tgry to drop a video from the main screen to a time line with no secuence i receive an error with no number, just tell me the progran stop working and the program closes

    You need to help us first ...
    Computer specs:
    OS, CPU, RAM, GPU, vRAM ... and also disc layout & connections can be useful (as in, "2 internal hard-drives and an external on Thunderbolt connection for exports")
    Program specs:
    Specific build of Premier Pro from the bottom of the "About" splash screen off the "Help" menu is best.
    Footage file type: MXF, AVCHD, MOV, m2s, what?
    Even the camera it was shot on can be of interest at times.
    And did you use media browser to import, then project panel to drag & drop?
    Neil

  • The enter key is not working in firefox but it has working fine in chrome and IE so please help me to rid out from this.

    The enter key is not working in firefox but it has working fine in chrome and IE so please help me to rid out from this.

    Hello gokulaan, '''try Firefox Safe Mode''' to see if the problem goes away. Safe Mode is a troubleshooting mode, which disables most add-ons.
    ''(If you're not using it, switch to the Default theme.)''
    * You can open Firefox 4.0+ in Safe Mode by holding the '''Shift''' key when you open the Firefox desktop or Start menu shortcut.
    * Or open the Help menu and click on the '''Restart with Add-ons Disabled...''' menu item while Firefox is running.
    ''Once you get the pop-up, just select "'Start in Safe Mode"''
    '''''If the issue is not present in Firefox Safe Mode''''', your problem is probably caused by an extension, and you need to figure out which one. Please follow the [[Troubleshooting extensions and themes]] article for that.
    ''To exit the Firefox Safe Mode, just close Firefox and wait a few seconds before opening Firefox for normal use again.''
    ''When you figure out what's causing your issues, please let us know. It might help other users who have the same problem.''
    Thank you.

  • Help Please - having difficulties creating af link from the text to an attached file i acrobat

    I have been reading the help, but it just wonn't work when I try.
    I have tried as followed (I am working with a danish version, and hope to matched the same word as in the english version of Acrobat Xpro):
    1. From the toolbox i choose content and then 'hyperlink'
    2. I mark the text from which i wish to make a link
    3. Acrobat respond with an popup picture 'create a link'
    4. From the popup I mark 'Open a side' and push 'next'
    5. Acrobat respond with a new popup picture 'create / go to a side'
    6. I go to the navigator and open the list with attached file's that I have embedded in my acrobat file.
    7. I mark the to which i wish to make a link to
    8. In the popup 'create / go to a side' that stilll is open, i push 'Mark hyperlink'
    Then I hoped that I have created a link from the acrobat text to the attached file. In stead Acrobat has made a link to the same sidenumber that respond to the text from which i wish to make a link . F.ex. the linktext is on side 10 - then the link goes to side 10.
    How do i do it right?
    Please help.

    Hello Bernd
    Thanks for a quick respond.
    This corresponds to the text I have tried myself, but apparently I do something wrong
    1.      Open a PDF that contains a PDF file attachment – done
    2.      Go to where you want to create a link. If that location is in the file attachment, click the Attachments button in the navigation pane, select the file attachment, and click open.
    Here I go to side number 10 from which I wish to make a link from (I am not open the attachment file at this moment, as the location not is inside the file attachment).
    (I earlier also tried to  mark the attachment file and click open, and It result that the attached file just opened normally without creating a link to the file).
    3.      Choose Tools > Content > link, and select the area for the link
    Here  I mark the text on side 10 from which I wish to make a link to a attached file
    4.      In the Create Link dialog box, set the link appearance, select Go To A Page View, and then click Next
    Here I have selected ‘Go to a page view’ as told and I click Next
    5.      Set the page number and view magnification you want, either in the parent PDF document or in the file attachment, and then click set link.
    Here I go to the navigation pane and mark the attached file from the file list (the files in the list hasn’t any side number in the list) and then I click Set Link.
    Then I hoped that I have created a link from the acrobat text to the attached file. In stead Acrobat has made a link to the same sidenumber that respond to the text from which i wish to make a link . F.ex. the linktext is on side 10 - then the link goes to side 10.
    What do I do wrong.?
    Med venlig hilsen
    Mogens Pedersen
    Specialkonsulent
    T 33 63 13 07
    F 33 63 10 11
    [email protected]<mailto:[email protected]>
    Fra: Bernd Alheit [email protected]
    Sendt: 2. marts 2012 13:11
    Til: Mogens Pedersen
    Emne: Help Please - having difficulties creating af link from the text to an attached file i acrobat
    Re: Help Please - having difficulties creating af link from the text to an attached file i acrobat
    created by Bernd Alheit<http://forums.adobe.com/people/Bernd+Alheit> in Creating, Editing & Exporting PDFs - View the full discussion<http://forums.adobe.com/message/4241290#4241290

  • Please can someone help,i bought an iphone from the states,i put a sim in ,i could make phone call,but i couldnt surf ,it seems that something is wrong and when i click on wireless nozhing happen,

    please someone help i bought an iphone4 from the states, i put the sim card in, icould make a phone call,thats ok but i couldnt open the opera,and when i click on wireless on buttom nothings happen.

    Are you talking about an unlocked version?  If an iPhone is locked to AT&T in the U.S., anyting is fair game outside of AT&T's network. (You can always use WiFi, though.)

  • For those who have problems RE: My iPhone 4 on connecting to my pc shows my friends name in the DIGITAL camera Drive..It dsiplays my correct name when I`m on iTunes..PLEASE HELP ME HOW DO I CHANGE THE NAME IN THE DIGITAL CAMERA DRIVE??

    For those who have problems RE: My iPhone 4 connecting to my pc shows my friends name in the DIGITAL camera Drive..It dsiplays my correct name when I`m on iTunes..PLEASE HELP ME HOW DO I CHANGE THE NAME IN THE DIGITAL CAMERA DRIVE??
    SOLUTION:
    Iam pointing t0 windows7 os.
    1) go to control panel
    2) open hardware and sound
    3) In that open Devices and printers
    4)In that u can find Apple Iphone.
    5) now right click on this --> Hardware --> Properties --> General --> Uninstall --> ok.
    6) now unplug and plug in ur iphone again.There u go u iphone name changes to its original name.

    I am having this problem.  At first with the new iPhone 5, and then with the iPad 2.  I am not sure why this is happening. 
    My gut feeling is this is an iO6 issue and here's why -
    The problem mainly occurs with apps.  I have about 150 apps, and when I plugged in the phone, iTunes went to sync all of them.  The process would hang up after about 20 - 30 apps were loaded onto the phone. I could tell where about the process hung up because the apps on the phone showed up as "waiting".
    Then on the iPad 2 I plugged in to sync and saw there was a huge "Other" component in my storage.  It required me to restore the iPad 2 from backup.  With this restore the same issues occurred - putting the apps back on the iPad would hang up.  The videos on the iPad also got stuck - maybe after about 10 hours of videos transfered iTunes crashed.
    My solution has been to soft reset the device, restart Windows, and continue the process until it's complete.  This is remarkably inefficient and time-intensive but everything works with patience.
    I have been wondering if others have had these same problems. 

  • Please help me to understand what is the meaning of Acess point Channel utilization?

           please help me to understand what is the meaning of Acess point Channel utilization? If i want to mange the capacity of my Office Wi-Fi network what are the factor i need to monitor.

    Hi Ankit,
    Channel Utilization
    The 802.11, 802.11b, and 802.11g standards use the same 2.4 GHz band. All must interoperate with each other, which introduces additional overhead reducing channel throughput. Many sites already have products using the Wi-Fi 2.4 GHz band. Additionally, there are many other products that use the same 2.4 GHz frequencies as used by Wi-Fi. Other products include Bluetooth, cordless phones, video game controllers, surveillance cameras, and microwave ovens.
    Before the installation of the Cisco Unified Wireless Network, a site can be tested for channel interference and utilization with tools from AirMagnet, Wild Packets, Cognio, and others. The Wireless Control System (WCS) AP On-Demand Statistics Display report provides a spectrum review of the following:
    •Noise by channel
    •Interference by channel
    •Client count versus RSSI
    •Client count versus SNR
    •Channel radar detection versus time
    You can further refer the following links,  
    https://supportforums.cisco.com/thread/2212228
    https://supportforums.cisco.com/thread/334981
    For design guide following link might help,  
    http://www.cisco.com/en/US/docs/solutions/Enterprise/Education/SchoolsSRA_DG/SchoolsSRA_chap5.html

  • I have been backing up  since 2010 but my machine will only go as far back as feb 11 ... why is this? please help i need valueable info from 2010

    i have been backing up  since 2010 but my machine will only go as far back as feb 11 ... why is this? please help i need valueable info from 2010

    Welcome to the discussion area!
    When the Time Capsule disk starts to become full, Time Machine will automatically delete the oldest backups first to make room for new backups.
    For more details, I think you will get a faster and more informed response if you post in the TIme Machine forum for questions like this. We primarily handle configuration set up and networking questons about the Time Capsule as a hardware device on this forum, but it's possible that someone may see your post and respond from here as well.
    Please click the link below and then click the "Refine this list" 'button to see the Time Machine area.
    https://discussions.apple.com/community/mac_os/mac_os_x_v10.6_snow_leopard?categ oryID=263

  • PLEASE Help! - Bridge and Premiere CC- "the operation could not be completed" and export error - MAC

    Dear Adobe Community,
    I got my first imac a few days ago, and i decided to install Adobe CC.
    When i want to run Adobe Bridge, says "the operation could not be completed", the same happens with Adobe After Effects.
    And I also have a problem with Premiere, when i want to export a project says that premiere must close.
    This is the try version, is this a problem of Adobe or Apple? i'm very worried
    Help!
    Thank you!
    Ivana

    Muchas gracias!!! Ha funcionado!
    El 11/02/2014, a las 00:02, Federico Platon <[email protected]> escribió:
    Re: PLEASE Help! - Bridge and Premiere CC- "the operation could not be completed" and export error - MAC
    created by Federico Platon in Foros de usuario a usuario - View the full discussion
    Confirma que se trata de una cuestión de permisos.
    Por cierto te aconsejos actualices la 9.1  a 9.2, posiblemente se habría arreglado así también.
    Bueno los pasos son:
    2. Select Go from the Finder Menu.
    3. Select Computer.
    4. Select Macintosh HD.
    5. Select Users.
    6. Select your user profile.
    7. Right click on user profile. Select Get Info.
    8. Go to bottom and unlock with admin password to make changes.
    9. Make sure your user profile has Read and Write privileges by selecting from dropdown menu.
    10. Go down to wheel at very bottom and select Apply to enclosed items. This should allow Adobe Bridge to run properly.
    Creo que no se necesita traducción.
    Please note that the Adobe Forums do not accept email attachments. If you want to embed a screen image in your message please visit the thread in the forum to embed the image at http://forums.adobe.com/message/6107188#6107188
    Replies to this message go to everyone subscribed to this thread, not directly to the person who posted the message. To post a reply, either reply to this email or visit the message page: http://forums.adobe.com/message/6107188#6107188
    To unsubscribe from this thread, please visit the message page at http://forums.adobe.com/message/6107188#6107188. In the Actions box on the right, click the Stop Email Notifications link.
    Start a new discussion in Foros de usuario a usuario at Adobe Community
    For more information about maintaining your forum email notifications please go to http://forums.adobe.com/thread/416458?tstart=0.

  • Please help me transfer purchased apps from my current ios6 to new ios7 program.

    Please help me transfer purchased apps from my current ios6 to new ios7 program.

    There is no need to transfer anything.
    Update the device via iTunes or Over the Air... no content on the device should be affected.
    If the device is used as designed and regularly backed up to iCloud or iTunes on the computer, should anything go wrong it can be restored.

  • I have 4s iPhone , I download the iOS 7. Now the front receiver microphone is not working , please help me that how to fix the problem.

    I have 4s iPhone , I download the iOS 7. Now the front receiver microphone is not working , please help me that how to fix the problem.

    I live in South Africa, and I had the same problem with my iPhone 4.
    After weeks of frustration and swearing, I was in the process of restoring my phone to a previous iOS. To do that you need to turn the "Find my iPhone" option off, since i turned it off, my problem was solved. No need to repair anything or revert back to old iOS.
    ***** that i cant use Find my iPhone, but atleast i can use my phone.

  • I am using Adobe Pro 11 and on opening a pdf I am getting error 'Insufficient Data for an Image'. Please help and provide a workaround if the solution not there.

    Hi all,
    I am using Adobe Pro 11 and on opening a pdf I am getting error 'Insufficient Data for an Image'. Please help and provide a workaround if the solution not there.
    I have already set the preferences to for page view to low zoom settings, and page fit view settings, but it never opens the pdf. Please check and provide a solution asap.
    Thanks in advance!

    Most of the documents have sensitive info on them.  I will have to do some looking for some that i can share, but will get something to upload (dropbox) as soon as I can.
    Thanks for you help.

  • Hi, please how can I transfer purchases from the app store on Mac to my iPad ? I purchased  keynotes, numbers ,pages and other items. I really want to have them on my iPad . Thanks.

    Hi please how can I transfer purchases from the app store on Mac to my iPad . I downloaded  keynotes , numbers, pages and others and will want to have them on my I pad thanks.

    Apps that are written for the Mac OS cannot be used on iOS devices, such as the iPad. You can purchase the iOS versions of some of these apps in the iTunes App Store.

Maybe you are looking for

  • How do i delete songs using iTunes from macbook pro

    i synced my iphones to a new i tunes library and now i have three unwated songs how do i delete them?

  • Payment Wizard Run does not create Payment/Check

    Does anyone know possible reason/s, why payment wizard run will not create payments and checks? The wizard goes up to Execute Step, after execution, it shows:           0 Payments Created           0 Checks Created I have compared settings (Banking,

  • Why buffer Hit greater than 100% in AWR

    hi, could anyone help explain why the buffer Hit is 376.58%, greater than 100% in my AWR. oracle version is 10.2.0.3.0. thanks! Instance Efficiency Percentages (Target 100%) ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~             Buffer Nowait %: 

  • Spry horizontal navigation element covers flash element...

    i have a spry navigation bar with a flash movie underneath, and when i hover over the navbar and the submenu pops down it covers the flash movie, but it doesn't cover the .jpg image that is next to the flash movie. how can i fix this? thanks.

  • Barcode,se​lect type automatica​lly

    Hi, actually i am thinking that whether we can make a VI that will decode a barcode without user to select the type of barcode... given that with the condition that  the user doesnt know the type of the barcode..... And this is the example of the 1D