Skip to content
This repository has been archived by the owner on Sep 22, 2020. It is now read-only.

albhasan/SciDB-lua

Repository files navigation

SciDB-lua

Use SciDB from Lua

Tutorial on calling C functions from Lua Here
Tutorial on libcurl Here

PRE-REQUISITES

  • Lua & lua development libraries sudo apt-get install lua5.2 liblua5.2-dev
  • A symbolic link at /usr/include/lua pointing pointing to /usr/include/lua5.x. For example: ln -s /usr/include/lua5.2 /usr/include/lua
  • The file /usr/include/curl/types.h must be present. Otherwise, create it with the following content: /* not used */
  • A SciDB database running the shim web service.

COMPILE

gcc -Wall -shared -fPIC -o shimclient.so -I/usr/include/lua shimc.c -lcurl -I.

USE

  • Create a text file called conf.exe. This text file must contain 4 lines:
    • URL of the public shim interface
    • URL of the dic shim interface
    • Username
    • Password
    Such a file would look like this
    http://mySciDB:8080
    https://mySciDB:8083
    scidb
    mySecretPassword
  • Make sure the following arrays do not exist on the datatbase:
    • iquery -aq "remove(winners)"
    • iquery -aq "remove(winnersFlat)"
    • iquery -aq "remove(event_index)"
  • Run the following command to execute the tests: lua shimc.lua

About

Send queries to SciDB from Lua

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published