Reading from the text file and writing to sql server

Results 1 to 2 of 2

Thread: Reading from the text file and writing to sql server

  1. #1
    Join Date
    Dec 1969
    Posts
    257

    Default Reading from the text file and writing to sql server

    Hi,<BR>I want to know weather I can read the text file that have comma <BR>seprated list, remove those comma and write those values back to<BR>sql server database, USING ASP.<BR><BR><BR><BR>Thanks<BR>Harry

  2. #2
    Nathan Pond Guest

    Default RE: Reading from the text file and writing to sql server

    Yes you can.<BR><BR>Now I suppose you&#039ll want to know how. :-) Well, I&#039ll start you in the right direction. Use ASP&#039s FileSystemObject to open the text file, then parse and seperate the information in the text file however you want it. I would probably say write a function that will use InStr() and fin the commas, then store the data in between the commas in an array.<BR><BR>You then make your database connection to SQL, and insert the data.<BR><BR>That is a rough sketch, not very detailed. But I hope it&#039s enough to get you started.<BR><BR>Nathan Pond

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •