Another existing application java framework is running in the MySQL Database for CRM purpose we planning to use frappe framework.
Please confirm can we use the MySQL with Frappe ?
Another existing application java framework is running in the MySQL Database for CRM purpose we planning to use frappe framework.
Please confirm can we use the MySQL with Frappe ?
we are also in same boat, using azure for cloud but they are going remove support for mariadb soon (sep 2025) so we are forced to use mysql, ideally it should be fine but we are still struggling to set that up, so i can say it’s not straight forward, but you can make it work.
Thanks for the response, Have you done the set up MySQL. if any guide please share.
Mysql doesn’t work as well. Tried with following devcontainer docker-compose.yml
version: "3.7"
services:
mariadb:
image: docker.io/mysql:8
platform: linux/amd64
command:
- --character-set-server=utf8mb4
- --collation-server=utf8mb4_unicode_ci
environment:
MYSQL_ROOT_PASSWORD: 123
volumes:
- mariadb-data:/var/lib/mysql
redis-cache:
image: docker.io/redis:alpine
platform: linux/amd64
redis-queue:
image: docker.io/redis:alpine
platform: linux/amd64
frappe:
image: docker.io/frappe/bench:latest
platform: linux/amd64
command: sleep infinity
environment:
- SHELL=/bin/bash
volumes:
- ..:/workspace:cached
# Enable if you require git cloning
# - ${HOME}/.ssh:/home/frappe/.ssh
working_dir: /workspace/development
ports:
- 8000-8005:8000-8005
- 9000-9005:9000-9005
volumes:
mariadb-data:
Here’s the error:
bench new-site --mariadb-user-host-login-scope="%" --db-root-password=123 --admin-password=admin development.localhost
Warning: MariaDB version ['8.4', '3'] is less than 10.6 which is not supported by Frappe
Installing frappe...
Updating DocTypes for frappe : [=== ] 8%
There was an issue while migrating the DocType: Workspace
Traceback (most recent call last):
File "<frozen runpy>", line 198, in _run_module_as_main
File "<frozen runpy>", line 88, in _run_code
File "/workspace/development/frappe-bench/apps/frappe/frappe/utils/bench_helper.py", line 114, in <module>
main()
File "/workspace/development/frappe-bench/apps/frappe/frappe/utils/bench_helper.py", line 20, in main
click.Group(commands=commands)(prog_name="bench")
File "/workspace/development/frappe-bench/env/lib/python3.11/site-packages/click/core.py", line 1161, in __call__
return self.main(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/workspace/development/frappe-bench/env/lib/python3.11/site-packages/click/core.py", line 1082, in main
rv = self.invoke(ctx)
^^^^^^^^^^^^^^^^
File "/workspace/development/frappe-bench/env/lib/python3.11/site-packages/click/core.py", line 1697, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/workspace/development/frappe-bench/env/lib/python3.11/site-packages/click/core.py", line 1697, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/workspace/development/frappe-bench/env/lib/python3.11/site-packages/click/core.py", line 1443, in invoke
return ctx.invoke(self.callback, **ctx.params)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/workspace/development/frappe-bench/env/lib/python3.11/site-packages/click/core.py", line 788, in invoke
return __callback(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/workspace/development/frappe-bench/apps/frappe/frappe/commands/site.py", line 99, in new_site
_new_site(
File "/workspace/development/frappe-bench/apps/frappe/frappe/installer.py", line 117, in _new_site
install_app(app, verbose=verbose, set_as_patched=not source_sql, force=False)
File "/workspace/development/frappe-bench/apps/frappe/frappe/installer.py", line 316, in install_app
sync_for(name, force=force, reset_permissions=True)
File "/workspace/development/frappe-bench/apps/frappe/frappe/model/sync.py", line 111, in sync_for
import_file_by_path(
File "/workspace/development/frappe-bench/apps/frappe/frappe/modules/import_file.py", line 146, in import_file_by_path
import_doc(
File "/workspace/development/frappe-bench/apps/frappe/frappe/modules/import_file.py", line 239, in import_doc
doc.insert()
File "/workspace/development/frappe-bench/apps/frappe/frappe/model/document.py", line 320, in insert
self.run_post_save_methods()
File "/workspace/development/frappe-bench/apps/frappe/frappe/model/document.py", line 1140, in run_post_save_methods
self.run_method("on_update")
File "/workspace/development/frappe-bench/apps/frappe/frappe/model/document.py", line 974, in run_method
out = Document.hook(fn)(self, *args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/workspace/development/frappe-bench/apps/frappe/frappe/model/document.py", line 1334, in composer
return composed(self, method, *args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/workspace/development/frappe-bench/apps/frappe/frappe/model/document.py", line 1316, in runner
add_to_return_value(self, fn(self, *args, **kwargs))
^^^^^^^^^^^^^^^^^^^^^^^^^
File "/workspace/development/frappe-bench/apps/frappe/frappe/model/document.py", line 971, in fn
return method_object(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/workspace/development/frappe-bench/apps/frappe/frappe/core/doctype/doctype/doctype.py", line 511, in on_update
raise e
File "/workspace/development/frappe-bench/apps/frappe/frappe/core/doctype/doctype/doctype.py", line 508, in on_update
frappe.db.updatedb(self.name, Meta(self))
File "/workspace/development/frappe-bench/apps/frappe/frappe/database/mariadb/database.py", line 448, in updatedb
db_table.sync()
File "/workspace/development/frappe-bench/apps/frappe/frappe/database/schema.py", line 41, in sync
self.create()
File "/workspace/development/frappe-bench/apps/frappe/frappe/database/mariadb/schema.py", line 63, in create
frappe.db.sql_ddl(query)
File "/workspace/development/frappe-bench/apps/frappe/frappe/database/database.py", line 413, in sql_ddl
self.sql(query, debug=debug)
File "/workspace/development/frappe-bench/apps/frappe/frappe/database/database.py", line 230, in sql
self._cursor.execute(query, values)
File "/workspace/development/frappe-bench/env/lib/python3.11/site-packages/pymysql/cursors.py", line 153, in execute
result = self._query(query)
^^^^^^^^^^^^^^^^^^
File "/workspace/development/frappe-bench/env/lib/python3.11/site-packages/pymysql/cursors.py", line 322, in _query
conn.query(q)
File "/workspace/development/frappe-bench/env/lib/python3.11/site-packages/pymysql/connections.py", line 563, in query
self._affected_rows = self._read_query_result(unbuffered=unbuffered)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/workspace/development/frappe-bench/env/lib/python3.11/site-packages/pymysql/connections.py", line 825, in _read_query_result
result.read()
File "/workspace/development/frappe-bench/env/lib/python3.11/site-packages/pymysql/connections.py", line 1199, in read
first_packet = self.connection._read_packet()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/workspace/development/frappe-bench/env/lib/python3.11/site-packages/pymysql/connections.py", line 775, in _read_packet
packet.raise_for_error()
File "/workspace/development/frappe-bench/env/lib/python3.11/site-packages/pymysql/protocol.py", line 219, in raise_for_error
err.raise_mysql_exception(self._data)
File "/workspace/development/frappe-bench/env/lib/python3.11/site-packages/pymysql/err.py", line 150, in raise_mysql_exception
raise errorclass(errno, errval)
pymysql.err.OperationalError: (1101, "BLOB, TEXT, GEOMETRY or JSON column 'content' can't have a default value")
frappe@11278a5b883a:/workspace/development/frappe-bench$
I don’t use Azure, so I hadn’t previously heard about this. But you’re quite correct:
Very interesting. I’ve got mixed feelings and cannot decide if …