Forum Replies Created

Viewing 15 posts - 6,181 through 6,195 (of 13,469 total)

  • RE: Why is this SELECT statement so slow.

    yep pseudocode will not help with pinpointing a specific performance issue; you 've got to show the real SQL statement, and preferably, the actual execution plan.

    examples of why the SQL...

  • RE: Index created date

    AFAIK, regular indexes cannot be determined by create_date or modified date; if the data exists, it is not exposed.

    you can infer the index creeation for Primary Key and unique constraints,...

  • RE: HTML using XML PATH

    the problem is the embedded html.

    SELECT td='<a href=''http://ABC:7777/XYZ/TYPE/EditForm.aspx?ID=0&UID='''+CAST(ACTIVITY_UID AS VARCHAR(36))+'''''>'+ACTIVITY_NAME+'</a>','',

    the FOR XML is going to htmlencode all that, turning them into amp lt ; a and stuff.

  • RE: Auditing my all SPs/Views/Functions in Today's Date

    waseem.shahzad 45937 (12/21/2011)


    Can you put a Date check on this?

    of course, but what do you want to check?> just add a WHERe statement that validates teh create_date column to whateever...

  • RE: Auditing my all SPs/Views/Functions in Today's Date

    sys.objects has got all that info for you;

    something like this is pretty close, i bet:

    SELECT

    schema_name(schema_id) As SchemaName,

    name as ObjectName,

    create_date

    FROM sys.objects

    WHERE type_desc IN(

    'AGGREGATE_FUNCTION',

    'SQL_SCALAR_FUNCTION',

    'SQL_INLINE_TABLE_VALUED_FUNCTION',

    'SQL_TABLE_VALUED_FUNCTION',

    'SQL_STORED_PROCEDURE','VIEW')

    ORDER BY create_date DESC

  • RE: Seeing the foreignkeys through the trees..

    Thanks Ian;

    your pointers and a fresh look at it thismorning got me where i wanted to go.

    for reference, this modified verison seems to do exactly what I was trying...

  • RE: Am I Blind? - Duplicate key row

    in the VALUEs statement you provided, rows one and three are identical for the columns [kp_slownik_kod] and [kod_id], which seems to matcht he...

  • RE: not exist statement help!!

    usually, you use exists to detect a reference/relationship/join between the two:

    this is more like what i'd expect to see:

    SELECT

    *

    FROM Report

    WHERE NOT EXISTS (SELECT

    ...

  • RE: SELECT TOP 50 Percent not returning 50 Percent

    i can confirm that SQL2005 express is returning 8 rows, where my 2008 returns 7.

    the only difference i see is in the execution plan; the layouts of the plans are...

  • RE: how to know which operation fired the DML trigger

    oops misread it a little bit...

    if you want to know if it was an INSERT, UPDATE or DELETE, you simply check the INSERTED or DELETED tables.

    if rows exist in both...

  • RE: Problem with left join.

    i'm guessing nwdetcot is a list of all possible prices, possibly for all products thru the begfinning of time..i'm betting you need to limit it to just the CURRENT...

  • RE: Find best key columns for Clustered Index

    SQLJocky (12/19/2011)


    Thanks. I understand the concepts when you know the data but what if you don't know the data? Is there a quick script that will show each...

  • RE: How-2-pass getdate() to oracle

    oracle has a suite of TO_* functions. TO_DATE and TO_CHAR for example, but i'm thinking this is going to be done on SQl, since you are really pulling the table...

  • RE: How-2-pass getdate() to oracle

    SYSDATE is the equivilent in oracle;

    SELECT SYSDATE FROM DUAL; for example.

  • RE: Trigger fires twice

    also, make sure you don't have two triggers on the same table, both with the same basic code, but two different names.

    that might explain two rows inserted when you expect...

Viewing 15 posts - 6,181 through 6,195 (of 13,469 total)