Sounds a bit like a cross between the (now defunct) Google Sawzall project and the sqlite csvtable module:<p><a href="https:&#x2F;&#x2F;github.com&#x2F;softace&#x2F;sqliteodbc&#x2F;blob&#x2F;master&#x2F;csvtable.c" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;softace&#x2F;sqliteodbc&#x2F;blob&#x2F;master&#x2F;csvtable.c</a>