• Lynn Pettis (4/17/2013)


    mike.hamilton721 (4/17/2013)


    Thank you Lynn. I tried that new EXEC you listed (missing a ' ?), and I thought I added it in the right spot. But I'm not sure what you mean about populating? I did

    @dbid = 5

    above the BEGIN string. Is that not how I should do this?

    The exec line now looks as follows:

    EXEC ('DBCC fileheader(''+cast(@dbid as varchar)'+')')

    This is over my head to be honest 🙂 Thank you for the helP!!

    Sorry, missed it in all the unformatted code.

    Hmm. Still getting incorrect syntax... Do I need to change anything besides the exec? Its saying cast syntax