How do you save data as ...

Results 1 to 2 of 2

Thread: How do you save data as ...

  1. #1
    Tara Guest

    Default How do you save data as ...

    I hope I am asking this correctly, if not please forgive. I am trying to have a field (Multi-line)be saved as a text file in SQL. Thank you in advance.<BR>Tara

  2. #2
    Join Date
    Dec 1969

    Default RE: How do you save data as ...

    If I understand your question correctly, this should work...<BR><BR>Dim fs, ts, rs, sql cnstr<BR>Set rs = Server.CreateObject ("adodb.recordset")<BR>Set fs = Server.CreateObject ("scripting.filesystemobject")<BR>sql = "..."<BR>cnstr = avalidconnectionstring<BR>rs.Open sql, cnstr, 0, 1, 1 &#039forward only read only<BR>Set ts = fs.OpenTextFile (filename, true) &#039overwrite old file<BR>do until rs.eof<BR>ts.write rs ("textfieldname" [or ordinal field number])<BR>loop<BR>&#039destroy the objects

Posting Permissions

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