Basic iRODS samples

For iRODS C API usage there are numerous examples provided with the installation. However, basic samples for a quick introduction are hidden among the complex ones. Also, some effort is required to find which libraries have to be linked. Few simplified examples are provided here, each on the top with the commands required to compile.

To put a file into iRODS the rcDataObjPut() is used:

putfile.c

To get a file from iRODS the rcDataObjGet() is used

getfile.c

To get all files for the given AVU, the rcGenQuery() with appropriate conditions is used:

avuquery.c

To get all AVUs for the given file, the rcGenQuery() with appropriate conditions is used:

avufile.c

Samples are tested under Linux and iRODS 3.2.

ready.

10 print "mail: contact at alepho.com | skype: karastojko | stackoverflow: karastojko | github: karastojko"
20 print "(c) 2009-2023 www.alepho.com"