How to store jython variable to java bean shell variable

Hello experts.
I have one procedure. here is the details
1st step is with java bean shell techonolgy and one variable.
<@
String testv=" ";
@>
Second step is jython technology.
str3='storing some value as per my logic'
<@testv@>=str3 // here I am getting error because i want to store jython variable to java bean shell variable
Once it will be stored , I will use in query as SELECT '<@=testv@>' from dual. If this is not possible is there any way to get the jython variable in side refreshing query
how to achieve this please suggest.
Thank you.

Hello experts. Any suggestion on this. How to store jython variable value into java bean shell variable.
Thank You.

Similar Messages

  • How to store multiline string literal in to java bean shell variable

    Hello Experts
    How to store multiline string literals in java bean shell like we use triple quote for jython variable
    Using Jython
    str=""" helllo
    welcome to my world"""
    above syntax is working but not for java bean shell like below
    String str=""" hello
    welcome to my world""";
    So how to do this in java bean shell. I came to this scenario while storing logs to a variable. I believe there is no solution for storing multiline strings to java bean shell variable.
    <@
    String str="<%=odiRef.getPrevStepLog("MESSAGE")%>";
    @>
    Any suggestion will be highly appreciated.
    Thank You.

    maddythehunk wrote:
    Im trying this but its not working...
    while(billingQueryParamsItr.hasNext()) {
         billingQueryParam = (BillingQueryParam) billingQueryParamsItr.next();
         System.out.println("****** Param Name-->"+billingQueryParam.getParamName());
         String[0] name = billingQueryParam.getParamName(); // giving error ; expected
         //billingItemActionForm.setParamName(billingQueryParam.getParamName());
    Declare the array outside of the loop. Fill the array as you iterate. And stop putting your error messages inside of comments in the code.

  • How to convert csv files into java bean objects?

    Hi,
    I have a CSV file, I want to store the data availabale in that csv file into java bean, I am new to this csv files how can I convert CSV files into java beans.
    Please help me.
    Adavanced Thanks,
    Mahendra

    You can use the java.io API to read (and write) files. Use BufferedReader to read the CSV file line by line. Use String#split() to split each line into an array of parts which were separated by comma (or semicolon). If necessary run some escaping of quotes. Finally collect all parts in a two-dimensional List of Strings or a List of Javabeans.
    java.io API: [http://www.google.com/search?q=java.io+javase+api+site:sun.com]
    java.io tutorial: [http://www.google.com/search?q=java.io+tutorial+site:sun.com]
    Basic CSV parser/formatter example: [http://balusc.blogspot.com/2006/06/parse-csv-upload.html]

  • Passing javascript variable to java bean

    Hi all,
    Is there any way to pass a java script variable to a java bean. i'm trying hard but in vain. please suggest a way how to do it...

    The variable u want to pass declare that in a dataobject class i.e consisting of getter and setters ...... when you will use the jsp:useBean tab and the setProperty tag along with the class name it will set the value of the variables ...... use form method = get to set the variables.

  • How to upload a file using java bean?

    hi,
    i need a code simple how to upload a file from jsp form to a java bean file (not a servlet)
    thank,s zik

    Hi,
    i need a code sample how to upload a file from jsp
    form to a java bean file (not a servlet)You can use jspSmartUpload component which is a free, fully-featured JSP component.
    jspSmartUpload provides you with all the upload/download features you could possibly wish for :
    * Simple and complete upload
    * Total control over the upload process
    * �Mixed forms� management
    * Total control over files sent
    * Download whatever you want
    For further information about jspSmartUpload please visit
    http://www.jspsmart.com/
    Hope this helps.
    Good Luck.
    Gayam.Srinivasa Reddy
    Developer Technical Support
    Sun Micro Sysytems
    http://www.sun.com/developers/support/

  • How to disable and enable a java bean area's visability?

    I have a large javabean area on my initial canvas when first dispalying my form.
    When I use the SHOW_CANVAS('canvas name') to display another canvas, everything looks fine except that the javabean from my previous canvas is still visible and covering up portions of this new canvas.
    So I tried using the set_property visible for the javabean area in the form and it only got rid of the surrounding edge of the javabean area.
    Last I made some set_custom_property values to send to the bean that would then use java calls to enable and disable the beans visability.
    But once the beans visibility was disabled in Java then it wouldn't come back after the calls to enable the visibility and refresh the bean were made through Java calls.
    Is there any other ways of disabling and enabling a java bean area's visability?
    Thanks,
    Michelle

    Hello,
    Maybe the bean is always display because of its particular paint() method ?
    Anyway, without any reflexion, I could suggest you to set the bean item width and height to 1 pixel when you don't want to display it. (Set_Item_Property)
    Francois

  • How to Store word doc in java using oracle

    hi my name is jagapathi raju i am working in Niit LTD
    can any one tell me how to store A word doc in oracle using java

    Hi Jagapathi
    You can store text/doc files in Database using CLOB/BLOB columns. Let me check if there are any samples...
    Thanks
    Srinivas

  • How to Create adf table from java bean

    Hi,
    How to Create adf table from java class (Not from ADF BC).
    Thanks
    Satya

    @vlsn -- you have to follow what shay said.
    Do the following in Model layer ::
    create a table property java class with your columns setters and getters like :
    *public class gridProps {*
    private int sno;
    private String orderNum;
    *public void setSno(int sno) {*
    this.sno = sno;
    *public int getSno() {*
    return sno;
    *public void setOrderNum(String orderNum) {*
    this.orderNum = orderNum;
    *public String getOrderNum() {*
    return orderNum;
    Create another table java class which will populate the values to your column values and return the collection :
    *public class gridPopulate {*
    private  List<gridProps> gridValues ;
    *public List<gridProps> setToGrid(ArrayList<ArrayList> valuesToSet) {*
    *if (valuesToSet == null) {*
    return gridValues;
    gridValues = new ArrayList<gridProps>();
    if(btnValue.equals("completeBtn"))
    return gridValues;
    for(ArrayList<String> tempArr:valuesToSet)
    gridProps gp = new gridProps();
    gp.setSno(Integer.valueOf(tempArr.get(0)));
    gp.setOrderNum(tempArr.get(1));
    return gridValues;
    Right click gridPopulate class and create this as data control.This class will be seen in Data control list.Under this data control,Drag the grid property collection(created earlier) to your page.Then execute your binding(gridPopulate) according to your logic.
    Thanks.(My jdev version 11.1.1.5.0)

  • How to store a Non Serializable Java Object ?

    Hi..
    I have a non serializable java object which I want to store in the Oracle database and retrieve it. Can anyone help me with how to go about doing this ?
    many thanks in advance
    Ragavan

    If you share the same JVM then its possible, but I doubt that is the case. If you don't share the JVM then its
    impossible to share an object between two apps.
    But if all your attempting to do is duplicate the object in the other app then I spose it is possible, as long as
    you can reconstruct the object from information that you can interegate from the object.
    For example, if you have App A, and App B. WIthin App A is a Double d object. Then you could get the
    value of the Double by doing:
    d.doubleValue()
    write the double to a file/socket/stream, read the file/socket/stream at the other end, create a new Double
    via Double d = new Double(parsedValue);
    Now the two Apps will have a Double d object that represent the same value via a a.equals(b) == true, but
    they will not refer to the same object within memory/jvm.
    James.

  • How to store binary data in Java

    I need to show news in my web aplication.So I am retrieving news from a Feed Server in which the field GEN_UNICODE_MESSAGE_1 gives the news data.News consists of both English/Arabic data.So how will I store the binary content in JAVA and how can I display the news in JSP?
    I tried storing the binary content in ByteArrayInputStream and appended it using StringBuilder.But I didnt get the desired output.Output is seen as ÇáÎáíÌíÉ ááÇÓÊËãÇÑÇáãÌãæÚÉÇáÔÑßÉÇáÇãÓÈÊãÈÑÓÈÊãÈÑÅÌãÇá.Please help me.
    Here GEN_UNICODE_MESSAGE_1 is of type BINARY.
    try{
    BufferedInputStream in=new BufferedInputStream(new ByteArrayInputStream((byte[])msg.getField("GEN_UNICODE_MESSAGE_1").value.get(h)));
    //ByteArrayInputStream in=new ByteArrayInputStream(((byte[])msg.getField("GEN_UNICODE_MESSAGE_1").value.get(h)));
    StringBuilder builder = new StringBuilder();
    byte[] buff=new byte[1024];
    int len;
    while ((len=in.read(buff))!=-1){
    builder.append(new String(buff,0,len));
    String incomingmsg=builder.toString();
    }catch(IOException e){}
    Edited by: Alance on May 7, 2010 10:12 PM

    BufferedInputStream bis=new BufferedInputStream(new ByteArrayInputStream((byte[])msg.getField("GEN_UNICODE_MESSAGE_1").value().toString().getBytes()));
    BufferedReader br = new BufferedReader(new InputStreamReader(bis));What on earth is all this?
    1. What is the type of msg.getField("GEN_UNICODE_MESSAGE_1").value()?
    2. Whatever that type is, you are then converting it to a String.
    3. You are then converting that to bytes.
    4. You are then casting that to byte[], which it already is,
    5. You are then wrapping a ByteArrayInputStream around that.
    6. ... and an InputStreamReader round that ...
    7. ... and a BufferedReader around that ...
    8. ... and reading lines
    9. ... and appending them to a StringBuilder
    10. ... and converting that to a String.
    Which you already at at step 2.
    String incoming = msg.getField("GEN_UNICODE_MESSAGE_1").value().toString();Not sure whether that's correct given the charset issues, but if not the problem starts at step 2. In any case steps 3-10 add precisely nothing.
    This is all pointless. The key question is (1). Answer that first.
    2. The type of String.getButy
    >
    StringBuilder sb = new StringBuilder();
    String line = null;
    while ((line = br.readLine()) != null) {
    sb.append(line + "\n");
    br.close();
    String incomingmsg=sb.toString();

  • How to store and load in java using mapping

    I am doing my project in java, my project consists of producing a card game.
    I my game at the end of each round the computer will ask the player if he/she wants to save the game. I have looked at some methods on how to do this. It seams that I need a type of mapping but how.
    I want to take a String (which is entered by the player) and to this String I want to store various peices of data that can be loaded up later.
    The data that I want to store are has follows
    1. Name of the player - String
    2. Name of the computer- String
    3. Points of computer sofar- Int
    4. Points of player sofar - Int
    5. Target points- Int
    If there is a better way then please tell me. thankyou

    The format of the saved game could be anything. An easy way to do this is by using the MessageFormat class.
    Let's say you use the tab character as a delimiter, and you want to write two strings and 3 ints:
    MessageFormat mf = new MessageFormat("{0}\t{1}\t{2,number}\t{3,number}\t{4,number}";
    Object[] o = new Object[5];
    o[0] = playerName;
    o[1] = computerName;
    o[2] = new Integer(computerPoints);
    o[3] = new Integer(playerPoints);
    o[4] = new Integer(targetPoints);
    String formatted = mf.format(o);
    PrintWriter out = new PrintWriter(new FileWriter("save.txt"));
    out.println(formatted);
    out.close();
    // reading:
    BufferedReader in = new BufferedReader(new FileReader("save.txt"));
    String s = in.readLine();
    Object[] values = mf.parse(s);
    playerName = (String)values[0];
    computerName = (String)values[1];
    computerScore = ((Number)values[2]).intValue();
    playerScore = ((Number)values[3]).intValue();
    targetScore = ((Number)values[4]).intValue();You could also just write each value on its own line and not using MessageFormat, but just read the values line by line and convert String to ints when needed.

  • How to get application path in java bean

    hi all,
    We will be using <%= application.getRealPath("/") %> for getting the application path in jsp. is there any similar way to find the path using a bean. Please do help....
    thanx
    Message was edited by:
    end

    I try to use application.getRealPath("/") in my .java file, but gets an error "application can't be resolved". Do you need to include any library in order to use "application.getRealPath("/")"?
    Thank you.

  • How to store a relative path in a global variable

    Hi,
    I'm using Teststand 2013 and Labview 2013
    Is it possible to define a relative path for a global variable in the Teststand? Ex. "..\vector1.hws"
    Or I should use the Labview functions to solve this issue?
    Thanks,
    Solved!
    Go to Solution.

    Paths are so much easier to manipulate in LabVIEW.  So you could store the relative path as a string and then use LabVIEW to make the absolute path.
    I typically store a folder in a global variable and then I can just concatinate the strings to build the absolute path.  For example:
    FileGlobals.Folder = "C:\\foo\\bar\\",
    Locals.Path = FileGlobals.Folder + "blah.txt"
    There are only two ways to tell somebody thanks: Kudos and Marked Solutions
    Unofficial Forum Rules and Guidelines

  • How can i access and assign java xml Document variable in javascript block

    How can i access and assign org.w3c.dom.Document variable in javascript block
    I tried this xmlDoc = "<%=xmldoc%>";
    it is not working
    plz give me solution.
    thanx
    Vidya

    The solution would only work on MS IE browsers, as other browsers do not support an XML DOM.
    It can be done, but you would be stuck with using the Microsoft broswer. If that is acceptable, I have some example code, and a book recommendation.

  • How to Store word doc in java using oracle9i

    hi
    my name is jagapathi raju i whant a pice of code that will help me to store word doc in oracle9i please do this for me
    bye

    i whant a pice of code that will help me to store word doc in oracle9i please do > this for me Nope, imagine we are consultants who just provide you with a direction to your
    investigation.
    There's a few approachs...
    1. You store the entire word document ( or any arbitrary binary file ) in a BLOB
    field. ( binary large object ).
    Have a search for Oracle, JDBC and BLOB.
    2. You somehow extract the text from the Word document, losing all formating,
    and store the text in a database field. ( CLOB ) Character large object.
    regards,
    Owen

Maybe you are looking for

  • Solidworks model mating issue in 3D Picture control

    Hello I have been following example of LQR and linear inverted pendulum ...where we can import Solidworks model in Labview and have our own control..... I made SCARA and I am being able to access individual part ...however I still have some mating is

  • I have an XFL file that I want to use as clickable flash advertisment.

    Hi everybody! I have designed a 768x90 ad in After Effects. My goal is to use that video as a clickable flash ad. So far I have exported it in the form of an XFL but I really cant figure out how to do the rest. I need to make the whole banner clickab

  • TG4MSQL ora-28500 error on RECOVER login in READ-ONLY mode

    We're connecting from a 10.2 dbase to SqlServer2000 via TG4MSQL. No upfront problem connecting but the Oracle .trc file shows below error: ORA-28500: connection from ORACLE to a non-Oracle system returned this message: [Transparent gateway for MSSQL]

  • Alias in Mail app?

    Hi all, In browsing the discussion board, I've just learned to create an alias for mail in the online me.com page. However, is there a way to drag that alias somehow into the mail app that's on my desktop? Thanks

  • Errors while stopping Application 11.5.9

    Dear Experts, I am facing errors while trying to stop Application services. I am using : adstpall.sh apps/pwd to stop the services and here is the log for the same. Kindly help ASAP as I need to take cold backup this weekend. Thanks in advance. Oracl