[JavaSE实验] JDBC and MySQL# [JavaSE实验] JDBC and MySQL ## 1 JDBC JDBC is an API for the Java programming language that defines how a client may access a database. It provides methods for querying and updating data in a database database. JDBC is oriented towards relational databases. From a technical point of view, the API is as a set of classes in the java.sql package. To use JDBC with a particular database, we need a JDBC driver click on the Libraries node and select Add Library option. From the list of options, select MySQL JDBC Driver. ## 4 Installation and Testing If you don't already have MySQL installed, we must install0 码力 | 23 页 | 2.52 MB | 2 年前3
01 Sharding JDBC概览## 1 Sharding-JDBC 概览 ### 1.1 认识ShardingSphere ## ShardingSphere ShardingSphere是一套开源的分布式数据库中间件解决方案组成的生态圈,它由Sharding-JDBC、Sharding-Proxy和Sharding-Sidecar(计划中)这3款相互独立的产品组成。他们均提供标准化的数据分片、分布式事务和数据库治理功能 认识Sharding-JDBC 定位为轻量级Java框架,在Java的JDBC层提供的额外服务。它使用客户端直连数据库,以jar包形式提供服务,无需额外部署和依赖,可理解为增强版的JDBC驱动,完全兼容DBC和各种ORM框架。 - 适用于任何基于Java的ORM框架,如:JPA, Hibernate, Mybatis, Spring JDBC Template或直接使用JDBC。 - 基于任何第三方的数据库连接池,如:DBCP 基于任何第三方的数据库连接池,如:DBCP, C3P0, BoneCP, Druid, HikariCP等。 - 支持任意实现JDBC规范的数据库。目前支持MySQL,Oracle,SQLServer和PostgreSQL。  ### 1.3 认识Sharding-Proxy0 码力 | 6 页 | 781.70 KB | 2 年前3
CLICKHOUSE И DBEAVER, ИЛИ KOMY HyЖEH JDBC?## DBeaver CLICKHOUSE И ДВЕАVER, ИЛИ КОМУ НУЖЕН JDBC? dbeaver.com ## 1  ## DBeaver Универсальный интерфейс для работы ЮДС-ДРАЙВЕРЕ В ДВУХ СЛОВАХ √ JDBC-драйвер для Clickhouse есть и даже не один Х Никто не идеален, и JDBC-драйвер тоже ## СЛОЖНОСТИ ## ! 1. Соответствие спецификации JDBC 2. Новая версия драйвера не не всегда работает 3. Существование разных JDBC-драйверов 4. Нехватка аналитических функций ## COOTBETCTBIE JDBC API ## ВОПРОСЫ • Нестандартно возвращаются значения массивов • Метаданные о числовых0 码力 | 9 页 | 2.16 MB | 2 年前3
2 Sharding-JDBC入门使用## 2 Sharding-JDBC入门使用 ### 2.1 不使用 Spring ## 引入Maven依赖 ## 基于Java编码的规则配置 Sharding-JDBC的分库分表通过规则配置描述,以下例子是根据user_id取模分库,且根据order_id取模分表的两库两表的配置。 // 配置真实数据源 Maporg.apache.shardingsphere sharding-jdbc-core ${sharding-sphere.version} version}dataSourceMap = new HashMap<>(); // dataSource1 = new BasicDataSource(); dataSource1.setDriverClassName("com.mysql.jdbc.Driver"); dataSource1.setUrl("jdbc:mysql://localhost:3306/ds0"); dataSource1.setUsername("root"); dataSource1 0 码力 | 12 页 | 325.38 KB | 2 年前3
使用JDBC连接数据库## ☐ ## 使用JDBC连接数据库 北京理工大学计算机学院金旭亮 ## Java数据库应用程序全局视图 Java应用程序 JDBC数据库驱动(*.jar) JDBC规定了一整套访问数据库的标准API,所有数据库都需要实现它,因此,使用JDBC访问数据库的Java应用程序,是很容易切换底层数据库的。 ## JDBC核心类型一览表 |核心类型 (java.sql)|说明| |---|---| ... ## JDBC访问数据库的基本步骤 加载JDBC驱动程序 创建数据库连接 执行SQL语句 接收并处理SQL的返回结果 关闭创建的各个对象 对于有可视化界面的应用程序,或者是Server端应用程序,应该在独立的线程中完成这些步骤。 出于精简学习负担的目的,我们将以SQLite为例介绍JDBC的基本使用,在此基础之上,后面选择微软的SQL Server来介绍JDBC的高级特性…… e583e2ed112ca27/p6_1.jpg) ## JDBC连接SQLite数据库 ## 下载SQLite的JDBC驱动-1 SQLite官网上没有直接提供java的驱动程序组件包,可以通过搜索引擎搜索“sqlite jdbc”找到相应的包。 GitHub - xerial/sqlite-jdbc: SQLite JDBC Driver Another difference is that0 码力 | 20 页 | 1.02 MB | 2 年前3
Apache ActiveMQ Artemis 2.23.1 User Manualmanagement.xml use:2. If you're using JDBC persistence then due to the changes in ARTEMIS-3679 you'll need to update your database. The column command-line option to transfer messages. • Performance improvements for the wildcard address manager. - JDBC datasource property values can now be masked. • Lots of usability improvements to the Hawto 2 based that supports replication • Consumer window size support for individual STOMP clients • Improved JDBC connection management • New web console based on Hawto 2 • Performance optimizations (i.e. caching) 0 码力 | 503 页 | 6.35 MB | 2 年前3
Spring Framework 3.1.1 Changelog"key-generator" attribute * introduced CustomSQLExceptionTranslatorRegistry/Registrar for JDBC error code translation * officially deprecated TopLinkJpaDialect in favor of EclipseLink and Spring's (SPR-8751) * prepared Spring's DataSource and RowSet adapters for forward compatibility with JDBC 4.1 * introduced ForkJoinPoolFactoryBean for Java 7 (alternative: add new jsr166.jar to Java 6) for queryForInt/Long * jdbc:script's "separator" and "execution" attributes work nested with embedded- * added "encoding" attribute to jdbc:script element * JavaMailSenderImpl0 码力 | 23 页 | 64.04 KB | 2 年前3
Spring Framework 3.1.3 Changelogcreated early for JPA weaving to work reliably * Spring-backed DataSources consistently implement JDBC 4.0's wrapper interface * optimized ResourceDatabasePopulation to work around JDK 1.7 * fixed @PropertySource placeholder resolution to apply to all specified values * JDBC parameter binding uses JDBC 3.0 ParameterMetaData (if available) for type determination * added "jtaTransactionManager" en's "key-generator" * introduced CustomSQLExceptionTranslatorRegistry/Registrar for JDBC error code translation * officially deprecated TopLinkJpaDialect in favor of EclipseLink and Spring's0 码力 | 25 页 | 69.19 KB | 2 年前3
Spring Framework 2.0.6 Changelogcloses freshly obtained JarFile objects, to allow for hot redeployment Package org.springframework.jdbc $ ^{*} $ fixed SQLErrorCodeSQExceptionTranslator to avoid potential NPE in debug log * moved getPackage()" to work Package org.springframework.jdbc fixed GeneratedKeyHolder to avoid NPE in exception message in case of a null key returned by the JDBC driver fixed JdbcTemplate's fallback support CciDaoSupport, for obtaining a template with just different con spec Package org.springframework.jdbc * SqlOperation and its subclasses do not pre-parse for named parameters anymore, accepting ":"0 码力 | 57 页 | 161.42 KB | 2 年前3
Spring Framework 3.1.2 Changelogfixed @PropertySource placeholder resolution to apply to all specified values * JDBC parameter binding uses JDBC 3.0 ParameterMetaData (if available) for type determination * added "jtaTransactionManager" en's "key-generator" * introduced CustomSQLExceptionTranslatorRegistry/Registrar for JDBC error code translation * officially deprecated TopLinkJpaDialect in favor of EclipseLink and Spring's (SPR-8751) * prepared Spring's DataSource and RowSet adapters for forward compatibility with JDBC 4.1 * introduced ForkJoinPoolFactoryBean for Java 7 (alternative: add new jsr166.jar to Java 6)0 码力 | 24 页 | 66.17 KB | 2 年前3
共 670 条
- 1
- 2
- 3
- 4
- 5
- 6
- 67













