Forum Replies Created

Viewing 15 posts - 4,426 through 4,440 (of 7,164 total)

  • RE: build sql string into variable

    The desire to use of an object name stored in a variable to build a query, e.g.

    DECLARE @tableName SYSNAME;

    SET @tableName = N'MyTable';

    SELECT Column

    FROM @tableName;

    usually indicates a flawed design. Mind...

    There are no special teachers of virtue, because virtue is taught by the whole community.
    --Plato

  • RE: Is it possible to create a database user automatically after creating a database?

    I just tested it out...you can add the user to model and put it in the db_owner Role and anytime a new DB is created the user will be there....

    There are no special teachers of virtue, because virtue is taught by the whole community.
    --Plato

  • RE: Index spool to physical index for performance

    GilaMonster (4/19/2012)


    opc.three (4/19/2012)


    You can retrieve the actual plan for your session, check out this article for next time:

    Viewing the Execution Plan of a Running Query in SQL Server

    That gets an...

    There are no special teachers of virtue, because virtue is taught by the whole community.
    --Plato

  • RE: Index spool to physical index for performance

    You can retrieve the actual plan for your session, check out this article for next time:

    Viewing the Execution Plan of a Running Query in SQL Server

    There are no special teachers of virtue, because virtue is taught by the whole community.
    --Plato

  • RE: Which way is better for script execution...

    Lynn Pettis (4/19/2012)


    I do have to say I liked Oracle's CREATE OR REPLACE. If the database object (view, stored procedure, function) already existed, it replaced it and if it...

    There are no special teachers of virtue, because virtue is taught by the whole community.
    --Plato

  • RE: Storing statistical (user) data

    Tristan Chiappisi (4/19/2012)


    Another thought to reduce the amount of rows was a key/xml table where the XML would contain a series of statistics metrics per store and I would just...

    There are no special teachers of virtue, because virtue is taught by the whole community.
    --Plato

  • RE: Question about Data Conversion Transformation

    Which SSIS data type are you converting the string to?

    See section "Mapping Integration Services Data Types to Database Data Types" on Integration Services Data Types to ensure you are using...

    There are no special teachers of virtue, because virtue is taught by the whole community.
    --Plato

  • RE: Stored Procedure Nesting Error

    It is true that BEGIN / END adds clarity, but it does not release us from separating our batches with GO, i.e. this still produces an incorrect result:

    use tempdb

    go

    create proc...

    There are no special teachers of virtue, because virtue is taught by the whole community.
    --Plato

  • RE: wql query to check for creation of multiple files in a directory

    I am not sure how you would do this in one WMI query. I would setup two watchers in sequence...when the first watcher finds a file it will pass control...

    There are no special teachers of virtue, because virtue is taught by the whole community.
    --Plato

  • RE: use print statement in stored procedure

    HowardW (4/19/2012)


    opc.three (4/19/2012)


    itskanchanhere (4/19/2012)


    I used Teradata SQL Assistant client to execute some procedures in SQL Server. Since these had Print statements they failed...Sps without print were successfully executed.. I faced...

    There are no special teachers of virtue, because virtue is taught by the whole community.
    --Plato

  • RE: how to transfer specific db users and passwords to another db??

    USE database_name

    DECLARE @sql NVARCHAR(MAX);

    SET @sql = N'';

    SELECT @sql = @sql + 'EXEC master.dbo.sp_help_revlogin @login_name = N''' + sp.name + ''';

    '

    FROM sys.database_principals dp

    ...

    There are no special teachers of virtue, because virtue is taught by the whole community.
    --Plato

  • RE: Recover sa Password

    Get Back into SQL Server After You've Locked Yourself Out

    There are no special teachers of virtue, because virtue is taught by the whole community.
    --Plato

  • RE: use print statement in stored procedure

    itskanchanhere (4/19/2012)


    I used Teradata SQL Assistant client to execute some procedures in SQL Server. Since these had Print statements they failed...Sps without print were successfully executed.. I faced problem only...

    There are no special teachers of virtue, because virtue is taught by the whole community.
    --Plato

  • RE: SQL 2008R2 just keeled over

    Perry Whittle (4/18/2012)


    opc.three (4/18/2012)


    With VAS being such a limiting factor on 32-bit instances large contiguous blocks can become hard to come by after being up for a while and the...

    There are no special teachers of virtue, because virtue is taught by the whole community.
    --Plato

  • RE: Stored Procedure Nesting Error

    This is a shot in the dark because I cannot see what you see, but sometimes when compiling procedures additional code slips into the procedure definition if your batches are...

    There are no special teachers of virtue, because virtue is taught by the whole community.
    --Plato

Viewing 15 posts - 4,426 through 4,440 (of 7,164 total)