Skip to content
Snippets Groups Projects
Commit 5ffaa992 authored by Dominique Blouin's avatar Dominique Blouin
Browse files

change sql query

parent d08ae866
No related branches found
No related tags found
No related merge requests found
......@@ -61,9 +61,9 @@
<ExternalCommand2Host data="localhost"/>
<ExternalCommand2 data="/packages/uppaal(4.0.11/uppaal /home/enrici/TURTLE/uppaal/spec.xml"/>
<LastOpenFile data="/home/trhuy/Downloads/CSmartCardProtocol.xml"/>
<LastOpenFile data="/home/trhuy/Downloads/SemesterFinalResult/StuxnetModel/stuxnet_6_12_split (1).xml"/>
<ExternalServer data="localhost:12345"/>
<ExternalServer data="10.188.65.215:12345"/>
<LastWindowAttributes x="90" y="25" width="1219" height="597" max="false" />
......
Fri Jun 19 15:15:20 CEST 2015 : Could not listen on port 1527 on host localhost:
java.net.BindException: Address already in use
Sat Jun 27 18:00:11 CEST 2015 : Apache Derby Network Server - 10.11.1.1 - (1616546) started and ready to accept connections on port 1527
----------------------------------------------------------------
Sat Jun 27 18:00:29 CEST 2015:
Booting Derby version The Apache Software Foundation - Apache Derby - 10.11.1.1 - (1616546): instance a816c00e-014e-35bf-5eb2-000043e4831f
on database directory /home/trhuy/TURTLE/crawler/db-derby-10.11.1.1-bin/bin/MyDatabase with class loader sun.misc.Launcher$AppClassLoader@7451b0af
Loaded from file:/home/trhuy/TURTLE/crawler/db-derby-10.11.1.1-bin/lib/derby.jar
java.vendor=Oracle Corporation
java.runtime.version=1.7.0_79-b14
user.dir=/home/trhuy/TURTLE/crawler/db-derby-10.11.1.1-bin/bin
os.name=Linux
os.arch=amd64
os.version=3.13.0-37-generic
derby.system.home=/home/trhuy/TURTLE/crawler/db-derby-10.11.1.1-bin/bin
Database Class Loader started - derby.database.classpath=''
......@@ -175,7 +175,7 @@ public class Database_query {
+ "AND VULNERABILITIES.SCORE BETWEEN ? AND ? \n"
+ "FETCH FIRST ? ROWS ONLY";
System.out.println(querySQL);
//System.out.println(querySQL);
PreparedStatement prep = this.database.getconn().prepareStatement(querySQL);
......
......@@ -224,8 +224,10 @@ public class File_management {
transformer.transform(domSource, sr);
String out = new SimpleDateFormat("dd-MM-yy/hh-mm-ss").format(new Date());
String xmlContent = sr.getWriter().toString();
boolean success = (new File(System.getProperty("user.dir")+"\\results")).mkdir();
File file = new File(System.getProperty("user.dir")+"\\results\\"+out+".xml");
//boolean success = (new File(System.getProperty("user.dir")+"\\results")).mkdir();
//File file = new File(System.getProperty("user.dir")+"\\results\\"+out+".xml");
boolean success = (new File(System.getProperty("user.dir")+"/results")).mkdirs();
File file = new File(System.getProperty("user.dir")+"/results/"+out+".xml");
if (success=false) {
System.out.println("The folder structure does not exist");
}else {
......
......@@ -918,7 +918,6 @@ public class JDialogSearchBox extends javax.swing.JFrame {
}
/**
*
* @param msg
......@@ -1464,14 +1463,26 @@ public class JDialogSearchBox extends javax.swing.JFrame {
* @return a splited, then concaternated with space.
*/
public String splitAndConcat(String input){
String[] splitValue = input.split("(?=\\p{Lu})");
String value = "";
if (splitValue.length>0){
value = splitValue[0];
for (int i =1 ; i < splitValue.length; i ++ ){
value = value + " " + splitValue[i];
if (input.contains("_")){
String[] splitValue = input.split("_");
if (splitValue.length>0){
value = splitValue[0];
for (int i =1 ; i < splitValue.length; i ++ ){
value = value + " " + splitValue[i];
}
}
}else{
String[] splitValue = input.split("(?=\\p{Lu})");
if (splitValue.length>0){
value = splitValue[0];
for (int i =1 ; i < splitValue.length; i ++ ){
value = value + " " + splitValue[i];
}
}
}
return value;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment