SQL – What's possible?

Mar 5, 2012 at 5:45pm

SQL – What's possible?

Hey everybody,

I was thinking about building a SQL database but am not sure what is possible to do with it.

At the moment I have no idea about SQL but it seems like that it could offer a good solution.

So, is it possible to build a complete storage/data system with SQL for Max?
Beside the capability of saving values and attributes of common Max objects
I’d also like to save variables of mxj externals and FTM-Ircam objects.
…further I’d like to be able to save what objects are used within a patcher and how they are connected.

If there’s a way, what could be a first step? Any experiences with SQL and Max?

Greetings,
Alex

#62170
Mar 5, 2012 at 6:14pm

Hi Alex,

MaxMsp comes with a full SQLite installation. Which means that you do much more than just Storing Data.
I.E. group data from different tables, searching for data with specific criteria, all kind of sorting/ordering – working with keys/unique keys etc, and probably the best advantage is that SQL is good in performance when It comet to large set of data.

Here is a quite good introduction of what you can do in SQL.

http://www.w3schools.com/sql/default.asp

I remember that there was a very good article written by a C74 staff member here – but right now I can’t find it…Maybe someone else remembers.
Jan

#224523
Mar 5, 2012 at 6:16pm
#224524
Mar 5, 2012 at 7:56pm

Hey Jan,

thanks a lot! Also for the introduction links. That sounds quite nice.

But what is very unclear to me is in which ways data from Max can be put into the database. In the example patches of the c74 introduction the data is put in kind of manually via patch cords. Is it possible to acces(read/write) values of MaxObjects from a database directly, cordless? Like with scripting names?

As I read in Max SQLite can be realized with Javascript or C. Does one these APIs provide a better functunality for building a database?

Greetings,
Alex

#224525
Mar 6, 2012 at 1:25am

I figured out values from common Max objects can be accessed with the getvalue, setvalue message from C and Javascript.

http://www.cycling74.com/sdk/MaxSDK-6.0.4/html/group__obj.html
Javascript -> Max Help

#224526

You must be logged in to reply to this topic.