I also tried with \ but
[db2usr1@ps0259 ~]$ db2 'connect to QA_DB user db2admin using admin\!@#'
SQL0104N An unexpected token "!" was found following "<identifier>".
Expected tokens may include: "NEW". SQLSTATE=42601
I have to use ! sign in password because thats the requirement.
if u can suggest somethine else then it will be great for me.