func (this *Queries_Amazing) Insert(ctx context.Context, db persist.Runnable) *Query_Amazing_Insert {
	return &Query_Amazing_Insert{
		opts: this.opts,
		ctx:  ctx,
		db:   db,
	}
}
Insert returns a struct that will perform the 'insert' query.
When Execute is called, it will use the following fields:
[id start_time name]
package basic
import (
	sql "database/sql"
	driver "database/sql/driver"
	fmt "fmt"
	io "io"
	proto "github.com/golang/protobuf/proto"
	timestamp "github.com/golang/protobuf/ptypes/timestamp"
	persist "github.com/tcncloud/protoc-gen-persist/persist"
	test "github.com/tcncloud/protoc-gen-persisttests/test"
	context "golang.org/x/net/context"
	codes "google.golang.org/grpc/codes"
	gstatus "google.golang.org/grpc/status"
)
func NopPersistTx(r persist.Runnable) (persist.PersistTx, error) {
	return &ignoreTx{r}, nil
}
type ignoreTx struct {
	r persist.Runnable
}
func (this *ignoreTx) Commit() error   { return nil }
func (this *ignoreTx) Rollback() error { return nil }
func (this *ignoreTx) QueryContext(ctx context.Context, x string, ys ...interface{}) (*sql.Rows, error) {
	return this.r.QueryContext(ctx, x, ys...)
}
func (this *ignoreTx) ExecContext(ctx context.Context, x string, ys ...interface{}) (sql.Result, error) {
	return this.r.ExecContext(ctx, x, ys...)
}
type Runnable interface {
	QueryContext(context.Context, string, ...interface{}) (*sql.Rows, error)
	ExecContext(context.Context, string, ...interface{}) (sql.Result, error)
}
func DefaultClientStreamingPersistTx(ctx context.Context, db *sql.DB) (persist.PersistTx, error) {
	return db.BeginTx(ctx, nil)
}
func DefaultServerStreamingPersistTx(ctx context.Context, db *sql.DB) (persist.PersistTx, error) {
	return NopPersistTx(db)
}
func DefaultBidiStreamingPersistTx(ctx context.Context, db *sql.DB) (persist.PersistTx, error) {
	return NopPersistTx(db)
}
func DefaultUnaryPersistTx(ctx context.Context, db *sql.DB) (persist.PersistTx, error) {
	return NopPersistTx(db)
}
type alwaysScanner struct {
	i *interface{}
}
func (s *alwaysScanner) Scan(src interface{}) error {
	s.i = &src
	return nil
}
type scanable interface {
	Scan(...interface{}) error
	Columns() ([]string, error)
}
type Queries_Amazing struct {
	opts Opts_Amazing
}
func QueriesAmazing(opts ...Opts_Amazing) *Queries_Amazing {
	var myOpts Opts_Amazing
	if len(opts) > 0 {
		myOpts = opts[0]
	} else {
		myOpts = OptsAmazing(&DefaultHooks_Amazing{}, &DefaultTypeMappings_Amazing{})
	}
	return &Queries_Amazing{
		opts: myOpts,
	}
}
func (this *Queries_Amazing) SelectById(ctx context.Context, db persist.Runnable) *Query_Amazing_SelectById {
	return &Query_Amazing_SelectById{
		opts: this.opts,
		ctx:  ctx,
		db:   db,
	}
}
type Query_Amazing_SelectById struct {
	opts Opts_Amazing
	db   persist.Runnable
	ctx  context.Context
}
func (this *Query_Amazing_SelectById) QueryInType_PartialTable()  {}
func (this *Query_Amazing_SelectById) QueryOutType_ExampleTable() {}
func (this *Query_Amazing_SelectById) Execute(x In_Amazing_SelectById) *Iter_Amazing_SelectById {
	var setupErr error
	params := []interface{}{
		func() (out interface{}) {
			out = x.GetId()
			return
		}(),
		func() (out interface{}) {
			mapper := this.opts.MAPPINGS.TimestampTimestamp()
			out = mapper.ToSql(x.GetStartTime())
			return
		}(),
	}
	result := &Iter_Amazing_SelectById{
		tm:  this.opts.MAPPINGS,
		ctx: this.ctx,
	}
	if setupErr != nil {
		result.err = setupErr
		return result
	}
	result.rows, result.err = this.db.QueryContext(this.ctx, "SELECT * from example_table Where id=$1 AND start_time>$2", params...)
	return result
}
func (this *Queries_Amazing) SelectByName(ctx context.Context, db persist.Runnable) *Query_Amazing_SelectByName {
	return &Query_Amazing_SelectByName{
		opts: this.opts,
		ctx:  ctx,
		db:   db,
	}
}
type Query_Amazing_SelectByName struct {
	opts Opts_Amazing
	db   persist.Runnable
	ctx  context.Context
}
func (this *Query_Amazing_SelectByName) QueryInType_Name()          {}
func (this *Query_Amazing_SelectByName) QueryOutType_ExampleTable() {}
func (this *Query_Amazing_SelectByName) Execute(x In_Amazing_SelectByName) *Iter_Amazing_SelectByName {
	var setupErr error
	params := []interface{}{
		func() (out interface{}) {
			out = x.GetName()
			return
		}(),
	}
	result := &Iter_Amazing_SelectByName{
		tm:  this.opts.MAPPINGS,
		ctx: this.ctx,
	}
	if setupErr != nil {
		result.err = setupErr
		return result
	}
	result.rows, result.err = this.db.QueryContext(this.ctx, "SELECT * FROM example_table WHERE name=$1", params...)
	return result
}