Results 1 to 2 of 2
  1. #1
    Join Date
    Sep 2004
    Posts
    3

    Question Unanswered: How to display column descriptions?

    Hello!

    I am wracking my brain, trying to figure out how to return & display a column's description.

    I work in Cold Fusion with SQL 2000 database.

    My table name is "clients" and the column in question is "client_firstname"

    The description of this column, as entered in Ent. Mgr, is "First Name"

    If anyone can please help me, it would be very greatly appreciated!

    Thanks!

    Now for the details...

    I am trying this:

    ----------------------------------------------------------------
    <cfquery name="get_ext2" datasource="#application.dsn#">
    SELECT
    objname As 'Column'
    , value As 'Description'
    FROM
    ::fn_listextendedproperty
    ('MS_Description', 'user', 'dbo', 'table','client', 'client_firstname', default)
    </cfquery>

    <cfoutput>
    "#get_ext2.Column#"
    "#get_ext2.Description#"
    </cfoutput>
    ----------------------------------------------------------------

    ... and it is returning this:

    "" ""

    In my debug output, the query result appears as such:

    ----------------------------------------------------------------
    get_ext2 (Records=0, Time=16ms)
    SQL =
    SELECT
    objname As 'Column'
    , value As 'Description'
    FROM
    ::fn_listextendedproperty
    ('MS_Description', 'user', 'dbo', 'table','client', 'client_firstname', default)
    ----------------------------------------------------------------

    Haaalp!

    Thanks....

    Richard

  2. #2
    Join Date
    Feb 2004
    Location
    In front of the computer
    Posts
    15,579
    Provided Answers: 54
    I'd use fn_listextendedproperty.

    -PatP

Posting Permissions

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