Changes between Version 3 and Version 4 of NCHCCloudCourse100928_MYSQL
- Timestamp:
- Sep 29, 2010, 9:16:15 AM (15 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
NCHCCloudCourse100928_MYSQL
v3 v4 9 9 [[PageOutline]] 10 10 11 = 說明 = 12 11 13 * 需先安裝 hadoop 0.20 , apache2 , MySQL 5 server & client 12 14 15 * MySQL 內,先建立一個school 的資料庫,內含 teacher 的table ,並新增一些資料,如下: 13 16 [[Image(wiki:NCHCCloudCourse100928_MYSQL:pd1.png)]] 14 17 18 = 程式碼 = 15 19 16 20 = DBAccess.java = … … 50 54 Class.forName("com.mysql.jdbc.Driver"); 51 55 DBConfiguration.configureDB(conf, "com.mysql.jdbc.Driver", 52 "jdbc:mysql://localhost/school", " waue", "wauenchc");56 "jdbc:mysql://localhost/school", "user", "xxxxxxxx"); 53 57 conf.setOutputKeyClass(LongWritable.class); 54 58 conf.setOutputValueClass(Text.class);