I'm developing a product installer for an application that has to create a database on a DB2 during installation process. Since the database to be imported is very complex we have to check that the user has DB2 administrative privileges. Is this possible via command line call, or do I need to use a specific API library?
that's exactly the case we want to avoid with this check ;-)
Can you explain why?
The user needs SYSADM or SYSCTRL authority to create a database. How you determine that depends on the DB2 version, operating system, a number of registry variables, security plugin in place, and some instance configuration settings.