Forum Replies Created

Viewing 15 posts - 181 through 195 (of 230 total)

  • RE: Conversion from varchar to strong data types

    Yeah, try_convert sure took it's time getting here. We don't have 2012+ on any production boxes either so it's not an option.

    One trick to improve isnumeric() functionality is prefix '0e'...

    Executive Junior Cowboy Developer, Esq.[/url]

  • RE: show changes from and changes to in a history table

    Just curious, why are you unable to create an additional support table? I'm unable to think of a way you could have full DML history on demand without having some...

    Executive Junior Cowboy Developer, Esq.[/url]

  • RE: Query help- Need to create dummy rows

    Try something like this. Create a framework table of all the potential values you want (the ones which dont define the "Amount" columns) and then left join it to your...

    Executive Junior Cowboy Developer, Esq.[/url]

  • RE: Query issues?

    Those questions are largely subjective and dependent upon what the query is designed to do, what the size of the data is and how quickly this thing is supposed to...

    Executive Junior Cowboy Developer, Esq.[/url]

  • RE: Query help

    While as a rule, I'm somewhat loathe to the idea of using correlated subqueries, I believe this should do what you're asking. This keeps the left join and ensures there...

    Executive Junior Cowboy Developer, Esq.[/url]

  • RE: CSV CRLF Issue

    This may not be 100% the answer, but different parsers by default may use different line terminators (CR or LF). Generally when both are used it means whichever the parser...

    Executive Junior Cowboy Developer, Esq.[/url]

  • RE: Update records separated by group

    Assuming by "group" you're referring to the AuditTeamID, I think this gets you what you need.

    ;with qry as

    (

    Select 5 AS InternalAuditTeamEmployeeID, 1 as InternalAuditTeamID

    UNION ALL

    Select 11, 2

    UNION ALL

    Select 14,...

    Executive Junior Cowboy Developer, Esq.[/url]

  • RE: seven digit random number

    I'd be interested in hearing what the use case is for this as there's probably a much more tailored answer to your question.

    There are exactly 8,999,999 distinct integers between 1,000,000...

    Executive Junior Cowboy Developer, Esq.[/url]

  • RE: XML Schema validation in SQL Server

    Be careful of the hanging transaction state if the try catch assignment fails. If you're using explicit transactions or nested proc calls, you can end up in a situation where...

    Executive Junior Cowboy Developer, Esq.[/url]

  • RE: Foreign Keys: Essential or Academic?

    Thank you all for the quick and thorough responses. The assertion that they weren't essential literally kept me awake last night. I think I'll rest easier knowing that I'm doing...

    Executive Junior Cowboy Developer, Esq.[/url]

  • RE: Execute large number of insert statements

    FWIW, a few thousand rows shouldn't cause much blocking any way you do it.

    If the file is really just a bunch of insert statements that you're trying to run, I...

    Executive Junior Cowboy Developer, Esq.[/url]

  • RE: Best way to determine tables which contain a list of specific columns

    Nevermind, I think this was one of those things that after I posted it, I sort of answered my own question. Thanks for the quick replies anyway.

    Executive Junior Cowboy Developer, Esq.[/url]

  • RE: Best way to determine tables which contain a list of specific columns

    Oh I think I see what you mean, the join isn't really necessary here, it could just be

    select object_name([object_id])

    from sys.columns

    where name in ('InstrumentID', 'AssetClass', 'InstrumentType')

    group by [object_id]

    having count(1) =...

    Executive Junior Cowboy Developer, Esq.[/url]

  • RE: Best way to determine tables which contain a list of specific columns

    I don't need to just visibly see it. sys.columns and information_schema.columns would effectively do the same thing here. What I need is a programmatic way of determining the tables which...

    Executive Junior Cowboy Developer, Esq.[/url]

  • RE: V2008 R2 - Change Tracking

    I'd direct you to http://technet.microsoft.com/en-us/library/bb933875%28v=sql.105%29.aspx.

    My understanding of Change Tracking (and Change Data Capture) is that the logging portion is handled by a set of procedures and agent jobs which are...

    Executive Junior Cowboy Developer, Esq.[/url]

Viewing 15 posts - 181 through 195 (of 230 total)