Forum Replies Created

Viewing 15 posts - 1 through 15 (of 32 total)

  • RE: Report Subscription - Send email after saving to windows share

    Thanks but that may not be possible. Is there any other workaround?

  • RE: Report from Audit table

    Thanks for the info. Will keep in mind if the data grows out of hand.

  • RE: Report from Audit table

    What i was looking like is the complete history.

    for e.g. this gives me 2 rows, one from 4/1-4/30 and other from 4/1-4/15

    declare @dtmPointInTime datetime = '04/10/2013';

    select ms_id, startdate, enddate,...

  • RE: Report from Audit table

    Can you please describe in more detail about the daily snapshot approach?

  • RE: sql query questio

    Thanks that worked. I need to understand how it works though. will check out the article.

  • RE: LTRIM,RTRIM

    Its not that simple.

    The third party provides data, another team loads the data and we use the data to display on front end.

    The team that loads the data will...

  • RE: LTRIM,RTRIM

    You are correct, the data should be clean. But sometimes we have no control on the data and it is provided by third party. All we can do is some...

  • RE: LTRIM,RTRIM

    Sorry, I was not clear. I want include values from table column that has leading/trailing spaces also.

    For e.g.

    table1

    Col

    ----------

    ' ABC'

    'XYZ '

    ' MNR'

    ' MCR'

    table2

    Col

    -------

    'XYZ'

    'MNR'

    Select * from...

  • RE: LTRIM,RTRIM

    So both the queries will return same results? I want to include leading and trailing spaces from table2.

    If I understanding correctly, LTRIM/RTRIM does not make any difference.

  • RE: LTRIM,RTRIM

    If I have a query like

    Select * from table1 WHERE ColVal IN (Select AllVals from table2)

    Is it not better to have the following instead? It will bring in those values...

  • RE: LTRIM,RTRIM

    Then what is the need of LTRIM and RTRIM functions in SQL

  • RE: Search table field with LIKE clause

    using this query instead of using the view directly improved the performance times

    SELECT

    distinct ID,(Display+'--'+ID) as Display

    FROM MyView WHERE ...

  • RE: Search table field with LIKE clause

    CREATE TABLE [case1](

    [CaseID] [varchar](15) NULL,

    [Emp_ID] [varchar](15) NULL,

    [Segment] [varchar](10) NULL,

    [dischargedt] [date] NULL,

    [discharge_entered_dt] [date] NULL

    ) ON [PRIMARY]

    GO

    /****** Object: Index [IX_PK] Script Date: 03/28/2013 13:58:55 ******/

    CREATE UNIQUE CLUSTERED INDEX...

  • RE: Search table field with LIKE clause

    Here you go

    CREATE TABLE [case1](

    [CaseID] [varchar](15) NULL,

    [Emp_ID] [varchar](15) NULL,

    [Segment] [varchar](10) NULL,

    [dischargedt] [date] NULL,

    [discharge_entered_dt] [date] NULL

    ) ON [PRIMARY]

    GO

    /****** Object: Index [IX_PK] Script Date: 03/28/2013 13:58:55 ******/

    CREATE UNIQUE...

  • RE: Search table field with LIKE clause

    Full Index search will need an index on the view.

    And Indexed view will not be a good idea here since the data in case1 table is frequently updated.

Viewing 15 posts - 1 through 15 (of 32 total)