tiledb_ctx_alloc(NULL, &ctx);
tiledb_vfs_alloc(ctx, NULL, &vfs);
tiledb_vfs_open(ctx, vfs, "tiledb_vfs.bin", TILEDB_VFS_WRITE, &fh);
tiledb_vfs_write(ctx, fh, &f1, sizeof(float));
tiledb_vfs_write(ctx, fh, s1, strlen(s1));
tiledb_vfs_close(ctx, fh);
// Write binary data again - this will overwrite the previous file
tiledb_vfs_open(ctx, vfs, "tiledb_vfs.bin", TILEDB_VFS_WRITE, &fh);
const char* s2 = "abcdef";
tiledb_vfs_write(ctx, fh, &f1, sizeof(float));
tiledb_vfs_write(ctx, fh, s2, strlen(s2));
tiledb_vfs_close(ctx, fh);
// Append binary data to existing file
tiledb_vfs_open(ctx, vfs, "tiledb_vfs.bin", TILEDB_VFS_APPEND, &fh);
const char* s3 = "ghijkl";
tiledb_vfs_write(ctx, fh, s3, strlen(s3));
tiledb_vfs_close(ctx, fh);