Posts by Edylle Landy • 136 points
3 posts
-
9
votes1
answer27947
viewsA: Format CPF or CNPJ field using Regex
CNPJ: (^\d{2}. d{3}. d{3}/ d{4}- d{2}$) CPF: (^\d{3} x2E d{3} x2E d{3} x2D d{2}$) Using Validation Bean, you can set a default for your variable. @Pattern(regexp =…
-
1
votes3
answers1439
viewsA: Saving ID from a table with two Primary Keys with Hibernate
If the set of two or more columns that combined will never repeat, you do not need (and should not) create an extra column only to serve as a primary key (as @Shura16 suggested). You will only be…
-
2
votes2
answers1136
viewsQ: How to read a user-submitted file using Fileinputstream?
I would like the user to send a file . xls to the system and from this would be created a database. The method I have is working, but the parameter that Fileinputstream receives is a String…