jpa访问数据库的存储过程怎么写
2016-07-15
展开全部
@Entity
@Table(name = "USER", schema = "MOBILE", uniqueConstraints = {
@UniqueConstraint(columnNames = { "LOGINID" }),
@UniqueConstraint(columnNames = { "USERACCOUNT" }) })
@NamedNativeQuery(name = "addUser", query = "{call addUser(:pPortalID,:ploginid,:ploginpasswd,:pSelfQuiz,:pSelfAnswer,:pUserEmail,:pUserAccount,:pUserPin)}", hints = { @QueryHint(name = "org.hibernate.callable", value = "true") }, resultClass = User.class)
public class User implements java.io.Serializable {
@Table(name = "USER", schema = "MOBILE", uniqueConstraints = {
@UniqueConstraint(columnNames = { "LOGINID" }),
@UniqueConstraint(columnNames = { "USERACCOUNT" }) })
@NamedNativeQuery(name = "addUser", query = "{call addUser(:pPortalID,:ploginid,:ploginpasswd,:pSelfQuiz,:pSelfAnswer,:pUserEmail,:pUserAccount,:pUserPin)}", hints = { @QueryHint(name = "org.hibernate.callable", value = "true") }, resultClass = User.class)
public class User implements java.io.Serializable {
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询