mysql - How to make the sql of the java project compatible with the sql syntax of multiple databases?
PHPz
PHPz 2017-05-18 10:45:51
0
2
942

How can the sql statements in Java projects be compatible with multiple databases? The project belongs to the product category and it is not confirmed which database the user uses. We use db2 during development, but if we encounter an oracle database, sql will fail. I don't know how to achieve compatibility with multiple databases. For example, oracle, MySQL, SQL server, db2, etc.

PHPz
PHPz

学习是最好的投资!

reply all(2)
阿神

You can try using an ORM framework that supports multiple dialects.

大家讲道理

Isn’t ORM the solution to this problem? It executes different sql, jpa, hibernate according to the configured database dialect

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template