Forum Replies Created

Viewing 15 posts - 406 through 420 (of 487 total)

  • RE: Wise Job Scheduling

    Questions / comments

    1) How big is your DB? We are running 40DBs or so on an RAID 5 server, total about 15GB (not big). The server has *never* been defragmented....

  • RE: Calling procedure / trigger

    Robert,

    Another good day, I learned something new (and useful).

    Thanks!!

    P

  • RE: Interesting IF...ELSE.. Behaviour

    Multiple statements in IF / ELSE need to be wrapped in BEGIN...END

  • RE: Code Parser Control

    How many users? How educated, as in knowledge of SQL and DBs, are your users? How big is the DB? (Think about it: forget one join clause, and the query...

  • RE: unique column in 2 tables - interesting problem

    Couldn't you then run into the problem of 2 trans beginning at the same time, each getting the same new id number?

  • RE: unique column in 2 tables - interesting problem

    I just want to know how the app knows which of the two tables to insert.

  • RE: unique column in 2 tables - interesting problem

    How about 1 parent table A with identity, 2 child tables with foreign key and check constraints: table B, all the ids must be divisible by 2 with...

  • RE: Order a varchar field

    Here's the correct version (single column in select, ordering not by ordinal position - is that still to be deprecated?)

    SELECTcVal

    FROM #tmp_holding

    ORDER BY CONVERT(INTEGER, STUFF(cVal, 1, PATINDEX('%[0-9]%', cVal) -1, '')), cVal

    P

  • RE: Order a varchar field

    Try this:

    SELECTcVal, CONVERT(INTEGER, STUFF(cVal, 1, PATINDEX('%[0-9]%', cVal) -1, ''))

    FROM #tmp_holding

    ORDER BY 2, 1

    HTH,

    P

  • RE: Need script to UPDATE 1000 Rows then COMMIT, Iteratively

    Jeff,

    VERY COOL!!!!

    Never seen that UPDATE...SET construct before.

    Not so fast here, tho, took 1m11s.

    Thanks,

    Paul

  • RE: Convert to For/Next

    You say this is called from an update trigger, and then give an example involving one 1000 row insert (or 1000 single row inserts). Either way, unless the trigger is...

  • RE: Same changes on many databases

    Save all your changes in a script file, then cursor through your DBs calling OSQL using xp_cmdshell.

  • RE: Alter Table

    Michael,

    You're too funny!!! You say we're not here to preach, yet you're preaching at me!!!!

    I just read your solution to the original question: update syscolumns????? IMHO, that's preaching suicide....

  • RE: Alter Table

    Michael,

    In that case, it's not the ordinal position that breaks things, it's the poor code.

  • RE: Alter Table

    The ordinal position cannot matter. If you want to see columns in a specific order, select them in that order.

Viewing 15 posts - 406 through 420 (of 487 total)