65.9K
CodeProject is changing. Read more.
Home

Use XSLT to convert ADO Recordsets into delimited files

starIconstarIconstarIconstarIconstarIcon

5.00/5 (2 votes)

Oct 24, 2001

viewsIcon

62906

downloadIcon

1637

Transform any XML persisted ADO Recordset into a delimited text file.

Introduction

The rs2txt.xsl is an Extensible Style Sheet that will convert any ADO RecordSet, persisted in XML format, to a delimited, string-qualified file. You will need ADO 2.1 or later in order to persist ADO RecordSets as XML. Please see the VB6 demo for an example of how to use this stylesheet.

Environment Used

  • MDAC 2.6
  • Microsoft XML, version 4
  • VB 6

Usage Notes

You can easily change the desired delimiter and string-qualifier by modifying the value of the delimiter and qualifier variables at the top-level of the stylesheet. If you wish to have no qualifier, just set the value of the qualifier variable to an empty xsl:text element.

The string-qualifier is currently only used on fields with a data type of string. All other types will not use a qualifier.

References

  • For more information about the ADO XML Persistence format, consult this web page.
  • For the latest MDAC, visit here.