aspose file tools
The moose likes Object Relational Mapping and the fly likes Validation for Text Area Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of Mongo DB Applied Patterns this week in the MongoDB forum
or a resume review from Five Year Itch in the Jobs Discussion forum!
JavaRanch » Java Forums » Databases » Object Relational Mapping
Reply Bookmark "Validation for Text Area" Watch "Validation for Text Area" New topic
Author

Validation for Text Area

Praveen Reddy
Ranch Hand

Joined: Jul 12, 2006
Posts: 51
Hi

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.

Thanks
Praveen
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 56150
    
  13

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.


[Smart Questions] [JSP FAQ] [Books by Bear] [Bear's FrontMan] [About 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: 3652

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


My Blog: Down Home Country Coding with Scott Selikoff
 
I agree. Here's the link: http://zeroturnaround.com/jrebel - it saves me about five hours per week
 
subject: Validation for Text Area
 
Similar Threads
JTextArea Alternate Row color Change
multiple lines in JEditorPane
How to preserve new lines when parsing
Any ideas for practice programs...
text area inrichfaces