improved readme

This commit is contained in:
Lunny Xiao 2013-05-12 14:25:36 +08:00
parent aa93d08a8f
commit 8c81e70188
2 changed files with 4 additions and 4 deletions

View File

@ -73,7 +73,7 @@ type User struct {
} }
``` ```
2.1.More mapping rules, please see [Mapping Rules](#-8) 2.1.More mapping rules, please see [Mapping Rules](#mapping)
3.When you set up your program, you can use CreateTables to create database tables. 3.When you set up your program, you can use CreateTables to create database tables.
@ -267,7 +267,7 @@ if err != nil {
``` ```
##Mapping Rules ##Mapping Rules
<a name="8" id="8"></a> <a name="mapping" id="mapping"></a>
1.Struct and struct's fields name should be Pascal style, and the table and column's name default is SQL style. 1.Struct and struct's fields name should be Pascal style, and the table and column's name default is SQL style.
For example: For example:

View File

@ -70,7 +70,7 @@ type User struct {
} }
``` ```
2.1 详细映射规则,请查看[映射规则](#-8) 2.1 详细映射规则,请查看[映射规则](#mapping)
3.在程序初始化时,可能会需要创建表 3.在程序初始化时,可能会需要创建表
@ -162,7 +162,7 @@ res, err := engine.Exec(sql, "xiaolun", 1)
``` ```
##高级用法 ##高级用法
<a name="8" id="8"></a> <a name="mapping" id="mapping"></a>
更高级的用法我们必须要使用session对象session对象在创建时会立刻创建一个数据库连接。 更高级的用法我们必须要使用session对象session对象在创建时会立刻创建一个数据库连接。
``` ```