2020年9月13日 星期日

Go Tutorial

 1. Simple

https://michaelchen.tech/golang-programming/write-first-program/

https://ithelp.ithome.com.tw/articles/10157141


https://michaelchen.tech/golang-programming/struct/

GO Tips

 1,  go comment have /* */ 


2.  go function input must declare type 

good:  func myFun(addr string) { ... }

bad:  func myFun(addr ) { ... }



3.  go functin return error type is error

good: func myFun(addr string) (string, error)  {

        if err != nil {

                return "", err

        }

        return "success", nil

}

4. go string connact can use plus



5.  Go cmd parameter use os package

func main() {
    if len(os.Args) != 3 {
        fmt.Println("Usage:", os.Args[0], "PATTERN", "FILE")
        return
    }
    pattern := os.Args[1]
    file := os.Args[2]
    // ...
}

2020年9月11日 星期五

go tcp connect

 https://www.linode.com/docs/development/go/developing-udp-and-tcp-clients-and-servers-in-go/

2020年9月9日 星期三

Mariadb settings

 https://www.azureunali.com/dbmysql-sql-mode%E7%9A%84%E8%A8%AD%E5%AE%9A/


https://rtfm.co.ua/en/aws-rds-sqlstate22001-data-too-long-for-column-using-mariadb-10-2/

2020年9月7日 星期一

PHP setting warnging message

 https://stackoverflow.com/questions/24506642/can-i-get-phps-pdo-to-return-mysql-warnings-instead-of-only-error-messages


2020年9月6日 星期日

Mariasql comment-doucment

 such as /*!5200 set XXX */



ref

https://stackoverflow.com/questions/1916392/how-can-i-get-rid-of-these-comments-in-a-mysql-dump

https://www.techonthenet.com/mariadb/comments.php


http://job.achi.idv.tw/2013/05/02/mysql-annotation-syntax/

mysql partition

 

1. https://cola.workxplay.net/mysql-partitioning-for-performance-optimization/


2. https://mariadb.com/kb/en/partitioning-limitations/

3. https://kkc.github.io/2017/07/07/mysql-partitioning/