hemant Budhewar BamniBk

Ranch Hand
+ Follow
since May 09, 2009
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
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by hemant Budhewar BamniBk

Welcome Amit


I would like to know what all other languages (their syntax, concepts etc.) have been referred throughout this book. Asking this because I think, one should know all the basic pre-requisite knowledge before he start reading this book.

Thanks,
Hemant
11 years ago
Hi, can anybody havin answer for this?
Hi,

I want to write large clob object having more than 4k in Oracle database (10g) but I could not able to do this even thogh I set property SetBigStringTryClob.

Could anybody tell me about this?

It would be great if I could able to set it in web logic jndi setup.

Thanks in Advance!

Thanks,
Hemant

Deepak Bala wrote:You can follow these steps -> http://www.oracle.com/technology/sample_code/tech/java/codesnippet/jdbc/clob10g/handlingclobsinoraclejdbc10g.html

Let us know if you have errors even after following that tutorial



Code Snippet to update:

CLOB clob = (CLOB) objResultSetP.getObject(1);

Writer writer = null;
try
{
writer = clob.getCharacterOutputStream();
writer.write(m_strValue);
writer.flush();
}
finally
{
try
{
if (writer != null)
writer.close();
}

Deepak Bala wrote:You can follow these steps -> http://www.oracle.com/technology/sample_code/tech/java/codesnippet/jdbc/clob10g/handlingclobsinoraclejdbc10g.html

Let us know if you have errors even after following that tutorial



I am sorry Deepak,

I have initially tried this code but I was getting problem while writing with help of pstmt.setString() for More than 4k characters.

In above case even if I use props.put("SetBigStringTryClob", "true"); still it says string literal too long.

So then I used the steps which I mentioned.

i.e.

Wrting Empty Clob first then updating with characterStream writer.

I read somewhere that SetBigStringTryClob flag works in case main not for web apps.

Please provide if you have any inputs.



Deepak Bala wrote:Which database ?

Please post some code and related error / log messages if any



Thanks for your reply.

Stack: Oracle10g, Weblogic/Tomcat, Linux/Windows

I will add code as well.
Hi,

I am facing below problem,

I want to write clob column with some data. I have am writing it by following two step process,

1) Write empty string into clob cloumn with the help of EMPTY_CLOB() method
2) Get the recently added clob object and then update it by using writer (Resultset.getCharacterOutputStream)

This works fine for Statement but in case of Preparedstatment used in #1 it behaves strangely

Actually I found that it is not getting recently added clob object. So I could not able to update the column and data remain in clob column is empty.

Note: In case of Preparedstatment I am using batch processing.

Thanks in advance!

Thanks,
Hemant

Ulf Dittmer wrote:Is the browser possibly configured to go through a proxy?



yes
12 years ago

Rob Prime wrote:You can't connect to the port on the host you specified, and after a timeout it simply fails. Are you sure you can reach the URL? You can try with a regular browser like Internet Explorer or Firefox.



Thruogh the browser I can get the page but with code I even not get connected to that URL.

Please let me know if you need any more information.

Thanks
12 years ago

I have been using URL and URLConnetion api's, but getting problem saying,


Exception in thread "main" java.net.ConnectException: Connection timed out: connect
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(Unknown Source)
at java.net.PlainSocketImpl.connectToAddress(Unknown Source)
at java.net.PlainSocketImpl.connect(Unknown Source)
at java.net.Socket.connect(Unknown Source)
at java.net.Socket.connect(Unknown Source)
at sun.net.NetworkClient.doConnect(Unknown Source)
at sun.net.www.http.HttpClient.openServer(Unknown Source)
at sun.net.www.http.HttpClient.openServer(Unknown Source)
at sun.net.www.http.HttpClient.<init>(Unknown Source)
at sun.net.www.http.HttpClient.New(Unknown Source)
at sun.net.www.http.HttpClient.New(Unknown Source)
at sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(Unknown Source)
at sun.net.www.protocol.http.HttpURLConnection.plainConnect(Unknown Source)
at sun.net.www.protocol.http.HttpURLConnection.connect(Unknown Source)
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source)
at com.MaiYUYTY.main(Maina.java:34)

Can anybody having idea about the resoulution
12 years ago
I found some code which is exactly similar to below template,


var str1 = "string";
var str2 = "string";
alert("first alert");
// Equals alert
alert("equals alert " + (str2.equals(str1)));



Can anybody explain why equals method in last alert not executes in some cases?

I am sorry I don’t know what all those “some scenarios” are.

I tried with cookie clearing and also came to know about this from some links that JavaScript equals compares only reference.



can anybody have an idea about converting weblogic.jdbc.wrapper.Clob_weblogic_jdbc_base_Base Clob to oracle.sql.Clob

This is because I am getting below Exception,

=====================

java.lang.ClassCastException: weblogic.jdbc.wrapper.Clob_weblogic_jdbc_base_BaseClob

=====================


Thanks in advance
13 years ago
Can anybody suggest me good book for SCEA?

Thanks in advance
Hi I have written an enum, FileExtensions which contains some file extensions ,

I have two ways to write this each extension names,

One way just specifying the lower case


Ex.
enum FileExtensions {
ppt, xls;
}

in this case I just have to get that enum and which will server my purpose, i.e. appending this enum name to file name.


Another way is as below,

please let me know which is the right,


public enum FileExtensions {
PPT("ppt"), PPTX("pptx"), DOC("doc"), DOCX("docx"), XLS("xls"), XLSX("xlsx"),
OK("ok"), ERR("err"), XMl("xml"), TMP("tmp");

// Extenstion used.
private String extension;

FileExtensions(final String extenstion) {
this.extension = extenstion;
}

/**
*
* This is overriden method.
*
* @see java.lang.Enum#toString().
* @return - String.
*/
@Override
public String toString() {
return extension;
}

}



13 years ago