__init__ (self, table, fieldname, fieldtype, length, default, set_index, options, unique, precision)
No docs
build_for_alter_table (self, current_def)
No docs
default_changed (self, current_def)
No docs
default_changed_for_decimal (self, current_def)
No docs
get_definition (self, with_default=1)
No docs
Basically, a wrapper for oft-used mysql commands. like show tables,databases, variables etc...
0. Simplify / create settings for the restore database source folder
0a. Merge restore database and extract_sql(from frappe_server_tools).
1. Setter and getter for different mysql variables.
2. Setter and getter for mysql variables at global level??
Pass root_conn here for access to all databases.
create_database (self, target)
No docs
create_user (self, user, password, host)
No docs
delete_user (self, target, host)
No docs
No docs
drop table if exists
No docs
get list of databases
get_table_schema (self, table)
Just returns the output of Desc tables.
get_tables_list (self, target=None)
get list of tables
Get variables that match the passed pattern regex
grant_all_privileges (self, target, user, host)
No docs
grant_select_privilges (self, db, table, user, host)
No docs
restore_database (self, target, source, user, password)
No docs
__init__ (self, doctype, prefix=tab)
No docs
No docs
No docs
No docs
No docs
No docs
get_columns_from_docfields (self)
get columns from docfields and custom fields
No docs
No docs
No docs
No docs
Check if change in varchar length isn't truncating the columns
Inherits from frappe.exceptions.ValidationError
frappe.model.db_schema.add_column (doctype, column_name, fieldtype, precision=None)
No docs
frappe.model.db_schema.get_definition (fieldtype, precision=None, length=None)
No docs
frappe.model.db_schema.remove_all_foreign_keys ()
No docs
frappe.model.db_schema.updatedb (dt)
Syncs a DocType
to the table
* creates if required
* updates columns
* updates indices
frappe.model.db_schema.validate_column_name (n)
No docs