}
0 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   vinoth_sundaram
Posted On:   Thursday, September 30, 2010 06:40 AM

import java.io.BufferedReader; import java.io.File; import java.io.FileReader; import java.io.IOException; public class filecomp{ public static void main(String args[]){ BufferedReader br1 = null; File getFile1 = new File("E:/vinoth/test.csv"); try { if (getFile1.exists() && getFile1.isFile()) { FileReader readerFile1 = new FileReader(getFile1); br1 = new BufferedReader(readerFile1); String file1line; int f1line=0; while(((file1line = br1.readLine()) != null)) { f1line=f1line+1; System.out.println("file1..."+f1line); String rowlinebyline=file1line; String column[];    More>>
			import java.io.BufferedReader;
			
import java.io.File;
import java.io.FileReader;
import java.io.IOException;

public class filecomp{
public static void main(String args[]){
BufferedReader br1 = null;
File getFile1 = new File("E:/vinoth/test.csv");
try {
if (getFile1.exists() && getFile1.isFile())
{
FileReader readerFile1 = new FileReader(getFile1);
br1 = new BufferedReader(readerFile1);
String file1line;
int f1line=0;
while(((file1line = br1.readLine()) != null))
{
f1line=f1line+1;

System.out.println("file1..."+f1line);

String rowlinebyline=file1line;
String column[];
String file1str[]=file1line.toString().split(";");
for(int i =0; i <=file1str.length ; i++){
System.out.println(file1str[i]);
for(int j=0;j <=rowlinebyline.length();j++){
column=rowlinebyline.split(",");
System.out.println("Columnwisedate"+column[j]);
}
}
}
}
}
catch (IOException e)
{
System.out.println("Problem:"+e);
}

}
}
   <<Less
About | Sitemap | Contact