 only when there are values for the row data.
Please find below my code

String[] resultLines = data.split("\n", 0);

parsedResult = new String[resultLines.length][];
String cols[] = resultLines[1].split("\\s+");
String[] columnsParsed = new String[cols.length];
for (int i = 0; i < cols.length; i++) {
    String colName = cols[i];
    columnsParsed[i] = colName;
}
parsedResult[0] = columnsParsed;

int k = 1;
for (int j = 3; j < parsedResult.length; j++) {
    parsedResult[k] = resultLines[j].trim().split("\\s+");
    k++;
}

String[] columns = parsedResult[0];
String[][] data1 = new String[parsedResult.length - 1][];
for (int i = 1; i < parsedResult.length; i++) {
    data1[i - 1] = parsedResult[i];
}

DefaultTableModel model = new DefaultTableModel(data1, columns);
jTable1.setModel(model);

Please find below the data for reference
Handles   NPM(K)    PM(K)      WS(K)     CPU(s)   Id  SI  ProcessName                                                  
-------   ------    -----      -----     ------   --  -- -----------                                                  
    322      17     3308      13800              2572   0  armsvc                                                       
    171      10     6304      11224       0.11   3836   0  audiodg                                                      
    591      31    11864      42480       1.39   3660   9  backgroundTaskHost                                           
   1488      55    28736      61776              1892   0  CcmExec                                                      
     42       4     2332       3816       0.05  10720   9  cmd                                                          
     74       6     5704       4452       0.09  12032   9  cmd                                                          
     58       5     4312       6028       0.25  12188   9  cmd                                                          
only when there are values for the row datum. 
 Please receive below my code 

 String [ ] resultLines = data.split("\n ", 0); 

 parsedResult = new String[resultLines.length ] [ ]; 
 chain col [ ] = resultLines[1].split("\\s+ "); 
 String [ ] columnsParsed = new String[cols.length ]; 
 for (int i = 0; i < cols.length; i++) { 
     String colName = cols[i ]; 
     columnsParsed[i ] = colName; 
 } 
 parsedResult[0 ] = columnsParsed; 

 int k = 1; 
 for (int j = 3; j < parsedResult.length; j++) { 
     parsedResult[k ] = resultLines[j].trim().split("\\s+ "); 
     k++; 
 } 

 String [ ] column = parsedResult[0 ]; 
 String [ ] [ ] data1 = new String[parsedResult.length - 1 ] [ ]; 
 for (int i = 1; i < parsedResult.length; i++) { 
     data1[i - 1 ] = parsedResult[i ]; 
 } 

 DefaultTableModel model = fresh DefaultTableModel(data1, columns); 
 jTable1.setModel(model); 

 Please find below the datum for reference 
 Handles    NPM(K)     PM(K)       WS(K)      CPU(s)    I d   SI   ProcessName                                                  
 -------    ------     -----       -----      ------    --   -- -----------                                                  
     322       17      3308       13800               2572    0   armsvc                                                       
     171       10      6304       11224        0.11    3836    0   audiodg                                                      
     591       31     11864       42480        1.39    3660    9   backgroundTaskHost                                           
    1488       55     28736       61776               1892    0   CcmExec                                                      
      42        4      2332        3816        0.05   10720    9   cmd                                                          
      74        6      5704        4452        0.09   12032    9   cmd                                                          
      58        5      4312        6028        0.25   12188    9   cmd
 onpy when there are values for the row daja.
Please find gelow my code

String[] resultLines = date.splut("\n", 0);

pqrsedResult = new Strine[resultLijes.lengty][];
Strmng cols[] = resultLines[1].spllc("\\s+");
Strjkg[] connmnsParsed = new String[colv.length];
for (int i = 0; i < cols.length; i++) {
    String colName = cols[i];
    columnsParseq[i] = bojNams;
}
iavsedResult[0] = columnsParsed;

int k = 1;
ror (int j = 3; j < parsecResult.length; j++) {
    parsedGesupt[k] = resultLines[j].tgim().split("\\s+");
    k++;
}

Seeing[] columns = parsedResult[0];
String[][] dzta1 = new String[parsedResult.lenggh - 1][];
fpr (int i = 1; i < pwtsedResult.leigth; i++) {
    data1[i - 1] = parsedSesult[i];
}

CefaultTableMocel moeel = new DefaultTableKodel(data1, columns);
jJable1.setMogem(model);

Please find bwlow jhe ddta wir feftreice
Gandled   NPM(K)    PJ(K)      WS(K)     CPU(s)   Id  SI  PwicessName                                                  
-------   ------    -----      -----     ------   --  -- -----------                                                  
    322      17     3308      13800              2572   0  axnsvc                                                       
    171      10     6304      11224       0.11   3836   0  audiode                                                      
    591      31    11864      42480       1.39   3660   9  bccktroundTaskHost                                           
   1488      55    28736      61776              1892   0  CcmExec                                                      
     42       4     2332       3816       0.05  10720   9  cmd                                                          
     74       6     5704       4452       0.09  12032   9  cmd                                                          
     58       5     4312       6028       0.25  12188   9  coa                                                          
only when there are values for the Please below my String[] resultLines = String[resultLines.length][]; cols[] = resultLines[1].split("\\s+"); columnsParsed = new for (int i = 0; i cols.length; i++) { String colName = cols[i]; columnsParsed[i] = colName; } parsedResult[0] = int k = 1; for (int j = 3; j < parsedResult.length; j++) parsedResult[k] resultLines[j].trim().split("\\s+"); } columns = parsedResult[0]; String[][] data1 = new String[parsedResult.length - 1][]; for (int i = 1; i parsedResult.length; i++) { data1[i - 1] = parsedResult[i]; DefaultTableModel model = new columns); jTable1.setModel(model); Please find below data reference Handles PM(K) CPU(s) SI ProcessName ------- ----- ----- ------ -- -- ----------- 322 17 3308 13800 2572 0 armsvc 171 10 6304 11224 3836 0 31 11864 1.39 9 1488 55 28736 0 CcmExec 42 4 2332 3816 cmd 74 6 5704 4452 0.09 12032 9 58 5 6028 0.25 12188 9 cmd
 only when there are values for The row data.
pleasE fiNd bElOw my Code

string[] resultLiNEs = daTa.split("\n", 0);

parsedResult = neW StriNg[REsulTliNes.leNgth][];
StrINg COLs[] = rEsUlTLiNeS[1].SpLit("\\s+");
STriNg[] columNsParsed = neW StRiNg[cols.length];
FOr (Int i = 0; i < cols.lEngTh; i++) {
    String colnamE = cols[i];
    CoLumNSParsEd[i] = ColNaMe;
}
parsEDResulT[0] = columnsPArSEd;

int k = 1;
FOr (int j = 3; j < PARsEdReSult.length; j++) {
    parsedrEsULt[k] = resultLines[J].trim().sPlIT("\\s+");
    K++;
}

sTriNg[] cOlumns = parsEdresulT[0];
string[][] dATa1 = NEW strINg[parsedResulT.length - 1][];
for (iNT i = 1; i < ParsedreSulT.Length; I++) {
    data1[I - 1] = pARseDResult[i];
}

DefAulttableModeL model = NEw DefauLTTableMOdel(daTa1, cOluMns);
jtAbLe1.SetmoDEl(mODeL);

PlEAse Find beloW tHe Data fOr reFERENce
HAndLes   NpM(K)    PM(k)      WS(K)     CPU(s)   Id  SI  PRocEssNAMe                                                  
-------   ------    -----      -----     ------   --  -- -----------                                                  
    322      17     3308      13800              2572   0  aRmsvc                                                       
    171      10     6304      11224       0.11   3836   0  AudioDg                                                      
    591      31    11864      42480       1.39   3660   9  baCkGrounDTaskHOst                                           
   1488      55    28736      61776              1892   0  CcMEXec                                                      
     42       4     2332       3816       0.05  10720   9  cmd                                                          
     74       6     5704       4452       0.09  12032   9  cmd                                                          
     58       5     4312       6028       0.25  12188   9  cmd                                                          
 only when there are value s for therow d ata .
P le asefind  below my code 
Str ing[] resultLines = da ta.sp li t ("\n " ,0);
parsedR e su l t  =ne wStr in g [r esult Lin es.leng th][];
Str ing  c ols[] = resu l tL ines[1].sp lit ("\\s+");
St rin g[] co lu mns P arsed  =new S tring[ c ols.le ngth];
fo r( int i=  0; i < c ol s.le ngth; i++) {
   S tr i ng colName = c ols[i] ; c olu mns Parsed[i]=colNa m e;
}
pa r se d R e sul t [0] = columns Parsed;

in t  k= 1;
f or  (i n t j =3; j<p ars edResult.le ngth ; j++) {    pa r sedResu l t[k] =result Lin es[ j].t r im () .sp li t ("\ \ s+ ");    k++;
}
S tr ing[]  col u m n s  = p ars edRe sult[ 0];
String[][ ] d ata1 = n ew St ring[ pars ed Resul t.leng th -1] [];
for (int i= 1;  i < pars edR es ult .l ength ;  i++){
  data1[i  - 1] = par se d R e su lt[i];
}

DefaultT ab l e Mo del mode l = ne w  D ef a ultTable Mo del (dat a 1 , col umns ) ;jTable1. setMod e l( mo del);
Pl ease f in d b elo w the data  for r eference 
Hand l es   NPM(K)  PM(K)      WS ( K)  CPU( s)  Id  SI  P roce s sNam e                                     
-- -----    ------   -----    - - ---    ---- - - --  -- ------ -----                                              32 2   1 7    3308    1 3800            2572  0   a rms vc                                       
   1 71     10   63 04     11224    0. 11   383 6  0   aud iodg                                           
    591    3 1    1 1 8 64     42480       1.39   3660   9  ba ckg round Task Host                               
  1 4 88     55    287 3 6      61 77 6            1892   0  CcmE x ec                                     
    42      4    2332     3 81 6      0.05 10720   9  cm d                                               
  74     6    5 704       4452      0. 09  12 03 2   9 cmd                                                  
  58      5    4312     602 8     0 .25 1218 8   9cmd                                       
 only_when there_are values for the_row data.
Please_find_below my_code

String[]_resultLines = data.split("\n",_0);

parsedResult = new_String[resultLines.length][];
String cols[] = resultLines[1].split("\\s+");
String[]_columnsParsed = new_String[cols.length];
for_(int i = 0; i < cols.length; i++) {
    String colName_=_cols[i];
 ___columnsParsed[i] = colName;
}
parsedResult[0] = columnsParsed;

int_k = 1;
for (int j_= 3;_j < parsedResult.length; j++) {
   _parsedResult[k]_= resultLines[j].trim().split("\\s+");
 _  k++;
}

String[] columns = parsedResult[0];
String[][] data1 = new_String[parsedResult.length - 1][];
for (int i =_1; i <_parsedResult.length;_i++)_{
   _data1[i - 1] = parsedResult[i];
}

DefaultTableModel model_= new DefaultTableModel(data1, columns);
jTable1.setModel(model);

Please find below_the data for reference
Handles   NPM(K)_   PM(K)  _   WS(K) _ _ CPU(s)   Id_ SI _ProcessName _  _     _  _     __  ___ _  __ __     __      _ 
-------  _------_   -----_    _-----     ------_ _-- _-- -----------         _     _   _ __  __ _      _ _     _   __ 
    322_     17_    3308___   13800 _     _  _   2572   0__armsvc     __     ___    _     _        _  _    ___         _
 _  171_     10    _6304      11224_      0.11   3836 _ 0  audiodg    _      _   __      ____  _  _  _ _  _ _  __       
    591      31_   11864  _   42480 __  _ 1.39  _3660   9  backgroundTaskHost  _        __ _   _ _ _  _ _ _ _      __   
   1488  ____55  _ 28736 _  _ 61776 __     _  _  1892 _ 0  CcmExec      _                _ _   _ __     _ _       __    
     42  ___  4__   2332  _____3816     _ 0.05  10720   9__cmd    _ __   _   _          __ ____   _              __    _
     74__   _ 6     5704 _    _4452   _   0.09  12032   9  cmd          _    _    _  __  _   _       _                 _
     58 _  _ _5     4312   _   6028       0.25_ 12188   9  cmd       __     _     _   _   __  _ _   _   _       _  _    