亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? metadataregressiontest.java

?? 用于JAVA數(shù)據(jù)庫連接.解壓就可用,方便得很
?? JAVA
?? 第 1 頁 / 共 5 頁
字號(hào):
			createTable(tableName,					"(binary_field BINARY(32), varbinary_field VARBINARY(64))");			try {				this.rs = this.conn.getMetaData().getColumns(						this.conn.getCatalog(), null, tableName, "%");				assertTrue(this.rs.next());				assertEquals(Types.BINARY, this.rs.getInt("DATA_TYPE"));				assertEquals(32, this.rs.getInt("COLUMN_SIZE"));				assertTrue(this.rs.next());				assertEquals(Types.VARBINARY, this.rs.getInt("DATA_TYPE"));				assertEquals(64, this.rs.getInt("COLUMN_SIZE"));				this.rs.close();				this.rs = this.stmt						.executeQuery("SELECT binary_field, varbinary_field FROM "								+ tableName);				ResultSetMetaData rsmd = this.rs.getMetaData();				assertEquals(Types.BINARY, rsmd.getColumnType(1));				assertEquals(32, rsmd.getPrecision(1));				assertEquals(Types.VARBINARY, rsmd.getColumnType(2));				assertEquals(64, rsmd.getPrecision(2));				this.rs.close();			} finally {				if (this.rs != null) {					this.rs.close();				}			}		}	}	/**	 * Tests fix for BUG#12975 - OpenOffice expects DBMD.supportsIEF() to return	 * "true" if foreign keys are supported by the datasource, even though this	 * method also covers support for check constraints, which MySQL _doesn't_	 * have.	 * 	 * @throws Exception	 *             if the test fails.	 */	public void testBug12975() throws Exception {		assertEquals(false, this.conn.getMetaData()				.supportsIntegrityEnhancementFacility());		Connection overrideConn = null;		try {			Properties props = new Properties();			props.setProperty("overrideSupportsIntegrityEnhancementFacility",					"true");			overrideConn = getConnectionWithProps(props);			assertEquals(true, overrideConn.getMetaData()					.supportsIntegrityEnhancementFacility());		} finally {			if (overrideConn != null) {				overrideConn.close();			}		}	}	/**	 * Tests fix for BUG#13277 - RSMD for generated keys has NPEs when a	 * connection is referenced.	 * 	 * @throws Exception	 */	public void testBug13277() throws Exception {		if (isRunningOnJdk131()) {			return; // test not valid on JDK-1.3.1		}		createTable("testBug13277",				"(field1 INT NOT NULL PRIMARY KEY AUTO_INCREMENT, field2 VARCHAR(32))");		try {			this.stmt.executeUpdate(					"INSERT INTO testBug13277 (field2) VALUES ('abcdefg')",					Statement.RETURN_GENERATED_KEYS);			this.rs = this.stmt.getGeneratedKeys();			ResultSetMetaData rsmd = this.rs.getMetaData();			checkRsmdForBug13277(rsmd);			this.rs.close();			for (int i = 0; i < 5; i++) {				this.stmt						.addBatch("INSERT INTO testBug13277 (field2) VALUES ('abcdefg')");			}			this.stmt.executeBatch();			this.rs = this.stmt.getGeneratedKeys();			rsmd = this.rs.getMetaData();			checkRsmdForBug13277(rsmd);			this.rs.close();			this.pstmt = this.conn.prepareStatement(					"INSERT INTO testBug13277 (field2) VALUES ('abcdefg')",					Statement.RETURN_GENERATED_KEYS);			this.pstmt.executeUpdate();			this.rs = this.pstmt.getGeneratedKeys();			rsmd = this.rs.getMetaData();			checkRsmdForBug13277(rsmd);			this.rs.close();			this.pstmt.addBatch();			this.pstmt.addBatch();			this.pstmt.executeUpdate();			this.rs = this.pstmt.getGeneratedKeys();			rsmd = this.rs.getMetaData();			checkRsmdForBug13277(rsmd);			this.rs.close();		} finally {			if (this.pstmt != null) {				this.pstmt.close();				this.pstmt = null;			}			if (this.rs != null) {				this.rs.close();				this.rs = null;			}		}	}	/**	 * Tests BUG13601 (which doesn't seem to be present in 3.1.11, but we'll	 * leave it in here for regression's-sake).	 * 	 * @throws Exception	 *             if the test fails.	 */	public void testBug13601() throws Exception {		if (versionMeetsMinimum(5, 0)) {			createTable("testBug13601",					"(field1 BIGINT NOT NULL, field2 BIT default 0 NOT NULL) ENGINE=MyISAM");			this.rs = this.stmt					.executeQuery("SELECT field1, field2 FROM testBug13601 WHERE 1=-1");			ResultSetMetaData rsmd = this.rs.getMetaData();			assertEquals(Types.BIT, rsmd.getColumnType(2));			assertEquals(Boolean.class.getName(), rsmd.getColumnClassName(2));			this.rs = this.conn.prepareStatement(					"SELECT field1, field2 FROM testBug13601 WHERE 1=-1")					.executeQuery();			rsmd = this.rs.getMetaData();			assertEquals(Types.BIT, rsmd.getColumnType(2));			assertEquals(Boolean.class.getName(), rsmd.getColumnClassName(2));		}	}	/**	 * Tests fix for BUG#14815 - DBMD.getColumns() doesn't return TABLE_NAME	 * correctly.	 * 	 * @throws Exception	 *             if the test fails	 */	public void testBug14815() throws Exception {		try {			createTable("testBug14815_1", "(field_1_1 int)");			createTable("testBug14815_2", "(field_2_1 int)");			boolean lcTableNames = this.conn.getMetaData()					.storesLowerCaseIdentifiers();			String tableName1 = lcTableNames ? "testbug14815_1"					: "testBug14815_1";			String tableName2 = lcTableNames ? "testbug14815_2"					: "testBug14815_2";			this.rs = this.conn.getMetaData().getColumns(					this.conn.getCatalog(), null, "testBug14815%", "%");			assertTrue(this.rs.next());			assertEquals(tableName1, this.rs.getString("TABLE_NAME"));			assertEquals("field_1_1", this.rs.getString("COLUMN_NAME"));			assertTrue(this.rs.next());			assertEquals(tableName2, this.rs.getString("TABLE_NAME"));			assertEquals("field_2_1", this.rs.getString("COLUMN_NAME"));		} finally {			if (this.rs != null) {				this.rs.close();				this.rs = null;			}		}	}	/**	 * Tests fix for BUG#15854 - DBMD.getColumns() returns wrong type for BIT.	 * 	 * @throws Exception	 *             if the test fails.	 */	public void testBug15854() throws Exception {		if (versionMeetsMinimum(5, 0)) {			createTable("testBug15854", "(field1 BIT)");			try {				this.rs = this.conn.getMetaData().getColumns(						this.conn.getCatalog(), null, "testBug15854", "field1");				assertTrue(this.rs.next());				assertEquals(Types.BIT, this.rs.getInt("DATA_TYPE"));			} finally {				if (this.rs != null) {					ResultSet toClose = this.rs;					this.rs = null;					toClose.close();				}			}		}	}	/**	 * Tests fix for BUG#16277 - Invalid classname returned for	 * RSMD.getColumnClassName() for BIGINT type.	 * 	 * @throws Exception	 *             if the test fails.	 */	public void testBug16277() throws Exception {		createTable("testBug16277", "(field1 BIGINT, field2 BIGINT UNSIGNED)");		ResultSetMetaData rsmd = this.stmt.executeQuery(				"SELECT field1, field2 FROM testBug16277").getMetaData();		assertEquals("java.lang.Long", rsmd.getColumnClassName(1));		assertEquals("java.math.BigInteger", rsmd.getColumnClassName(2));	}	/**	 * Tests fix for BUG#18554 - Aliased column names where length of name > 251	 * are corrupted.	 * 	 * @throws Exception	 *             if the test fails.	 */	public void testBug18554() throws Exception {		testBug18554(249);		testBug18554(250);		testBug18554(251);		testBug18554(252);		testBug18554(253);		testBug18554(254);		testBug18554(255);	}	private void testBug18554(int columnNameLength) throws Exception {		StringBuffer buf = new StringBuffer(columnNameLength + 2);		for (int i = 0; i < columnNameLength; i++) {			buf.append((char) ((Math.random() * 26) + 65));		}		String colName = buf.toString();		this.rs = this.stmt.executeQuery("select curtime() as `" + colName				+ "`");		ResultSetMetaData meta = this.rs.getMetaData();		assertEquals(colName, meta.getColumnLabel(1));	}	private void checkRsmdForBug13277(ResultSetMetaData rsmd)			throws SQLException {		assertEquals(17, rsmd.getColumnDisplaySize(1));		if (versionMeetsMinimum(4, 1)) {			assertEquals(false, rsmd.isDefinitelyWritable(1));			assertEquals(true, rsmd.isReadOnly(1));			assertEquals(false, rsmd.isWritable(1));		}	}	public void testSupportsCorrelatedSubqueries() throws Exception {		DatabaseMetaData dbmd = this.conn.getMetaData();		assertEquals(versionMeetsMinimum(4, 1), dbmd				.supportsCorrelatedSubqueries());	}	public void testSupportesGroupByUnrelated() throws Exception {		DatabaseMetaData dbmd = this.conn.getMetaData();		assertEquals(true, dbmd.supportsGroupByUnrelated());	}	/**	 * Tests fix for BUG#21267, ParameterMetaData throws NullPointerException	 * when prepared SQL actually has a syntax error	 * 	 * @throws Exception	 */	public void testBug21267() throws Exception {		if (isRunningOnJdk131()) {			return; // no parameter metadata on JDK-1.3.1		}				createTable(				"bug21267",				"(`Col1` int(11) NOT NULL,`Col2` varchar(45) default NULL,`Col3` varchar(45) default NULL,PRIMARY KEY  (`Col1`))");		try {			this.pstmt = this.conn					.prepareStatement("SELECT Col1, Col2,Col4 FROM bug21267 WHERE Col1=?");			this.pstmt.setInt(1, 1);			java.sql.ParameterMetaData psMeta = this.pstmt					.getParameterMetaData();			try {				assertEquals(0, psMeta.getParameterType(1));			} catch (SQLException sqlEx) {				assertEquals(SQLError.SQL_STATE_DRIVER_NOT_CAPABLE, sqlEx.getSQLState());			}						this.pstmt.close();						Properties props = new Properties();			props.setProperty("generateSimpleParameterMetadata", "true");						this.pstmt = getConnectionWithProps(props).prepareStatement("SELECT Col1, Col2,Col4 FROM bug21267 WHERE Col1=?");						psMeta = this.pstmt.getParameterMetaData();						assertEquals(Types.VARCHAR, psMeta.getParameterType(1));		} finally {			closeMemberJDBCResources();		}	}	/**	 * Tests fix for BUG#21544 - When using information_schema for metadata, 	 * COLUMN_SIZE for getColumns() is not clamped to range of 	 * java.lang.Integer as is the case when not using 	 * information_schema, thus leading to a truncation exception that 	 * isn't present when not using information_schema.	 * 	 * @throws Exception if the test fails	 */	public void testBug21544() throws Exception {		if (!versionMeetsMinimum(5, 0)) {			return;		}				createTable("testBug21544",	            "(foo_id INT NOT NULL, stuff LONGTEXT"	            + ", PRIMARY KEY (foo_id)) TYPE=INNODB");				Connection infoSchemConn = null;				Properties props = new Properties();		props.setProperty("useInformationSchema", "true");		props.setProperty("jdbcCompliantTruncation", "false");				infoSchemConn = getConnectionWithProps(props);				try {	        this.rs = infoSchemConn.getMetaData().getColumns(null, null, 	        		"testBug21544",	                null);	        	        while (rs.next()) {	        	rs.getInt("COLUMN_SIZE");   	        }	    } finally {	        if (infoSchemConn != null) {	        	infoSchemConn.close();	        }	        	        closeMemberJDBCResources();	    }	}	/** 	 * Tests fix for BUG#22613 - DBMD.getColumns() does not return expected	 * COLUMN_SIZE for the SET type (fixed to be consistent with the ODBC driver)	 * 	 * @throws Exception if the test fails	 */	public void testBug22613() throws Exception {				createTable("bug22613", "( s set('a','bc','def','ghij') default NULL, t enum('a', 'ab', 'cdef'))");		try {			checkMetadataForBug22613(this.conn);						if (versionMeetsMinimum(5, 0)) {				Connection infoSchemConn = null;							try {					Properties props = new Properties();					props.setProperty("useInformationSchema", "true");										infoSchemConn = getConnectionWithProps(props);										checkMetadataForBug22613(infoSchemConn);				} finally {					if (infoSchemConn != null) {						infoSchemConn.close();					}				}

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號(hào) Ctrl + =
減小字號(hào) Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
久久久久国产精品厨房| 婷婷国产在线综合| 国产三级精品三级在线专区| 亚洲天堂福利av| 污片在线观看一区二区| 激情综合色播激情啊| 91美女精品福利| 久久免费午夜影院| 日本免费在线视频不卡一不卡二| 成人免费毛片app| 日韩天堂在线观看| 日韩精品一二三| 国产一区二区三区免费看| 在线观看免费亚洲| 中文字幕亚洲区| 国产一区在线视频| 91精品黄色片免费大全| 亚洲国产你懂的| 成人黄色电影在线| 欧美挠脚心视频网站| 亚洲自拍与偷拍| 成人激情av网| 欧美军同video69gay| 亚洲在线中文字幕| 成人一区二区在线观看| 69堂精品视频| 亚洲精品欧美专区| 亚欧色一区w666天堂| 色又黄又爽网站www久久| 欧美激情一二三区| 国内久久精品视频| 日韩欧美在线观看一区二区三区| 亚洲自拍欧美精品| av一区二区三区在线| 中文字幕一区二区三区蜜月| 国产成人免费av在线| 久久久久久久久久久99999| 国产精品996| 国产亚洲欧美色| 国产乱码精品1区2区3区| 欧美经典一区二区三区| 国产91对白在线观看九色| 精品国产一区二区三区不卡| 国产成人一区在线| 欧美激情综合在线| 岛国精品在线播放| 一区二区三区四区国产精品| 91网页版在线| 中文字幕在线一区二区三区| 99re视频这里只有精品| 亚洲日本在线天堂| 5858s免费视频成人| 日本特黄久久久高潮| 欧美xxxxxxxx| 成人深夜在线观看| 自拍偷自拍亚洲精品播放| a级高清视频欧美日韩| 亚洲最大成人综合| 欧美一区二区黄| 国产乱子伦视频一区二区三区 | 午夜电影久久久| 精品av久久707| 国产成人亚洲综合a∨猫咪| 亚洲国产精品激情在线观看| 欧美视频一区在线| 蜜桃av一区二区| 国产欧美日韩在线| 制服丝袜亚洲播放| 国产一区二区三区免费观看| 中文子幕无线码一区tr| 欧美日韩国产乱码电影| 蜜桃av噜噜一区| 中文字幕的久久| 欧美丰满高潮xxxx喷水动漫| 精品在线播放免费| 欧美激情综合网| 5858s免费视频成人| 国产白丝网站精品污在线入口| 日本韩国欧美一区| 韩国在线一区二区| 亚洲欧美经典视频| 麻豆91在线播放| 亚洲va在线va天堂| 久久综合九色综合97婷婷| 成人理论电影网| 日本特黄久久久高潮| 亚洲欧美日韩综合aⅴ视频| 精品99久久久久久| 欧美日韩国产不卡| 成人夜色视频网站在线观看| 精品在线亚洲视频| 午夜亚洲福利老司机| 日韩免费性生活视频播放| 色偷偷88欧美精品久久久| 久久精品国产网站| 亚洲精品亚洲人成人网在线播放| 欧美激情资源网| 欧美成人性战久久| 91麻豆精品国产91久久久资源速度| 成人网页在线观看| 激情综合五月婷婷| 国产一区三区三区| 五月天亚洲婷婷| 一区二区三区在线视频免费| 亚洲男人电影天堂| 国产精品久久三区| 国产精品卡一卡二卡三| 国产亚洲精品福利| 日韩一级完整毛片| 欧美tickling网站挠脚心| 欧美日韩免费观看一区三区| 99久久777色| 日本精品一区二区三区高清 | 国产精品麻豆一区二区| 欧美国产日韩亚洲一区| xvideos.蜜桃一区二区| 91美女片黄在线| 91成人免费在线| 91麻豆免费看| 欧美在线观看视频一区二区 | 性欧美大战久久久久久久久| 亚洲成人综合网站| 性做久久久久久| 亚洲综合色网站| 日本美女一区二区| 日韩高清在线一区| 亚洲高清不卡在线观看| 亚洲国产精品久久久久婷婷884| 亚洲免费色视频| 肉丝袜脚交视频一区二区| 亚洲国产成人精品视频| 亚洲一区av在线| 极品少妇一区二区| 国产精品综合一区二区| 岛国精品在线观看| 欧美午夜精品理论片a级按摩| 欧美视频日韩视频| 日韩西西人体444www| 国产午夜精品在线观看| 国产精品理伦片| 亚欧色一区w666天堂| 久久国产人妖系列| 国产a级毛片一区| 欧美电影免费提供在线观看| 亚洲一区二区三区精品在线| 亚洲综合清纯丝袜自拍| 九九精品一区二区| 国产精品一区二区三区乱码| 懂色av中文一区二区三区| 欧美日韩专区在线| 欧美精品久久久久久久久老牛影院| 欧美午夜一区二区三区 | 综合激情成人伊人| 首页国产欧美日韩丝袜| 韩国成人在线视频| 91久久国产最好的精华液| 欧美老人xxxx18| 日韩精品专区在线| 亚洲视频每日更新| 天堂av在线一区| 久久99热国产| 色综合网色综合| 欧美一区二区在线免费观看| 综合分类小说区另类春色亚洲小说欧美 | 亚洲欧美视频一区| 国内外成人在线视频| 93久久精品日日躁夜夜躁欧美| 欧美日韩国产电影| 亚洲伦理在线免费看| 久久精品国产久精国产| 99久久精品免费精品国产| 久久亚洲综合av| 亚洲午夜精品17c| 免费成人你懂的| 欧美美女一区二区在线观看| 久久综合九色综合97婷婷 | 这里只有精品电影| 中文字幕综合网| 国产剧情av麻豆香蕉精品| 欧美日高清视频| 国产精品妹子av| 国产精品自产自拍| 欧美一区二区女人| 亚洲欧洲日本在线| 久久精品99国产精品| 91成人网在线| 亚洲精品视频一区| av中文字幕一区| 国产精品久久久久一区二区三区共| 琪琪久久久久日韩精品| 欧美日韩一区高清| 亚洲免费高清视频在线| 色婷婷综合久久久中文一区二区| 国产精品精品国产色婷婷| 成人黄页毛片网站| ...xxx性欧美| 欧洲国内综合视频| 五月婷婷另类国产| 日韩一区二区三区免费看| 蜜臀久久99精品久久久久宅男 |