chamoretto / lib-mysql-curl

libmsqlcurl - lib for mysql and curl binding

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

MySQL UDF for curl utilities

Simple library connecting curl and MySQL

Running

Only for Unix-compatible OS

Requirements

libcurl4-openssl-dev
libmysqlclient development software
mysql

Installation

sudo ./install.sh

Usage

SELECT send_<post/put/delete>([<URL or IP with port>], data1 as alias1, data2 as alias2, ...)
FROM ...;

equivalent to

curl -X <POST/PUT/DELETE/> "<URL or IP with port>" \
-H "Content-Type: application/json" \
-d "{
      \"alias1\":\"data1\",
      \"alias2\":\"data2\",
      ...
    }"

Returns response code per request if request was somehow delivered

NULL if something went wrong;

About

libmsqlcurl - lib for mysql and curl binding

License:MIT License


Languages

Language:C 70.6%Language:Shell 15.3%Language:TSQL 12.5%Language:Makefile 1.6%