GithubHelp home page GithubHelp logo

basemax / mysqlcalc Goto Github PK

View Code? Open in Web Editor NEW
3.0 3.0 0.0 40 KB

A MySQL/MariaDB module and plugin to calculate the formula and calculate mathematical expression in SQL Query.

License: GNU General Public License v3.0

C++ 10.56% C 89.44%
mysql-udf udf-mysql mariadb-udf udf-mariadb cpp c cc calc cpp-calc calc-engine

mysqlcalc's Introduction

M-Calc, MCalc

MCalc Exmaple

select mcalc('5+5*2/2') as valu;
select mcalc('5+cos(0)') as valu;
select mcalc('5+pi*2)') as valu;

MariaDB-MySQL Calculator

A MySQL/MariaDB module and plugin to calculate the formula and calculate mathematical expression.

MariaDB-Mysql UDF

Extend your MySQL server with additional functions

UDF Plugin-Module for MySQL

Compiling

gcc -shared -o mcalc.so mcalc.cc evaluation.c -std=c++11 -fPIC
cd sql
make mcalc.o

Installing module

CREATE FUNCTION mcalc RETURNS double SONAME "mcalc.so";

Uninstalling module

DROP FUNCTION mcalc;

MariaDB-MySQL Calc

Add module as mysql plugins

It will show path where to put the .so file:

SHOW VARIABLES LIKE 'plugin_dir';

Tested on: MariaDB 10.3.18

MariaDB-MySQL References


Max Base

My nickname is Max, Programming language developer, Full-stack programmer. I love computer scientists, researchers, and compilers.

Asrez Team

A team includes some programmer, developer, designer, researcher(s) especially Max Base.

Asrez Team

mysqlcalc's People

Contributors

basemax avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.