Hi Monks, I would like your assistance to write a program that searches for files in a directory and grabs file's name to store it on a variable, then connect to SQL Server 2000 Database and select records out of a table base on the values store in an array variable; then format the records with a padded zeros to meet standards. Finally it will write the output to a file. I'm not familiar using Perl to Connect to SQL Server 2000 or formatting a variable to pad it with zeros to meet a certain length. Does anyone know any samples on how to a connect to a SQL Server database and format variables. Could this program best accomplish by writing a store procedure then connecting to sql server 2000 to run the store procedure and grab the output fields to a file?? I haven't seen that much DBI programming. I'll appreciate your assistance on how to accomplish this task.

In reply to Accessing SQL Server 2000 by skyler

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.