0

I'm currently running into issues within the `python:3.11-buster` image whereby recent sqlite3 changes which added in v.3.35 of sqlite aren't working, e.g., sqrt (https://antonz.org/sqlite-3-35/):

sqlite3.OperationalError: no such function: sqrt

I've added the following lines to my Dockerfile:

# Install sqlite3
RUN apt-get update && \
  DEBIAN_FRONTEND=noninteractive apt-get -yq --no-install-recommends install sqlite3=3.* && \
  rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* && \
  mkdir -p /root/db

However, the issue still persists ...

If anyone could point me in the right direction to get mathematical functions to work I'd be eternally grateful ...

Micheal J. Roberts
  • 3,735
  • 4
  • 37
  • 76
  • Math functions are not supported in the standard release of SQLite 3.35.0+ You need to use the -DSQLITE_ENABLE_MATH_FUNCTIONS compile-time option yo make them available. Check https://sqlite.org/changes.html and https://sqlite.org/compile.html#enable_math_functions – forpas Nov 29 '22 at 19:11
  • @forpas Ah I see. Do you know a way to get this working with SQLAlchemy? – Micheal J. Roberts Nov 29 '22 at 19:27

0 Answers0