jQuery in Action, 3rd edition
The moose likes Object Relational Mapping and the fly likes Validation for Text Area Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » Object Relational Mapping
Bookmark "Validation for Text Area" Watch "Validation for Text Area" New topic

Validation for Text Area

Praveen Reddy
Ranch Hand

Joined: Jul 12, 2006
Posts: 51

Can any one please let me know how to do validations for text area in order to prevent SQL Injections.

i dont want any one to inject some SQL statements to update my database.

Bear Bibeault
Author and ninkuma

Joined: Jan 10, 2002
Posts: 63838

This is not something that you should be handling at the client. Using best practice JDBC techniques, such as prepared statements, is the way to handle SQL injection.

I'll move this off to the JDBC forum for further advice.

[Asking smart questions] [About Bear] [Books by Bear]
Praveen Reddy
Ranch Hand

Joined: Jul 12, 2006
Posts: 51
Thanks for the Suggestion i am using hibernate i want to validate my text area
Scott Selikoff
Saloon Keeper

Joined: Oct 23, 2005
Posts: 3753

Moving to Object Relational mapping forum, although I suspect SQL injection is not possible in Hibernate since there are no direct SQL queries. SQL injection only plays a part when you are forwarding input directly into a SQL query such as

[OCA 8 Book] [Blog]
I agree. Here's the link: http://aspose.com/file-tools
subject: Validation for Text Area
jQuery in Action, 3rd edition