diff --git a/components/Sidebar.jsx b/components/Sidebar.jsx
index 960aa028..bf50e003 100644
--- a/components/Sidebar.jsx
+++ b/components/Sidebar.jsx
@@ -145,6 +145,10 @@ export default class Sidebar extends Component {
- – with
- – withSchema
+ - – createSchema
+ - – createSchemaIfNotExists
+ - – dropSchema
+ - – dropSchemaIfExists
- – createTable
- – createTableIfNotExists
- – renameTable
diff --git a/sections/schema.js b/sections/schema.js
index 7b499ed5..c668ae1d 100644
--- a/sections/schema.js
+++ b/sections/schema.js
@@ -25,6 +25,62 @@ export default [
}
]
},
+ {
+ type: "method",
+ method: "createSchema",
+ example: "knex.schema.createSchema(schemaName)",
+ description: "Creates a new schema on the database, only applicable to PostgreSQL.",
+ children: [
+ {
+ type: "runnable",
+ content: `
+ knex.schema.createSchema('private')
+ `
+ }
+ ]
+ },
+ {
+ type: "method",
+ method: "createSchemaIfNotExists",
+ example: "knex.schema.createSchemaIfNotExists(schemaName)",
+ description: "Creates a new schema on the database if it doesn't exists on the database, only applicable to PostgreSQL.",
+ children: [
+ {
+ type: "runnable",
+ content: `
+ knex.schema.createSchemaIfNotExists('private')
+ `
+ }
+ ]
+ },
+ {
+ type: "method",
+ method: "dropSchema",
+ example: "knex.schema.dropSchema(schemaName)",
+ description: "Drops a schema, specified by schemaName, only applicable to PostgreSQL.",
+ children: [
+ {
+ type: "runnable",
+ content: `
+ knex.schema.dropSchema('private')
+ `
+ }
+ ]
+ },
+ {
+ type: "method",
+ method: "dropSchemaIfExists",
+ example: "knex.schema.dropSchemaIfExists(schemaName)",
+ description: "Drops a schema conditionally if the schema exists, specified by schemaName, only applicable to PostgreSQL.",
+ children: [
+ {
+ type: "runnable",
+ content: `
+ knex.schema.dropSchemaIfExists('private')
+ `
+ }
+ ]
+ },
{
type: "method",
method: "createTable",