Keerthi Sagar

Greenhorn
+ Follow
since Apr 21, 2007
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
(keep public parts private until JForum day)
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt
Moderation Tools

Recent posts by Keerthi Sagar

I tried to execute the build multiple times. I believe the domain was messed up. I deleted the domain directory and ran build again. It executed successfully.
5 years ago
Hi,

I am facing the following error while executing create() method in the python function for creating a Oracle connection pool, given below.

#===============================================
# FUNCTION: data_source_create
#===============================================
def data_source_create(theDataSrcName,theUserId,thePassword):
cd("/");
print 'Creating JDBCSystemResource with name '+ theDataSrcName;
aJDBCSysRsc = create(theDataSrcName,"JDBCSystemResource");
aJDBCResource = aJDBCSysRsc.getJDBCResource();
aJDBCResource.setName(theDataSrcName);

aConnectionPoolParams = aJDBCResource.getJDBCConnectionPoolParams();
aConnectionPoolParams.setConnectionReserveTimeoutSeconds(25);
aConnectionPoolParams.setMaxCapacity(100);
aConnectionPoolParams.setTestTableName("dual");

aDataSrcParams = aJDBCResource.getJDBCDataSourceParams();
aDataSrcParams.addJNDIName(theDataSrcName);
aDataSrcParams.setGlobalTransactionsProtocol("None");

aDriverParams = aJDBCResource.getJDBCDriverParams();
aDriverParams.setUrl(deploy_env_ora_database_jdbc_url);
aDriverParams.setDriverName(ora_jdbc_driver);
aDriverParams.setPassword(thePassword);

aDriverProps = aDriverParams.getProperties();
aProperty = aDriverProps.createProperty("user");
aProperty.setValue(theUserId);
return aJDBCSysRsc;

=============================================================
[wlst] Traceback (innermost last):
[wlst] File "weblogic\weblogic_library.py", line 201, in ?
[wlst] File "<string>", line 1, in ?
[wlst] File "weblogic\weblogic_library.py", line 181, in target_environment_create
[wlst] File "weblogic\weblogic_library.py", line 130, in environment_create
[wlst] File "weblogic\weblogic_library.py", line 141, in environment_create_single_server
[wlst] File "weblogic\weblogic_library.py", line 41, in data_source_create
[wlst] File "<iostream>", line 528, in create
[wlst] at weblogic.management.scripting.EditHandler.create(EditHandler.java:531)
[wlst] at weblogic.management.scripting.WLScriptContext.create(WLScriptContext.java:332)
[wlst] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[wlst] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
[wlst] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
[wlst] at java.lang.reflect.Method.invoke(Method.java:597)
[wlst]
[wlst] java.lang.ClassCastException: java.lang.ClassCastException: java.lang.reflect.InvocationTargetException cannot be cast to weblogic.management.scripting.ScriptException
[wlst]
[wlst] Exception in thread "main" java.lang.IllegalStateException: Traceback (innermost last):
[wlst] File "weblogic\weblogic_library.py", line 201, in ?
[wlst] File "<string>", line 1, in ?
[wlst] File "weblogic\weblogic_library.py", line 181, in target_environment_create
[wlst] File "weblogic\weblogic_library.py", line 130, in environment_create
[wlst] File "weblogic\weblogic_library.py", line 141, in environment_create_single_server
[wlst] File "weblogic\weblogic_library.py", line 41, in data_source_create
[wlst] File "<iostream>", line 528, in create
[wlst] at weblogic.management.scripting.EditHandler.create(EditHandler.java:531)
[wlst] at weblogic.management.scripting.WLScriptContext.create(WLScriptContext.java:332)
[wlst] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[wlst] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
[wlst] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
[wlst] at java.lang.reflect.Method.invoke(Method.java:597)
[wlst]
[wlst] java.lang.ClassCastException: java.lang.ClassCastException: java.lang.reflect.InvocationTargetException cannot be cast to weblogic.management.scripting.ScriptException
[wlst]
[wlst] at weblogic.management.scripting.WLSTInterpreterInvoker.printError(WLSTInterpreterInvoker.java:110)
[wlst] at weblogic.management.scripting.WLSTInterpreterInvoker.executePyScript(WLSTInterpreterInvoker.java:103)
[wlst] at weblogic.management.scripting.WLSTInterpreterInvoker.main(WLSTInterpreterInvoker.java:27)
======================================================
Technical information
-------------------------
Operating System: Windows XP 32bit.

Ant version: apache-ant-1.8.4

JDK: jdk1.6.0_21. JAVA_HOME=C:\JavaSDK\jdk1.6.0_21 and JAVA_VENDOR=Sun

Weblogic: 10.3.3. While installing I have not selected to install JDK and JRockit plugins. Instead, I pointed the JDK home to C:\JavaSDK\jdk1.6.0_21.

Oracle: 11g version 11.2.0.1.0. Installed as localhost at 1521 port with service name orcl. Server and TNS Listener are up and running.

Python script was executed using WLST task in an Ant Script.

Please let me know if you need any further information.

Thanks and regards,
Y. Keerthi Sagar.
5 years ago
Hi Vina,
Put the <jsp:useBean> tag out side the forloop like;
====
<jsp:useBean id="barChart" class="com.cewolf.Barchart">
<% for (int d = 1; d < 8; d++)
====
And also put the closing tag </jsp:useBean> out side the forloop

Regards,
Y. Keerthi Sagar.
8 years ago
JSP
Please check your private messages
8 years ago
JSP
Hi Vina,
Can you place the complete code again, including the Bean class and the declaration details of the variables "c", "cal" and the method details of isDate(). ?

I sent you a private message with my GTalk ID. Check it and ping me. I hope it would be easier to discuss.

Regards,
Y. Keerthi Sagar.
8 years ago
JSP
Hi Pankaj,
Try to set OFF the AUTOCOMPLETE feature for the form, like;

<form AUTOCOMPLETE="OFF">
-----------
-----------
-------
</form>

Regards,
Y. Keerthi Sagar.
8 years ago
JSP
Hi Vina,
I just given some broad idea, and it is a bit difficult to identify without knowing the declaration details of the variables "c", "cal" and the method details of isDate(). I don't know whether you are using any exisiting utility or it is a custom method. If isDate() is a custom method, please provide the details of that.

Regards,
Y. Keerthi Sagar.
8 years ago
JSP

vina kum wrote:
//ArrayList disp= new ArrayList();



Uncomment this block and comment the following line

vina kum wrote:
String disp = "";



Now, instead of assigning the value in "dispDay" to "disp" like;

vina kum wrote:
disp = Integer.toString(dispDay);



Add the value in "dispDay" to "disp" ArrayList object like;
disp.add(Integer.toString(dispDay));

Now, in the Barchart class, change the type for the variable, "disp", from "String" to "ArrayList";

vina kum wrote:
public class Barchart implements DatasetProducer, Serializable {
public Barchart() {}
private String disp ;

public String getDisp() {
System.out.println("getDisp");
return disp;
}

public void setDisp(String disp) {
System.out.println("setDisp");
this.disp = disp;

}



Now, check with the modifications, and let me know if any problems occured.

Regards,
Y. Keerthi Sagar.
8 years ago
JSP

pawan chopra wrote:Hi All,

I am getting the localized value using java code only.



Hi Pawan,
The scenario specified by you is not clear, how you are getting the localized values?

One way, and I think the better way is, maintaining the properties files for various languages and based on the required langauge/locale, loading the corresponding property file. You can use resource bundle here.

Regards,
Y. Keerthi Sagar.
8 years ago
JSP
Hi Vinod,
You can put all the .properties files in WEB-INF/classes folder

Regards,
Y. Keerthi Sagar.
8 years ago
JSP
Hi Vina,
Still your question is confusing. Is your ArrayList is in JSP?? And you want to send that to the Servlet??

If that is the case, you can not send that ArrayList object to servlet in normal way. Because, once the jsp file is generated and sends to the browser, the server will not have access to the Java objects available in jsp. What you can do is keep the value in a session variable and update it as required.

Regards,
Y. Keerthi Sagar.
8 years ago
JSP
Hi Kavitha,
Try with location.href

Regards,
Y. Keerthi Sagar.
8 years ago
JSP
Hi Chinmaya,
The easiest way is to put an Application Context level variable and maintain the value during User login and logoff.

Regards,
Y. Keerthi Sagar.
8 years ago
JSP
Hi Simran,
Check the following steps;
=> Write the whole content in a div tag
=> Open a popup window write the contents into that window
=> Print the popup window
=> Close the popup window.

Sample javascript function will be like;
function CallPrint(){
var printContent = document.getElementById("txtDiv");
var Win4Print = window.open('','','left=0,top=0,width=500,height=500,top=301,left=365,resizable=1,status=0,toolbar=0');
Win4Print.document.write(printContent.innerHTML);
Win4Print.document.close();
Win4Print.focus();
Win4Print.print();
Win4Print.close();
}

Regards,
Y. Keerthi Sagar.
Hi Steve,
While iterating if you got the required value in that column, add simply the following code.
========
%>
<script>document.getElementById('<%=y%>').style.display = none;</script>
<%
========
Here what I am doing is, closing the jsp scriptlet and adding a javascript code to hide the row.

Hope this works.

Regards,
Y. Keerthi Sagar.
8 years ago
JSP