Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com> Co-authored-by: marbar3778 <marbar3778@yahoo.com>
17 lines
287 B
Go
17 lines
287 B
Go
package postgres
|
|
|
|
import (
|
|
"os"
|
|
|
|
"cosmossdk.io/indexer/postgres/internal/testdata"
|
|
)
|
|
|
|
func ExampleCreateEnumTypeSql() {
|
|
err := CreateEnumTypeSql(os.Stdout, "test", testdata.MyEnum)
|
|
if err != nil {
|
|
panic(err)
|
|
}
|
|
// Output:
|
|
// CREATE TYPE "test_my_enum" AS ENUM ('a', 'b', 'c');
|
|
}
|