Skip to content

Commit

Permalink
Merge branch 'master' of ssh://github.com/k1LoW/tbls
Browse files Browse the repository at this point in the history
  • Loading branch information
k1LoW committed Jul 24, 2018
2 parents 0b3c442 + 7c3ecfc commit 842746a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions db/db.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,11 +44,11 @@ func Analyze(urlstr string) (*schema.Schema, error) {
case "mysql":
driver = new(mysql.Mysql)
default:
return s, fmt.Errorf("Error: %s", "unsupported driver")
return s, errors.WithStack(fmt.Errorf("Error: %s", "unsupported driver"))
}
err = driver.Analyze(db, s)
if err != nil {
return s, errors.WithStack(err)
return s, err
}
return s, nil
}
2 changes: 1 addition & 1 deletion schema/schema.go
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ func (t *Table) FindColumnByName(name string) (*Column, error) {
return c, nil
}
}
return nil, errors.WithStack(fmt.Errorf("Error: not found column '%s'", name))
return nil, errors.WithStack(fmt.Errorf("Error: not found column '%s.%s'", t.Name, name))
}

// Sort schema tables, columns, relations, and constrains
Expand Down

0 comments on commit 842746a

Please sign in to comment.