hibernate No Dialect mapping for JDBC type 1111 problem solution
No Dialect mapping for JDBC type: 1111 problem solution
Error reporting reason
Because each database has its own dialect, and the simple understanding of dialect is to make a mapping relationship for the unique data types and functions of some databases, and 1111 can't find the corresponding value of dialect because there is no mapping relati ...
Posted by strangesoul on Thu, 10 Mar 2022 04:23:36 +0100
Use hibernate validator to complete parameter verification before entering the controller
1, Why use validator?
Parameter verification is a very important step in the development process. If the front-end parameter verification is for user experience, the back-end parameter verification is for security. Have you ever done parameter verification? Judge one field by one. The disadvantages of this approach are obvious - code redundanc ...
Posted by binarynomad on Sat, 26 Feb 2022 16:52:02 +0100
Which is better, Hibernate or MyBatis
Because the programming idea is different from the design mode of database, some ORM frameworks have been born. The core is to turn relational database and data into object-oriented. Hibernate and myBatis are currently popular solutions. Both have their own advantages and disadvantages. The competition is fierce, and one of the more important c ...
Posted by mhewall on Fri, 18 Feb 2022 16:33:09 +0100
Mybatis's past and present life
JDBC
When it comes to java operating database, JDBC must be inexcusable. Mybatis actually encapsulates JDBC
// Register JDBC Driver
Class.forName("com.mysql.cj.jdbc.Driver");
// open a connection
conn = DriverManager.getConnection("jdbc:mysql://localhost:3306/spring-shiwu? characterEncoding=utf-8&serverTimezone=UTC", "root", "1234 ...
Posted by nikbone on Fri, 18 Feb 2022 15:59:31 +0100
eclipse learning (Chapter 3: Hibernate in ssh) - 7 Hibernate uses annotation development
preface
This article refers to https://www.w3cschool.cn/hibernate/zief1iev.html A practice note made after.
Project practice
1. Initialization project and jar package pull
2. mysql data structure
SET FOREIGN_KEY_CHECKS=0;
-- ----------------------------
-- Table structure for classes
-- ----------------------------
DROP TABLE IF ...
Posted by optiplex on Sun, 30 Jan 2022 23:14:36 +0100
eclipse learning (Chapter 3: Hibernate in ssh) - 9 Standard query in Hibernate
Foreword (it is suggested to have a look at the version gap)
This article refers to https://www.w3cschool.cn/hibernate/ugov1ie8.html A practice log made after. If you use the old version directly, there is no problem. Let me give you the simplest example. You can create it directly. If so, you can add parameters to it.
Criteria c = sessio ...
Posted by ultrus on Sun, 30 Jan 2022 05:23:16 +0100
SSH enterprise case_ CRM customer management system: customer management module & Dictionary & asynchronous
1. Review of last lesson
SVN • SVN: version control tool. • common version control tools SVN CVS GIT • install SVN server • install SVN client • use of SVN check out update submit commit solve SVN conflict • setting of SVN permissions SVN create user SVN create group ...
Posted by rfrid on Thu, 20 Jan 2022 23:22:38 +0100
Spring data & JPA learning notes
jpa:Java Persistence api is a specification, and hibernate is its implementation. jpql/hql: query language. jpql is a subset of hql. 1. Basic usage and annotation explanation @MappedSuperclass 1. The class marked @ MappedSuperclass will not be a complete entity class. It will not be mapped to the database table, but its properties will be mappe ...
Posted by Aliz on Tue, 18 Jan 2022 22:52:29 +0100
Annotated Association of hibernate
1, Use annotations for associations
user configuration table
<mapping resource="org/zttc/itat/model/User.hbm.xml"/>
<mapping class="org.zttc.itat.model.User"/>
It replaces the original xml
Class level annotation
@The entity annotation declares a class as an entity Bean. Entity must have @ Id. You can generate a Tabl ...
Posted by phpshift on Mon, 03 Jan 2022 18:13:44 +0100
Four states of Hibernate entity objects
First, declare that in Hibernate, entity objects have four states, not three (see org.hibernate.event.def.AbstractSaveEventListener).
The three states of Hibernate objects circulated on the Internet are probably because the official hibernate documents are not updated. After one person writes, copy one by one, you know.
state invariant
/**
...
Posted by robburne on Tue, 21 Dec 2021 22:26:08 +0100