Regarding your question about SQL queriers: you might want to have a look at OQL:
https://docs.mendix.com/refguide/oql
For external databases, the following might be of interest:
https://docs.mendix.com/howto/integration/how-to-execute-an-sql-statement-on-an-external-database
Regards,
Thorsten
A possible solution would be to use an extra entity for your "Index" and associate the first one with it. You can choose the index you need via a refference selector, you can create new ones, delete old ones and show only your indices in a datagrid.
The benefit is also that you reduce redundancy.