2 #Test Case : Creation of user with same name twice should be failed
3 # Connect to root user as:
4 # # csql -u root -p manager
5 # create a user say nihar as:
6 # CSQL> create user nihar password 'nihar123';
7 # create another user with same name nihar
8 # CSQL> create user nihar password 'nihar123';
9 # It should be failed, saying user name in this name already exist.
11 QUITFILE
=${PWD}/tools
/UserStmt
/csql.conf
15 REL_PATH
=`pwd`/tools
/UserStmt
20 rm -f ${REL_PATH}/usr.sql
25 echo "echo create user nihar password 'nihar123';" >${REL_PATH}/usr.sql
26 echo "create user nihar password 'nihar123';" >>${REL_PATH}/usr.sql
27 echo "echo create user nihar password 'nihar321';" >>${REL_PATH}/usr.sql
28 echo "create user nihar password 'nihar321';" >>${REL_PATH}/usr.sql
29 echo "echo drop user nihar;" >>${REL_PATH}/usr.sql
30 echo "drop user nihar;" >>${REL_PATH}/usr.sql
31 echo "quit;" >>${REL_PATH}/usr.sql
33 echo "Connecting User root"
34 if [ "$VALGRIND" = "true" ]
36 valgrind
--tool=memcheck
--leak-check=full
$CSQL_INSTALL_ROOT/bin
/csql
-u root
-p manager
-s ${REL_PATH}/usr.sql
38 $CSQL_INSTALL_ROOT/bin
/csql
-u root
-p manager
-s ${REL_PATH}/usr.sql