File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JForum and the fly likes Error editing posts when using Oracle 9i Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Products » JForum
Bookmark "Error editing posts when using Oracle 9i" Watch "Error editing posts when using Oracle 9i" New topic
Author

Error editing posts when using Oracle 9i

Migrated From Jforum.net
Ranch Hand

Joined: Apr 22, 2012
Posts: 17424
also entered at : http://www.jforum.net/jira/browse/JF-556

When editing posts (your own or others) JForum will correctly post the information if the post is longer.

If you the post is made shorter (ie. delete some words from the post and press submit) there is garbage data displayed.

I have not tested this in other environments but can reproduce every time with Oracle 9i.

E/.
[originally posted on jforum.net by ewise]
Migrated From Jforum.net
Ranch Hand

Joined: Apr 22, 2012
Posts: 17424
This was suposed to be fixed.

Which JForum version and Oracle version are you using?

Rafael
[originally posted on jforum.net by Rafael Steil]
Migrated From Jforum.net
Ranch Hand

Joined: Apr 22, 2012
Posts: 17424
We are running with Oracle 9i and JForum 2.1.6 as stated in Jira.

From looking at the code it doesn't appear that the size of the BLOB is reduced when smaller posts are made.

E/.
[originally posted on jforum.net by ewise]
Migrated From Jforum.net
Ranch Hand

Joined: Apr 22, 2012
Posts: 17424
This is a bug of the jdbc driver, nor JForum. The oracle driver is a factory of bugs.

You can try the beta of JForum 2.1.7 - get it from http://www.jforum.net/beta/latest_dev.jsp

Rafael
[originally posted on jforum.net by Rafael Steil]
Migrated From Jforum.net
Ranch Hand

Joined: Apr 22, 2012
Posts: 17424
Rafael,

<also posted in JIRA>

I have fixed this issue (in my environment) by using two steps.

1) installed the latest Oracle Driver 10g 10.2.0.2 (for Solaris x86)

2) changing the method writeBlobUTF16BinaryStream in net.jforum.dao.oracle.OracleUtils as follows.
A note: this code relies on the 10g driver as the 9i driver doesn't seem to like the truncate() call. I didn't look too closely and went for the quickest fix here.


[originally posted on jforum.net by ewise]
Migrated From Jforum.net
Ranch Hand

Joined: Apr 22, 2012
Posts: 17424
hehe.. great.

This should be the 4th different solution for the same problem.

It's amazing to see how a company like oracle can't ship a decent jdbc implementation.

Rafael
[originally posted on jforum.net by Rafael Steil]
Migrated From Jforum.net
Ranch Hand

Joined: Apr 22, 2012
Posts: 17424
Hi Rafae,

I face same problem in our project.

Can you tell me another 3 solution for the same problem.

Thank you very much !

Spring
[originally posted on jforum.net by spring]
Migrated From Jforum.net
Ranch Hand

Joined: Apr 22, 2012
Posts: 17424
I just wanna say that with Hibernate and Spring, this is easy peacy stuff
[originally posted on jforum.net by lazee]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Error editing posts when using Oracle 9i
 
Similar Threads
sequence as String
ejb database mapping
Filters in java
Try / Catch Confusion
java.sql.SQLException: ORA-03115: unsupported network datatype or representation