Forum Replies Created

Viewing 15 posts - 10,171 through 10,185 (of 13,469 total)

  • RE: Performance issue on a udf - Better way to rewrite?

    J-F if possilbe, can you get rid of the function and just add a persisted calculated column instead? persisted stores the value in the data pages, and would be much...

  • RE: String manipulation with a move

    timscronin (1/6/2010)


    I have this idea which works row by row, but I need it to be inline sql

    DECLARE @drugName VARCHAR(20), @amp_position INT

    SELECT @drugName = '100MGWaldorf'

    SET @amp_position = CHARINDEX( 'MG', @drugName)...

  • RE: Intermittent SQLException "Could not find stored procedure"

    I believe i've seen this condition when a users credentials has a default database other than the one being connected to.

    What I mean is if i created a new user...

  • RE: User Defined Database Role

    Jack Corbett (1/5/2010)


    I'd create a role and give it those rights on each schema in the database. It's not quite db_owner so I'd avoid that.

    Based on what Jack said,...

  • RE: Require a batch file to zip files and move to Different loacation

    while you can do it from within SQL server with some TSQL commands, guess what....all the work goes out to xp_cmdshell to call programs like 7zip/winzip/pkzip, and then the MOVE...

  • RE: How to encrypt database objects

    nope;obfuscating table definition itself is not possible. I'm sure you feel proud of your design, and feel someone could possibly reverse engineer some of your business practices simply by looking...

  • RE: Killing sleeping processes

    why not have the app itself test for inactivity, and log people out after say, 20 minutes? then you could have a pop-up screen that said they were logged out....

  • RE: Problem using EXEC within SELECT CASE statement

    just so you know what the issue is:

    in TSQL, a CASE statement is used to decide which data to return; it can only return one of the SQL datatypes. you...

  • RE: Can TSQL 2005 do this : ToBase64string

    also use the search feature here on SSC for "Base64"; there are a number of forum posts and submitted scripts to encode/decode;

    here's the first of many i found:

    BASE64 Encode and...

  • RE: Field length mismatch

    char 160 in a lot of fonts looks like a space; if you use it in an html document, multiple char(160)'s in a row get respected as valid chars to...

  • RE: XP_CMDSHELL Question

    i think filenames/paths with spaces need to be wrapped in double quotes, right?

    also, are you not CALLING the datapump? why is the DIR command in there?

    exec master.dbo.xp_cmdshell '"C:\Program Files\Monarch Data...

  • RE: Change Default Script Location

    i couldn't find a way to change it in the GUI, but when i looked in the registry, I found the spot to change it:

    the key HKEY_CURRENT_USER\Software\Microsoft\Microsoft SQL Server\100\Tools\Shell has...

  • RE: Order a group by value

    Rider i added a CASE in order by with two columns, and it seems to do exactly what you were after; am i missing anything?:

    here's my results:

    PART TYPE ...

  • RE: Normalize data using Pivot WITHOUT using Aggregate function

    ouch that changes things a bit;

    can you please do a SELECT DISTINCT ColumnName From yourtable, so we can have the list of columnnames to normalize this data into? so...

  • RE: Normalize data using Pivot WITHOUT using Aggregate function

    Justin James (12/29/2009)


    Thank you for the help Lowell. I'll make sure to include the appropriate SQL in my further posts.

    One question I have about your SQL:

    select ID/6 as REC, [ID]%...

Viewing 15 posts - 10,171 through 10,185 (of 13,469 total)