Hi
I have attached the Process definition file. I need to move from one node to another . In this example afte the state Node[first] it will go to Dev Connection Node ( Inside I have written a java code which i have mentioned below ) and then after this i have used a decision ,here i want the message= Yes to be passed to decision , so that another node will be called else it will go to end.
My Problem is after the Dev connection Node its not moving to decision. And another thing is how to send the paramter to decision from Dev Conncetion . Please Help me out.
If u have questions please reply me i will post more information for u to help me.
Java Code
public void execute(ExecutionContext context) throws Exception {
String query = "SELECT login_name from rs_users where user_id = 2";
try
{
Class.forName("oracle.jdbc.driver.OracleDriver");
Connection con = DriverManager.getConnection("jdbc:oracle:thin:@localhost:1521:xe","resonancedev","resonancedev");
Statement stmt = con.createStatement();
//int rs = stmt.executeUpdate(query1);
ResultSet rs = stmt.executeQuery(query);
while (rs.next()) {
message = rs.getString("login_name");
message = "Yes";
System.out.println("name-->" +message);
}
con.close();
}
catch (Exception e) {
// TODO: handle exception
message = e.toString();
}
context.getContextInstance().setVariable("message", message);
}