User Profile

Collapse

Profile Sidebar

Collapse
asenthil
asenthil
Last Activity: Apr 11 '07, 06:17 AM
Joined: Dec 20 '06
Location: tamilnadu, india
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • asenthil
    replied to LOAD DATA INFILE problem....
    in Java
    yeaaaaahhhhhhhh hhhhhh........

    Hai r035198x....

    i found the solution for that....

    just we have add a LOCAL keyword in the query like this

    stmt.executeUpd ate("LOAD DATA LOCAL INFILE \"" + filename + "\" INTO TABLE " + tablename + " FIELDS TERMINATED BY ','");

    Now itz perfectly working...

    Thanks for replying...
    se...
    See more | Go to post

    Leave a comment:


  • asenthil
    replied to LOAD DATA INFILE problem....
    Now also the same result....

    i will explain u clearly..

    When i want a export data from a database into a text file..

    i used the query, SELECT * INTO OUTFILE 'C:/test.txt' FROM TABLE....

    there is no test.txt file in C:/..i cant see it...

    But when i run the program again, it throwing an exception that
    C:/test.txt already exists....

    thats what, i came...
    See more | Go to post

    Leave a comment:


  • asenthil
    replied to LOAD DATA INFILE problem....
    in Java
    Now also the same result....

    i will explain u clearly..

    When i want a export data from a database into a text file..

    i used the query, SELECT * INTO OUTFILE 'C:/test.txt' FROM TABLE....

    there is no test.txt file in C:/..i cant see it...

    But when i run the program again, it throwing an exception that
    C:/test.txt already exists....

    thats what, i came...
    See more | Go to post

    Leave a comment:


  • asenthil
    replied to LOAD DATA INFILE problem....
    Ya it is creating a file..... But it is not storing in c:/

    i dont know where it is storing......

    the file is storing in some other location...

    the file is in invisible mode.......
    See more | Go to post

    Leave a comment:


  • asenthil
    replied to LOAD DATA INFILE problem....
    in Java
    Ya it is creating a file..... But it is not storing in c:/

    i dont know where it is storing......

    the file is storing in some other location...

    the file is in invisible mode.......
    See more | Go to post

    Leave a comment:


  • asenthil
    replied to LOAD DATA INFILE problem....
    Hey another one things...

    But when i tried the filename = "C:/test.txt"

    itz import the data from the database and load it to the text file perfectly..

    but whatz special in this is.... there is no test.txt file in the C:/

    Actually test.txt file is a created file by using Query

    SELECT * INTO OUTFILE in the java program for export data to a file(C:/test.txt)..
    ...
    See more | Go to post

    Leave a comment:


  • asenthil
    replied to LOAD DATA INFILE problem....
    in Java
    Hey another one things...

    But when i tried the filename = "C:/test.txt"

    itz import the data from the database and load it to the text file perfectly..

    but whatz special in this is.... there is no test.txt file in the C:/

    Actually test.txt file is a created file by using Query

    SELECT * INTO OUTFILE in the java program for export data to a file(C:/test.txt)..
    ...
    See more | Go to post

    Leave a comment:


  • asenthil
    started a topic LOAD DATA INFILE problem....

    LOAD DATA INFILE problem....

    Hi guys,

    I have got a question regarding LOAD DATA INFILE. Can some one save my day.

    1. I want to import a txt file into mysql database.
    when I use the following query in the mysql> prompt its fine.
    which is

    when I do it java I am getting error

    Error
    -----------
    java.sql.sqlExc eption: General error message from server:
    "File 'D:/Sen.txt' not found...
    See more | Go to post

  • asenthil
    started a topic LOAD DATA INFILE problem....
    in Java

    LOAD DATA INFILE problem....

    Hi guys,

    I have got a question regarding LOAD DATA INFILE. Can some one save my day.

    1. I want to import a txt file into mysql database.
    when I use the following query in the mysql> prompt its fine.
    which is

    when I do it java I am getting error

    Error
    -----------
    java.sql.sqlExc eption: General error message from server:
    "File 'D:/Sen.txt' not found...
    See more | Go to post

  • ya okay,

    now itz cleared...

    thanks for ur support and responses...

    senthil.
    See more | Go to post

    Leave a comment:


  • Ya i'm also want the reason for hirak's question...

    plzz explain us.. r035198x....

    thanks.
    senthil.
    See more | Go to post

    Leave a comment:


  • Hai r035198x...

    Very very thanks for ur reply...

    Now itz working perfectly...

    i'm a beginner to java, jsp...

    Now i'm learning hardly to work in java...

    can u plzz tell me...

    what are the main concepts i have to study in java

    to do projects in jsp...

    thanks
    senthil.
    See more | Go to post

    Leave a comment:


  • Hai ro35...

    thanks for ur reply...

    now its writing the data to the file...

    But itz not writing the Employee_Number to the file...

    the output is like the follwing in the text file..

    ? Axel Washington
    ? Arvid Sharma
    ? Jonas Ginsberg
    ? Florence Wojokowski
    ? Sean Washington
    ?Elizabeth Yamaguchi

    its sucessfully writing the two strings...
    See more | Go to post

    Leave a comment:


  • How to retrive all the rows in a mysql database and write it to a file using java?

    Hai to all,,

    i had to tried to retrive and write a single row to a file from the database..

    But dont know to write all the retrived rows to a file from the database..

    how to do that...

    here are my codings for writing a single row to a file...

    Code:
    import java.io.*;
    import java.sql.*;
    
    public class DataBase {
    
      public static void main(String args[])
    ...
    See more | Go to post

  • asenthil
    started a topic Exception: Can not issue SELECT via executeUpdate!
    in Java

    Exception: Can not issue SELECT via executeUpdate!

    Hai to all,

    Now i'm trying to export Mysql table to a file By using the

    following program...

    itz sucessfully compiled... but it throws the above Exception..

    [HTML]
    Code:
    import java.io.*;
    import java.sql.*;
    public class ExportData {
    public static void main(String args[]) {
            String Driver;
            Statement stmt; 
             ResultSet rs;
    ...
    See more | Go to post

  • How to export table data from a mysql database into text file using java?

    Hai,

    i'm a beginner to java...

    just now i had tried to read and write files using java...

    and then i had tried to connect a database using jdbc...

    now i want to export the data's from a database into a text file

    using java....

    Can any one plzz give me an idea for doing this process...

    thanks and regards..
    senthil.
    See more | Go to post

  • asenthil
    started a topic How to read and write files using java?
    in Java

    How to read and write files using java?

    i'm trying to read and write files using java...

    some errors occurs when i'm trying this code..

    Error in java: Cannot find symbol
    location: class java.io.FileOut putStream
    FileOutputStrea m fout = new FileOutputStrea m(outputFile);
    ^
    Code:
    import java.io.*;
    
      public class Copy {
          public static void main(String[] args) throws IOException
    ...
    See more | Go to post

  • asenthil
    started a topic Beginner to java - HELP!
    in Java

    Beginner to java - HELP!

    Hai to all,

    i had just now started studying java...

    Can anyone plzz tell me..

    is there any free e-books available for studying, java programming basics..

    Plzz tell me which websites will be used for studying java programming.

    senthil
    See more | Go to post

  • asenthil
    replied to How to use SaveToFile() in C++?
    in C
    Hai snow...

    As u said i had tried the following method...

    Code:
    HANDLE hFile,hFile1;
    DWORD wmWritten; 
    HFILE op,op1;
    OFSTRUCT ofs;
    
    memset(&ofs, 0, sizeof(OFSTRUCT));
    op=OpenFile("C:\\tab.doc",&ofs,OF_READ);            
    hFile = CreateFile(_T("C:\\text.doc"),GENERIC_READ|GENERIC_WRITE,        FILE_SHARE_READ,NULL,OPEN_ALWAYS,FILE_ATTRIBUTE_NORMAL,NULL);
    ...
    See more | Go to post

    Leave a comment:


  • asenthil
    replied to How to open a file using openfile() method...
    in C
    Hai,
    thanks for ur reply...

    ya i saw it...

    But i cant undestand the explanation for the 2nd parameter...


    will u plzz help me...

    thanks..
    senthil
    See more | Go to post

    Leave a comment:

No activity results to display
Show More
Working...