How to include the variable as a part of the sqlStatement in doGet Servlet

How can I get the variable empnum as a part of the sqlStatement. I am getting an error.
String empnum = req.getParameter("empnum"); --Works
out.println("THE empnum IS : " + empnum); -- Works
String dsJndi = "jdbc/OracleCoreDST"; -- Works
String sqlStatement = "select from HR_TABLE where HR_EMP_NUM=empnum";* - Works if empnum is hardcoded.
Thanks so much for the help in advance
KA

Thanks John..! Opened my eyes ;)
Was a bit reluctant with the users repeated basic questions - my bad and apologies.
It should have been
String sqlStatement = "select * from HR_TABLE where HR_EMP_NUM=?";
PreparedStatement pt = c.prepareStatement(sqlStatement);
pt.setInt(1, Integer.parseInt(empnum));
ResultSet rs = pt.executeQuery();though the 1st solution works..!
regards,
~K

Similar Messages

  • How to I print a center footer which includes the word "Page" as part of the Page # of #?

    I want to print out multiple pages when I go to a specific URL and I want to also print a custom center footer which actually prints out the word Page as part of the Page # of #, normally if you choose the specific Page # of # you only get printed out as an example 1 of 2, it does not cause the word Page to be included in the printout?
    a

    Hi Nes,
    This is the second time you are posting a variation on this question.
    I was about to so NO YOU CAN'T...
    but then I thought...
    It is possible to print just parts of a front panel but it is a lot easier to do the things others have suggested.
    If you really want to print just a part of the FP you will have to do a lot of coding and the GUI will do some strange things in the process.
    I will outline the process and leave the code as an exercise for the reader.
    Using property nodes determine where on the FP the objects of interest are located.
    Again using property nodes, move the objects around on the FP so that they are grouped together and sized such they fit on a printed page.
    Using property nodes adjust the screen size origin etc so only
    the objects of interest are now visable.
    Using.....nodes print only the visable part of the screen.
    Using....nodes put everything back where is was when you started!
    Like I said, this is not easy.
    The simplest solution was suggested by BJD who said group the objects of interest on a tab page, use an invoke node to get the image and then display it on the FP of a sub-VI set to print on completion. That method will let you quickly add new interesting objects to the print out without having to change the sub-VI.
    Trying to help,
    Ben
    Ben Rayner
    I am currently active on.. MainStream Preppers
    Rayner's Ridge is under construction

  • How do i put a cover on the album when the album isnt a part of the itunes store?

    How do i put a cover on the album when the album isnt a part of the itunes store?

    fishmore wrote:
    BUT the image didn't actually work and all I ended up with was the word JPEG and a generic image... Any assistance would be appreciated - Thank you.
    Sounds like you copied an icon from the icon spot in a Get Info window for an image file, then pasted that intoo the same spot in the Get Info window for your folder. As you found out, that won't work - unless the image file already has a custom icon, that is.
    Visually, it's hard to tell if an image file has a custom icon, particularly if View Options for a folder (or the desktop) has been set to 'show icon preview' - the OS will use Preview to make an icon for that file 'on the fly', but it does not really exist as far as being a copyable icon.
    For what you want to do, the solution is really very easy.
    Do a Get Info on the image file whose icon you want to copy for your folder. In that Get Info window is a larger depiction of the image about halfway down - double-click that, and it should open in Preview.
    Press Command-A (that's Select All in the Edit menu).
    Press Command-C (that's Copy in the Edit menu).
    Close Preview, close the Get Info window for the image file.
    Open the Get Info window for your folder.
    Select the icon in the upper left by clicking it once - a blue border should appear around it.
    Press Command-V (that's Paste in the Edit menu).
    Close the Get Info window, and you're done.
    Comment - that's a nice way to make unique folder icons, but there is one drawback: how to distinguish visually between a folder with such an icon and an image file.
    One way, old school, is to append the character ƒ to the end of the name you give the folder. That character is easily generated by pressing Option-F and can be a visual indicator that the item is actually a folder and not an image.

  • Using "View Selector" in the List View Web Part, changes the web part page to the view selected's page.

    Hi,
    I am relatively new to Web Parts pages.  I created a page with list view web part and a Infopath Form Web Part, which are connect via the "Get Form From" option.  My users would like to be able to use views dependent on what
    they are looking for.  So I created different views.  However, when I select the view from within the Web Part, it changes the web part page to the list view page.  I must be doing something wrong.  How do I configure the list view to show
    the selected view and results within the existing "list view web part"?
    Thanks,
    Dwayne

    Hi
    Lindali,
    Sorry, but this has not been answered to my liking.  The "List View Web Part" has the ability for the user to select the view from within the web part, so there you should be able to select a different view and have it appear within the same web part. 
    Does anyone know how to complete this task?
    Thanks,
    Dwayen

  • Why is the Mac App Store part of the OS?

    After reading about issues a lot of people are having with the 10.6.6 update, I think I'll pass on it. I don't understand why Apple made the Mac App Store part of the system software. Why couldn't it be in iTunes like the iTunes & App store? Is Apple acting like Microsoft and pushing stuff on us that we may not want as part of the OS?

    Sean Foley wrote:
    There is something wrong with this. I hate when someone is pulling a fast one and think they are getting away with it.
    What specifically do you believe Apple is getting away with? Basically, Apple is extending the same OS-level features to third party developers that in the past it has reserved for its own apps, including one-click download, security checks, & installation. Moreover, the terms & conditions of use are readily available, as is the same Help topic support as with any other Apple app -- all you have to do is read it.
    Sure, you have to buy many of the apps in the Mac App Store, but what is slimy about that? Doesn't the word "Store" tell you that?
    Does anyone know where to search for all those great applications now, or is getting a new OS the only answer.
    Try a Google search on "Mac apps," or any of the related searches found at the bottom of the search results page.
    And at least for now, http://www.apple.com/downloads/macosx/ still works in the same way it always has.

  • SharePoint 2013 web service: Error while sending claim based authentication request (The corresponding SID in the domain is not part of the intended account type)

    We are using .asmx services for SharePoint features such as comments, and rating.
    Service
    Feature   used
    http://<<hostname>>/_vti_bin/socialdataservice.asmx
    Commenting, Rating
    http://<<hostname>>/_vti_bin/UserProfileService.asmx
    For out of box workflows
    In SharePoint 2013,
    SharePoint – 80  web application is on claims based mode and user is logging in with windows authentication. With logged-in client context used to call SharePoint's default web service, we are getting below error message from
    web service (Social data and user profile services).
    Server was unable to process request. ---> The corresponding SID in the domain is not part of the intended account type.
    When the service is accessed using console application with Visual Studio credentials (logged in user), we are able to access the service. Below is the code snippet
    using   (SocialDataService
    service = new  
    SocialDataService())
                      service.Credentials =
    CredentialCache.DefaultCredentials;
    SocialCommentDetail detail =   service.AddComment("<<url>>",
      "Test Comment",
    null,  
    null);
    Are SharePoint 2013 web services not supporting request coming with claim based authentication web application?
    Thanks, Pratik Agrawal (MAQ Software)

    While this applies to 2010, I believe the same is true with 2013:
    http://social.technet.microsoft.com/Forums/sharepoint/en-US/925e5f46-317f-46d3-bc55-c67f07eb2372/call-sharepoint-web-services-using-claimbased-authentication?forum=sharepointgeneralprevious
    Trevor Seward
    Follow or contact me at...
    &nbsp&nbsp
    This post is my own opinion and does not necessarily reflect the opinion or view of Microsoft, its employees, or other MVPs.

  • My Mac is a 21.5-inch Late 2009 with a 1 TB Seagate HD that must be replaced, according to Apple support, but they denied me that right because the serial is not part of the replacement program: any suggestions to get a plausible solution to this problem?

    My Mac is a 21.5-inch Late 2009 with a 1 TB Seagate HD that must be replaced, according to Apple support Panama, but they denied me that right because the serial is not part of the replacement program: any suggestions to get a plausible solution to this problem?
    I would want to know what are the criteria used by the people al espresslane support to deny the opportunity presented by the replacement program, given the situation that these 1 TB Seagate HD´s have had problems and certainly not only in the batch they accepted, but probable in other batches too.
    The second question is about the powerpc support that is lost when updating from Snow Leopard to Lion X: I can not read my medical application UPTODATE.
    I hope that there wil be some kind of support to help me solve that problem, this is my first petition actually.
    Now, I do not have access to my yahoo email, intermitent access to Apple home page, unpredictable access to Apple store and no access to iCloud in my iMac: when I try to access these web sites, the blue web address bar is interrupted and never goes to the end, no filling up the whole bar.
    I do not know what is the first problem, the Seagate HD or the Lion X, but my life is becoming a miserable one, not having the opportunity to enter in the raplacement program, losing the powerpc support because of the updating to Lion X, the necessity to buy Lion X again because it used to appear as a paid program, but not anymore, and finally having no access to my yahoo email, Apple home website and Apple store and no access at all to the iCloud: I am done.
    Chao, Elías.

    You can have Apple or a competent service shop replace the internal HD for a fee, unless you have AppleCare and the iMac is within its warranty period in which case it will cost nothing. If you must pay the cost will be approximately $350 US.
    PowerPC support is gone with Lion. You can install or retain Snow Leopard on another partition, and boot Snow Leopard as necessary.
    The inability to load web pages is a different problem, unless it is related to your failing hard disk.

  • Report Painter - disable the variable from being diplayed on the selection

    Hi guys,
    I' using variables Fiscal Year 1GJAHLJ  and Previous Year 1GJAHVJ in my report, but the variable 1GJAHVJ is  displayed on the selection screen as Current Year, which confusing the users who are running the report.
    Can I change the description of the variable (GS12 didnt work) or completely disable from being displayed on the selection screen.
    You input is very valuable.
    Thank you
    Regards

    Use 1GJAHR and 1GJAHVJ variables for Current Fiscal Yr and Previous Year respectively.
    1GJAHVJ ( = '&1GJAHLJ'-1) is a dependent of what you input as Current Year, therefore, no need to manually enter for previous year.

  • I'v downloaded a tv series,paid for it, its in my itunes but with exclamation marks next to it, every time it tries to download the series it says "part of the file seems to be corrupted" and tells me to redownload it.Tried that and it comes up the same.

    I'v downloaded a tv series,paid for it, its in my itunes but with exclamation marks next to it, every time it tries to download the series it says "part of the file seems to be corrupted" and tells me to redownload it.Tried that 8 times and it comes up the same. What do I do?

    Clear the contents of ...iTunes\iTunes Media\Download and try one more time.
    If the problem recurs use the "report a problem" links in your account history and explain what has happened so far. There may be a problem with the source rather than your download of it.
    tt2

  • Having trouble downloading photoshop elements 12 on windows. Can't get past the installing sharing technologies part of the download. It just goes on for hours.

    Having trouble downloading Photoshop elements 12 on windows. Can't get past the installing sharing technologies part of the download. It just goes on for hours. Don't get error message but it won't finish download. Help please.

    بتاريخ ١٧/٠٨/٢٠١٤ ٤:٥٨ ص، جاء من "akpsjones" <[email protected]>:
    having trouble downloading photoshop elements 12 on windows. Can't get
    past the installing sharing technologies part of the download. It just goes
    on for hours.
    created by akpsjones in Downloading, Installing, Setting Up - View the
    full discussion
    >

  • I put together and sent 10 pictures from my granddaughter's birthday party. Is there a way of sending them with a link recipients can click on, rather than having all the pictures download as part of the email message?

    I put together and sent 10 pictures from my granddaughter's birthday party. Is there a way of sending them with a link recipients can click on, rather than having all the pictures download as part of the email message?

    Hello userlarry, do you have Mobile Me? You could use that. Or you could compress them, you would still need to send them in an email, but it would help with size limitations of emails.
    To compress them, put them in a folder and right click on the folder. You should see a Compress option. Then just drag the .zip file into your mail.
    Regards,
    Graham

  • How to use the variables of Function exit in the include program

    i have a problem of using the variables of a function exit in the include program..
    If i use those variables there will be an error indicating 'Field FEBVW_IN is unknown. It is neither in one of the specified tables nor defined by a DATA statement'. Please help... Below is the code of the function exit:
    FUNCTION EXIT_SAPLIEDP_202.
    ""Lokale Schnittstelle:
    *"  IMPORTING
    *"     VALUE(IDOC_CONTROL_INDEX)
    *"     VALUE(IDOC_DATA_INDEX)
    *"     VALUE(FEBVW_IN) LIKE  FEBVW STRUCTURE  FEBVW
    *"     VALUE(FEBKO_IN) LIKE  FEBKO STRUCTURE  FEBKO
    *"     VALUE(FEBEP_IN) LIKE  FEBEP STRUCTURE  FEBEP
    *"     VALUE(FEBRE_IN) LIKE  FEBRE STRUCTURE  FEBRE
    *"     VALUE(FEBPI_IN) LIKE  FEBPI STRUCTURE  FEBPI
    *"  EXPORTING
    *"     VALUE(I_FIMSG) LIKE  FIMSG STRUCTURE  FIMSG
    *"     VALUE(FEBVW_OUT) LIKE  FEBVW STRUCTURE  FEBVW
    *"     VALUE(FEBKO_OUT) LIKE  FEBKO STRUCTURE  FEBKO
    *"     VALUE(FEBEP_OUT) LIKE  FEBEP STRUCTURE  FEBEP
    *"     VALUE(FEBRE_OUT) LIKE  FEBRE STRUCTURE  FEBRE
    *"     VALUE(FEBPI_OUT) LIKE  FEBPI STRUCTURE  FEBPI
    *"  TABLES
    *"      IDOC_CONTROL STRUCTURE  EDIDC
    *"      IDOC_DATA STRUCTURE  EDIDD
    *"      IDOC_AVIP STRUCTURE  AVIP OPTIONAL
    *"      IDOC_AVIR STRUCTURE  AVIR OPTIONAL
    *"      IDOC_AVIT STRUCTURE  AVIT OPTIONAL
    *"  CHANGING
    *"     REFERENCE(IDOC_AVIK) TYPE  AVIK OPTIONAL
    *"  EXCEPTIONS
    *"      PROC_ERROR
      INCLUDE ZXF08U10.
    Here is the code for the include program.
      INCLUDE ZXF08U10
    MOVE febvw_in TO febvw_out.

    Sometimes you will get this error message when checking include code in exits even though there is really no error - it happens because the include does not realise it is in the function due to the navigation index being out of date.
    Try activating the code - it may work even though the check said there were errors.
    You can also get this issue when trying to drill down on the field in the include to view its structure.
    Andrew

  • How to Include Date variables in the Attachments sent via ibots

    Hi Experts,
    I have a requirement that when i configure an i-bot , i need to get a mail with attachment as an excel say "attname".This is fine,but how to customize such that the attachment contains date variables like "attname_24April2010" when recipients receive the mail?
    Also if this is possible then when i open the attachment, then it should have the title with report name and date variables? Can we achieve this?

    You can put varables in several views in OBIEE (e.g., Narrative, Title, etc.). BTW, in the Title View, you can also use built-in variables that display the run date and time.
    Click on this link to get the syntax:
    http://shivabizint.files.wordpress.com/2008/10/obiee-variables-overview.jpg

  • How can I burn just a selected part of the project to DVD?

    Afternoon all,
    we downloaded a number of clips from our HDV that we wanted to use in making a short movie (1 hour's worth of clips will end up being a movie of about half that length). After doing that, we decided to do a 'preview' of 2 minutes worth of mixed clips (5 in total) with music.....I made a new copy of the whole project and then deleted everything that we didn't want from the original collection of 1 hours worth of downloaded clips so that the project just left 2 minutes worth of clips.
    When we tried to burn this 2 minutes to DVD it seemed to be trying to do the whole project including a whole lot of nothing where I've deleted everything.
    Could you please tell me how to select only the 2 minutes worth of 5 clips and audio so that I can burn only that bit to DVD and also upload it to YouTube.
    A million thanks from a challenged newbie who can't find any instructions for doing this..
    JON

    Jon,
    It sounds like you did, just as you should, Save_As and Delete everything that is unwanted. If you did the Deletion from the Timeline, there should be nothing from the old Project, that should be included. A DVD is Transcoded and burned from the Timeline. If the Assets are not there, they will not included in the DVD, even if you did not Delete anything from the Project Panel.
    Tell us about the Clips now on your Timeline. Also, can you check the Timeline, by hitting the \ (Backslash key), and looking near the end of the Timeline. Do you have any "orphans" out there? Check all Video Tracks, even if you have to scroll to see them all. Does the Duration of the Timeline (viewed in the Program Monitor) match what you think that it should? If not, then you most likely have orphans, that you missed Deleteing.
    Good luck,
    Hunt

  • How can I select only a small part of the image to clone or edit etc?

    I want to select part of the image to clone is, and just edit the selected part. I know i can do this on photoshop but how do i do it on Aperture?

    You use the "Retouche" brush in Aperture and set it to "clone".
    Option-Click on the location you want to clone from to select a source, and then brush over the location where you want to clone to. The cloned region will follow the shape of the brushed area. You do not lasso the shape to to copy and paste it like in Photoshop.
    For example: Duplicating a penguin: The sourcepoint has been set to the beak of the second penguin, and then I brushed along the path where I want to penguin clone to appear.
    If I brush the whole area eventually the penguin will be copied completely. You'll have to experiment a bit with the brush size and softnees to ensure that the cloned object will blend in.
    Regards
    Léonie

Maybe you are looking for

  • Can't update anything from CC on any of my machines

    Process:         Creative Cloud [275] Path:            /Applications/Utilities/Adobe Creative Cloud/*/Creative Cloud.app/Contents/MacOS/Creative Cloud Identifier:      com.adobe.acc.AdobeCreativeCloud Version:         1.5.0.367 (???) Code Type:      

  • Error while shopping cart creation

    Hi All, We are on SRM 7.0 and ECC 6.0. We have just recently set up our SRM 7.0 system along with the portal. SSO, UWL etc have been configured in the Portal. Now when the user logs in to create a shopping cart and clicks on the 1. Employee Self Serv

  • Best practice when developing APEX apps and using a SVN repository

    Hi experts, I wanted to get your opinion on best practice regarding how to use SVN and APEX combined. The idea is basically how to structure and how to save APEX apps the best way in a repository. I am currently working with a custom SVN structure, n

  • Same idoc to multiple EDI receiver system using rule

    Dear Friends!   Good day!  I am using desadv.delvry03 idoc and I want to send same idoc from same communication component to multiple receiver parties without mapping. I have created first scenario successfully using idoc, when I create another scena

  • Best Practice: Correct Use Tax Calculation

    Hello, Our company is wanting to find out how other companines handle the below business process scenario involving use tax: Company orders 100 units of materials for delivery to location A.  Tax is calculated on PO based on location A ship-to addres