Parsing a String object that contains the database details in jsp

Hi All,
In my project i have a model which is a bean that contains
a method :-
UserBean.java
....getUserData()
//the database connection is written here.
st.executeUpdate("insert ----------");
In the servlet i am calling the bean,
ControllerServlet.java
UserBean ub=new UserBean();
Object obj=ub.getUserData();
session.putValue("something",obj); //Here the obj contains all the database datas that is used in insert query
//By using RequestDispacher i am forwarding this request & the response
to the jsp page
ViewJsp.jsp
String data=(String)session.getValue("something");
//Here "data" now contains all the database contents that is stored using insert query in the bean
From here i need to parse the "data" in order to display the contents
stored in the string "data" in to a html table.
Plz. do provide a solution for this.It is very Urgent at the moment.
So that i will be very thankful to u.
Thanx,
contactananth

ok, first of all, in getData, i assume you do a SELECT, not an INSERT,
so your bean code should look like:
ResultSet rs = st.executeQuery(...) // or somethig like that
return rs; // it will contain the data you needand in the jsp you write:
ResultSet rs = (ResultSet)session.getValue("something");
instead of
String data=(String)session.getValue("something");
i assume you know how to work with a ResultSet

Similar Messages

  • Error : Opening a rowset for "Sheet$" failed. Check that the object exists in the database.

    Hi,
    i am trying to load the data from excel sheet using For each loop container in ssis 2005.
    But it gave me the below error:
    Error: Opening a rowset for "Sheet1$" failed. Check that the object exists in the database.
    [DTS.Pipeline] Error: "component "failed validation and returned validation status "VS_ISBROKEN".
    Error: There were errors during task validation.
    Could you please let me know the solution
    Regards
    Sqlstud

    That message usually means validation has failed;
    Have any of the underlying tables changed?  Data types, lengths, maybe even column ordering, etc...?
    try this..
    Right-click on the Data Flow Task and select Properties. Then set DelayValidation =TRUE.
    Let us TRY this |
    My Blog :: http://quest4gen.blogspot.com/
    Thanks ETL.
    Everything is fine..(Datatypes,length,orderings etc)
    Already i have set
    DelayValidation =TRUE.
    IS there any other problem?
    Regards
    Sqlstud

  • Excel Source - Opening a rowset for "EFT$" failed. Check that the object exists in the database.

    Why oh why do I sometimes get this error when defining my Excel Source and then sometimes I do not?
    Am I doing something wrong here???
    The error is...
    Exception from HRESULT: 0xC02020E8
    Error at Data Flow Task [[Excel Source[27]]: SSIS Error Code DTS_E_OLEDBERROR. An OLE DB error has occurred. Error code: 0x80004005.
    Error at Data Flow Task [Excel Source [27}}: Opening a rowset for "EFT$" failed. Check that the object exists in the database.
    I know the Worksheet "EFT" exists because I defined this previously for the same Excel spreadsheet.
    Thanks for your review and am hopeful for a reply.
    PSULionRP

    A reply from CozyRoc must be hitting the nail on the head
    sheet name contains $
    http://social.msdn.microsoft.com/Forums/sqlserver/en-US/ce0fbff5-f5f1-4a4a-9c29-6adc32b0fd79/using-excel-file-as-source-in-data-flow-task-of-ssis-bi-2005-need-example-of-sheetnamecellrange?forum=sqlintegrationservices
    Arthur My Blog

  • How to search for a pattern string in entire registry and delete all the keys and subkeys that contain the pattern (C# or VB)?

    I want to search for a pattern string in the entire registry and need to delete all the keys and sub-keys that contain the pattern. How can I implement this in VB Script or C#? Appreciate if you can give some sample examples. Now every time, I am manually
    searching for the pattern in registry and deleting one by one.
    Thanks Prasad

    There is no built in way to do this. You'll end up having to enumerate all keys and values in the entire registry and comparing each one for a pattern using Regex or similar.  This is going to be really slow but there isn't much else you can do about
    it (other than parallelize the enumeration).  Also note that you won't have permissions to all keys for read and/or write access so you'll need to skip over those using exception handling.
    Michael Taylor
    http://blogs.msmvps.com/p3net

  • I know the name of an object - how do I get the name of the object that contains it?

    If I have a Movieclip, I can trace the name of the Movieclip
    that contains it using the _parent property.
    With a generic object, is there a way to trace the name of
    the object that contains it?
    Please, please tell me - this will be a huge help.
    Thanks

    Thanks for these comments - my problem isn't with MovieClips.
    I need to know if there is something which is the generic Objects
    equivalent to the MovieClips _parent property.
    Here's some code that hopefully will help explain further:
    class MyClass extends Object {
    var myObject:Object;
    function MyClass (){
    myFirstObject = new Object();
    myFirstObject.theParent = this;
    private function getNameOfParent(p_object:Object){
    // Some code to return the name of the object that contains
    p_object
    trace(p_object.__proto__); // Output: [object Object]
    trace(p_object._parent); // Output: undefined
    trace(p_object.theParent); // Output: [object Object]
    return ???
    public function doSomething(p_num:Number){
    var parentName = getNameOfParent(myObject);
    // do some more action...
    Timeline code:
    var myClass1 = new MyClass();
    myClass1.doSomething();

  • Example of generating excel dynamically in ssis? geting error [Excel Destination [190]] Error: Opening a rowset for "Excel_Destination$" failed. Check that the object exists in the database.

    example of generating excel dynamically in ssis? geting error [Excel Destination [190]] Error: Opening a rowset for "Excel_Destination$" failed. Check that the object exists in the database.

    Hi Vijay
    Can you be little bit more specific, did you receive this error when you are designing this pacakge using BIDS
    Becuase when you are designing this pacakge in BIDS, you need to manaually create a excel sheet manually for the first time you run,
    are you creating excel sheet using execute sql task and excel connection with input from a variable?
    Did you receive this error in validation phase or execution phase ?
    Can you share your query to create table in excel ?
    http://sqljunkieshare.com/2012/02/28/how-to-create-and-map-excel-destination-dynamically-in-ssis/
    Use the above post

  • Scaling an object that contains a gradient

    I'm working in Illustrator CS3. Got a question: I'm looking to scale an object that contains a gradient, but I want the position of the gradient to remain in the same position on the page. That is, I don't want the gradient to scale along with the object. Is it possible to do this without manually rebuilding the gradient?

    Normal scaling of an object (using the Scale tool, Transform or dragging the bounding box) will always scale the gradient too, but there is a sort of workaround if you know where the gradient starts and ends in the original.
    If you haven't already marked the beginning and end of your gradient, do so by pasting a copy of it in front (Cmd-F) and expanding the gradient - then you can see its start and end points when you turn off the preview. Mark what you need with guides and delete the expanded gradient. It's useful to make a guide that follows the angle of the gradient.
    Now draw a gradient-filled rectangle behind your object and get the gradient to match the angle and position of the gradient in your object by dragging with the gradient tool according to the guides.
    Having done this, copy and scale your object and change it into a clipping mask that masks the rectangle you just drew. Alternatively you can make a masking layer of your object if you know how to do that.
    Lock the rectangle (if you are using a normal clipping mask) and then you can move the object (which is now a mask) at will and the gradient will stay put.
    This is all a bit long-winded but please get back to me if you're lost :-)

  • Tool to create Java Object classes using the Database Tables

    Hi,
    Is their any tools or utility available to create the Java Object Classes using the Database Tables as input.
    Lets Say I am having the Employee, Employee_Salary tables in the Database.The utility has to create the Java Object classes with the relation.
    Please Help...
    Thx..

    Hm, for generating regular Java classes I wouldn't know one from memory. But I suggest you start searching in for example the Eclipse marketspace for a third party plugin that can do it. If all fail, you could always use Hibernate Tools from the Jboss Tools Eclipse plugin set to generate Hibernate/JPA entities and then strip the annotations from them to turn them into regular POJO classes.
    How many tables are we talking about anyway? It might be less effort to just create the classes with properties and then use an IDE to generate getters and setters for them.

  • UCCX8 Is There a Sesion Variable that contains the Call Control Group ID

    Hello,
         Is there a session variable that contains the Call Control Group ID of the trigger that called the script?
    -Lauren

    Hi Lauren,
    sorry, after two hours of analysing call hierarchies and running debugs, I gave up. I can't see any way of getting that value programmatically, in other words, I don't see any public field or method that would yield the desired value.
    However, if you want to use this only for debugging purposes, then getting the contact using the Get Trigger Info step, assigning it to a variable named contact (of type Contact) then calling the following method on it:
    contact.getTask().getTrigger() (which automatically calls the toString() method) would return a String similar to this - and it contains the ID of the Call Control Group apparently:
    "ContactApplicationTrigger[time=1356102368509,locale=en_US,cfg=JTAPITriggerConfig[schema=ApplicationTriggerConfig,time=2011-09-14 18:28:25.0,recordId=414,desc=Cisco JTAPI Trigger,name=82152,type=Cisco JTAPI Trigger,appName=TRAPPA,enabled=true,sessions=5000,idleTimeout=5000,locale=en_US,parms={},taskGroups=[],controlClass=class com.cisco.call.CallControlChannel,controlGroupId=1,contactGroups=[GroupInfo[class=com.cisco.dialog.DialogChannel,id=0]],dn=82152,redirectCSS=redirecting.party,cmDeviceName=TRAPPA_82152,cmDeviceInvalid=false,cmDescription=TransRouting IVRA,cmDevicePoolUUID={978D6B59-356E-FC92-81A9-3AAE9F843120},cmDevicePoolName=DP_Main_C,cmCallingSearchSpaceUUID={87083019-FEBF-9B48-742B-7658396D1D5C},cmCallingSearchSpaceName=CSS_mobily_normal_HelpDesk_IS,cmLocationUUID={29C5C1C4-8871-4D1E-8394-0B9181E8C54D},cmLocationName=Hub_None,cmPartitionUUID={10003B1B-F235-16A7-927D-01EB3DCCB57C},cmPartitionName=P_operatori,cmVoiceMailProfileUUID=,cmVoiceMailProfileName=None,cmCallPickUpGroupUUID=,cmCallPickUpGroupName=,cmDisplay=,cmExternalPhNumMask=,cmFwdBusyVM=false,cmFwdBusyDest=,cmFwdBusyCSSUUID=,cmFwdBusyCSSName=None,cmAlertingNameAscii=,cmPresenceGroupUUID=ad243d17-98b4-4118-8feb-5ff2e1b781ac,cmPresenceGroupName=Standard Presence group],contact=JTAPICallContact[id=16548,implId=3206772/2,state=STATE_ANSWERED_IDX,inbound=true,App name=TRAPPA,task=38000443987,session=17000062888,seq num=0,cn=82152,dn=82152,cgn=0725099603,ani=0725099603,dnis=null,clid=null,atype=REDIRECT,lrd=78866,ocn=78866,route=RP[num=82152],OrigProtocolCallRef=000000000030EE740228F81300000000,DestProtocolCallRef=null,TP=81122]]"
    Looks like the cfg field cannot be accessed, but the automatic toString() method is kind enough to dump all this information.
    Hope this helps.
    G.

  • What is property that contains the pass/fail status(UUT Result) of my main sequence ?

    Test Engineering
    Empower RF Systems Inc.

    Hi Mal,
    In general, in TestStand you use a step type that can use the Sequence Adapter in order to call a sequence (named subsequence in this context). The MainSequence is called from within the ProcessModel execution entry-points ('Test UUTs' and 'Single Pass' sequences in the TestStandModel.seq) when you launch the execution from "Execute->Test UUTs" or "Execute->Single Pass" menu or directly by the engine when you start an Interactive execution by selecting "Execute->Run MainSequence" menu option.
    In the first case, after the sequence call step executes, the Sequence Adapter can set the step status. So, finally the property that contains the status of Main Sequence is a subproperty of the SequenceCall step that in the ProcessModel execution entry-points is named "MainSeque
    nce Callback". The lookup string for this property depends from where you want to access it. For example :
    a) if it's from a step you add as part of the Execution entry-points customization, then the lookup string for the property should be "RunState.Sequence.Main["MainSequence Callback"].Result.Status"
    b) if it's from a step in the MainSequence, then the lookup string for the property should be "RunState.Caller.RunState.Sequence.Main["MainSequence Callback"].Result.Status" but special consideration should be taken if the MainSequence is run in Interactive mode, since the "RunState.Caller" property doesn't exist in this case.
    In the second case the sequence status isn't available (see above).
    Regards,
    Silvius
    Silvius Iancu

  • Is there a way to create a smart folder in iTunes, that contains the most recent (say 10) used playlists?

    Is there a way to create a smart folder in iTunes, that contains the most recent (say 10) used playlists? By having this I would be three clicks (touches from what is recent).
    Thanks

    100s with about 30 folders, comprised on different moods, years, genre, favorites, audiobooks, podcasts. Being accessed from multiple Macs and Apple TVs.

  • What are the T-codes that contain the master data for material and vendor?

    what are the T-codes that contain the master data for material and vendor?

    hi ,
    - Display Material  tcodes...
    MM01 - Create Material
    MM02 - Change Material
    MM03 - Display Material
    MM50 - List Extendable Materials
    MMBE - Stock Overview
    MMI1 - Create Operating Supplies
    MMN1 - Create Non-Stock Material
    MMS1 - Create Service
    MMU1 - Create Non-Valuated Material
    ME51N - Create Purchase Requisition
    ME52N - Change Purchase Requisition
    ME53N - Display Purchase Requisition
    ME5A - Purchase Requisitions: List Display
    ME5J - Purchase Requisitions for Project
    ME5K - Requisitions by Account Assignment
    MELB - Purch. Transactions by Tracking No.
    ME56 - Assign Source to Purch. Requisition
    ME57 - Assign and Process Requisitions
    ME58 - Ordering: Assigned Requisitions
    ME59 - Automatic Generation of POs
    ME54 - Release Purchase Requisition
    ME55 - Collective Release of Purchase Reqs.
    ME5F - Release Reminder: Purch. Requisition
    MB21 - Create Reservation
    MB22 - Change Reservation
    MB23 - Display Reservation
    MB24 - Reservations by Material
    MB25 - Reservations by Account Assignment
    MB1C - Other Goods Receipts
    MB90 - Output Processing for Mat. Documents
    MB21 - Create Reservation
    MB22 - Change Reservation
    MB23 - Display Reservation
    MB24 - Reservations by Material
    MB25 - Reservations by Account Assignment
    MBRL - Return Delivery per Mat. Document
    MB1C - Other Goods Receipts
    MB90 - Output Processing for Mat. Documents
    MB1B - Transfer Posting
    MIBC - ABC Analysis for Cycle Counting
    MI01 - Create Physical Inventory Document
    MI02 - Change Physical Inventory Document
    MI03 - Display Physical Inventory Document
    MI31 - Batch Input: Create Phys. Inv. Doc.
    MI32 - Batch Input: Block Material
    MI33 - Batch Input: Freeze Book Inv.Balance
    MICN - Btch Inpt:Ph.Inv.Docs.for Cycle Ctng
    MIK1 - Batch Input: Ph.Inv.Doc.Vendor Cons.
    MIQ1 - Batch Input: PhInvDoc. Project Stock
    MI01 - Create Physical Inventory Document
    MI02 - Change Physical Inventory Document
    MI03 - Display Physical Inventory Document
    MI31 - Batch Input: Create Phys. Inv. Doc.
    MI32 - Batch Input: Block Material
    MI33 - Batch Input: Freeze Book Inv.Balance
    MICN - Btch Inpt:Ph.Inv.Docs.for Cycle Ctng
    MIK1 - Batch Input: Ph.Inv.Doc.Vendor Cons.
    MIQ1 - Batch Input: PhInvDoc. Project Stock
    MI01 - Create Physical Inventory Document
    MI02 - Change Physical Inventory Document
    MI03 - Display Physical Inventory Document
    MI31 - Batch Input: Create Phys. Inv. Doc.
    MI32 - Batch Input: Block Material
    MI33 - Batch Input: Freeze Book Inv.Balance
    MICN - Btch Inpt:Ph.Inv.Docs.for Cycle Ctng
    MIK1 - Batch Input: Ph.Inv.Doc.Vendor Cons.
    MIQ1 - Batch Input: PhInvDoc. Project Stock
    MI21 - Print physical inventory document
    MI04 - Enter Inventory Count with Document
    MI05 - Change Inventory Count
    MI06 - Display Inventory Count
    MI09 - Enter Inventory Count w/o Document
    MI34 - Batch Input: Enter Count
    MI35 - Batch Input: Post Zero Stock Balance
    MI38 - Batch Input: Count and Differences
    MI39 - Batch Input: Document and Count
    MI40 - Batch Input: Doc., Count and Diff.
    MI08 - Create List of Differences with Doc.
    MI10 - Create List of Differences w/o Doc.
    MI20 - Print List of Differences
    MI11 - Physical Inventory Document Recount
    MI07 - Process List of Differences
    MI37 - Batch Input: Post Differences
    for vendor..
    XKN1  Display Number Ranges (Vendor)
    XK01  Create vendor (centrally)
    XK02  Change vendor (centrally)
    XK03  Display vendor (centrally)
    XK04  Vendor Changes (Centrally)
    XK05  Block Vendor (Centrally)
    XK06 Mark vendor for deletion (centrally
    XK07  Change vendor account group
    XK11  Create Condition
    XK12  Change Condition
    XK13  Display Condition
    XK14  Create with cond. ref. (cond. list)
    XK15  Create Conditions (background job)
    reward points if useful,
    venkat.

  • I'm a new MAC user and I'm trying to transfer my iTunes music files to my Mac, however when I attach the external drive that contains the music files, they aren't visible on the MAC (but they are visible on my old PC).  How do I get my music loaded?

    I'm a new MAC user and I'm trying to transfer my iTunes music files to my Mac, however when I attach the external drive that contains the music files, the music files aren't visible on the MAC (but they are visible on my old PC).  How do I get my music transferred?  I have already exported the purchased music from the iTunes library, but I have thousands of songs from my private CD collection that I had previously loaded through iTunes.

    Paragon Software has the most reliable NTFS driver for Mac
    tips on importing and organizing, transferring from Windows etc
    http://www.apple.com/support/itunes
    http://www.ilounge.com

  • LabVIEW could not generate code for the shared variable.You must open the VI in the project that contains the library where the shared variable resides

    HI
    When I put a network shared variable with fifo RT activated on my diagram, the arrow is broken.and I' ve got this message:
    ""LabVIEW could not generate code for the shared variable.You must open the VI in the project that contains the library where the shared variable resides""
    If I uncheck FIFO RT option for this variable the arrow isn't broken anymore.
    I 've no idea how to correct this weird error?
    Autodeploy is on, and I've check copy / delete in diagram in tool/options\diagram
    regards,
    james

    Hello,
    I don't reproduce this error.
    Could you send your VI?
    Regards
    VéroniqueD
    NI France

  • Is there any ways to find the object that triggered the keyevent

    i am having difficulty in this part of keyevent iam almost struck here i want to know is there an possibility to find the object that triggreed the keyevent

    hi!
    getSource() method returns the suorce object

Maybe you are looking for