on 2009 Dec 17 3:56 PM
While testing High Availability I want to simulate a failing primary server. Killing the process via task manager would work, but I just wanted a more elegant solution using plain SQL.
Request clarification before answering.
To terminate a server using a SQL statement, you might use xp_cmdshell() together with a command that kills a process (e.g. taskkill on Windows).
The issue that caused the crash with the above CREATE VIEW statement will be fixed in build 11.0.1.2367.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Just submit
create view ConnectionInfo as select Number as ConnNr, Name, Userid, DBNumber, LastReqTime, ReqType, CommLink, NodeAddr,LastIdle, BlockedOn, LockName, UncmtOps, (select value from sa_conn_properties(ConnNr) where PropName= 'PrepStmt' ) PrepStmt, (select convert(integer,isnull(value,0)) from sa_conn_properties(ConnNr) where PropName= 'CursorOpen' ) CursorOpen from sa_conn_info()
This will crash the server instantly (until the bug will be fixed). I'm using 11.0.1.2352.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
OS: Ubuntu10.4 AMD64 / Debian5 AMD64; SQL Anywhere: SA11.0.1.2645 64bit
for shut down server, run query in java isql:
select * from test_table where id=1; select * from test_table where id=2; select * from test_table where id=1 select * from test_table where id=2
ps: case id 11695638
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
52 | |
8 | |
5 | |
5 | |
5 | |
5 | |
5 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.