Permalink
Browse files

Started implementing renameColumn.

  • Loading branch information...
1 parent 21a9f86 commit 18bdffd2da224f19c28457122a2e3e160246bd47 @akinnunen akinnunen committed Feb 27, 2013
Showing with 11 additions and 2 deletions.
  1. +11 −2 lib/driver/mysql.js
View
13 lib/driver/mysql.js
@@ -132,8 +132,17 @@ var MysqlDriver = Base.extend({
var sql = util.format('DROP INDEX %s ON %s', indexName, tableName);
this.runSql(sql, callback);
},
-// renameColumn: function(tableName, oldColumnName, newColumnName, callback) {
-// },
+
+ renameColumn: function(tableName, oldColumnName, newColumnName, callback) {
+
+ var sql = "select column_type from information_schema.columns where table_name = 'files' and column_name = 'otsikko';"
+
+ this.runSql(sql, function(foo) {
+ console.log(foo);
+ });
+
+
+ },
changeColumn: function(tableName, columnName, columnSpec, callback) {
var constraint = this.createColumnDef(columnName, columnSpec);

0 comments on commit 18bdffd

Please sign in to comment.