Drop user if exists

How can I check if a user already exists - since DROP USER IF EXISTS is not possible ?

Hi Walter!

Thank you for using OmniSci and providing your feedback.

At this time, your request would be a manual two step process. If you have admin privileges, you could use the /u command in omnisql which will retrieve the list of users. You can then manually inspect if the user exists and then use the DROP USER command.

I have added a DROP USER IF EXISTS feature request to our backlog.

Thank you very much for the quick reply.

I’m accessing the database via JDBC - so I would need a SQL query to determine the existence of a user account - any chance ?

Not at this time. We already have a request to allow this type of queries for system information. I will add your vote to that request.

I would prefer the DROP USER IF EXISTS solution - at the moment I can work around the problem - but it would be nice if there was a solution in the foreseeable future. :grinning:

It’s likely that in the future, both of them will materialize on omnisci database :wink:

Hi @walter ,

Recently we added the DROP USER IF EXIST that you needed for full implementation of your tool.

You can refer to syntax in the docs.


Hi @candido.dessanti

Thanks for the tip - this works fine for me now.

But unfortunately, I still have the problem with the 2nd database connection open: https://github.com/omnisci/omniscidb/issues/668

Thanks and best regards


I will take a look to it