1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156
| TabRef[p][16]=reschp.getString("pop2");
TabRef[p][17]=reschp.getString("nom_sw2");
TabRef[p][18]=reschp.getString("num_carte2");
TabRef[p][19]=reschp.getString("port_sw2");
TabRef[p][20]=reschp.getString("port_odf_sw2");
TabRef[p][21]=reschp.getString("port_odf_cl2");
TabRef[p][22]=reschp.getString("troncon2");
TabRef[p][23]=reschp.getString("chambre2");
TabRef[p][24]=reschp.getString("chemin2");
TabRef[p][25]=reschp.getString("attenuation2");
TabRef[p][26]=reschp.getString("onde2");
p++;
}
catch(Exception ex)
{
System.out.println("********************POP Exception:\n"+ex);
}
}
}
reschp.close();
}
public void Test(String V,String T,String P,String SW,String CRT)throws SQLException{
//CL=new class2();
if(!T.equals("")){
for(int i=0;i<TC1.length;i++){
TC1[i]="";
}
System.out.println("fccccccccc IN.fc est: "+T);
ResultSet resultsC = sql.executeQuery("select chambre from chambre where troncon='"+T+"' order by nbr");//.toLowerCase()
int c=0;
if (resultsC != null)
{
while (resultsC.next())
{
try{
TC1[c]=resultsC.getString("chambre");
c++;
}
catch(Exception ex)
{
System.out.println("*********************************Exception:\n"+ex);
}
}
}
resultsC.close();
}
if(!P.equals("")){
for(int i=0;i<SW1.length;i++){
SW1[i]="";
}
ResultSet reschp = sql.executeQuery("select * from switch where pop='"+P+"'");
int p=0;
if (reschp != null)
{
while (reschp.next())
{
try{
SW1[p]=reschp.getString("nom");
p++;
}
catch(Exception ex)
{
System.out.println("********************POP Exception:\n"+ex);
}
}
}
reschp.close();
}
if(!SW.equals("")){
//select num_carte from port where nom_sw='twin_10G_1'group by num_carte
ResultSet reschp = sql.executeQuery("select num_carte from port where nom_sw='"+SW+"' group by num_carte");
int p=0;
if (reschp != null)
{
while (reschp.next())
{
try{
Carte1[p]=reschp.getString("num_carte");
p++;
}
catch(Exception ex)
{
System.out.println("Erreur Carte 2 Exception:\n"+ex.getMessage());
}
}
}
reschp.close();
}
if(!CRT.equals("") && !SW.equals("")){
for(int i=0;i<Port1.length;i++){
Port1[i]="";
}
//select num_carte from port where nom_sw='twin_10G_1'group by num_carte
ResultSet reschp = sql.executeQuery("select * from port where num_carte='"+CRT+"'and nom_sw='"+SW+"' and up_down = false order by id");
int p=0;
if (reschp != null)
{
while (reschp.next())
{
try{
Port1[p]=reschp.getString("num_port");
p++;
}
catch(Exception ex)
{
System.out.println("Erreur Port 2 Exception:\n"+ex.getMessage());
}
}
}
reschp.close();
}
} |
Partager