Forum Replies Created

Viewing 15 posts - 256 through 270 (of 337 total)

  • RE: DBCC SQLPERF(logspace)

    Thanks for the reply Gail.

    I understand what you are saying.But I just used the below DBCC command without specifying any size

    dbcc shrinkfile('logfile')

    So how was it that after shrinking the file...

    --------------------------------------------------------------------------------------------------
    I am just an another naive wannabe DBA trying to learn SQL Server

  • RE: Help with seemingly simple query

    Dave Ballantyne (1/13/2011)


    Try this article

    http://www.sqlservercentral.com/articles/T-SQL/71550/

    I tried using quirky update.Any comments on this method ?

    http://www.sqlservercentral.com/Forums/Topic1031000-203-4.aspx

    --------------------------------------------------------------------------------------------------
    I am just an another naive wannabe DBA trying to learn SQL Server

  • RE: Group Islands of Contiguous Dates (SQL Spackle)

    Well I just stumbled upon this article.I tried to do it using quirky update method and seems to be working but haven't tested it on a huge no of rows...

    --------------------------------------------------------------------------------------------------
    I am just an another naive wannabe DBA trying to learn SQL Server

  • RE: Allocate memory to SELECT statement in sql server 2005

    Just remember that Resource Governor is new to SQL Server 2008 and this is a 2005 question.

    Yeah.That's true. How did I miss that ?

    --------------------------------------------------------------------------------------------------
    I am just an another naive wannabe DBA trying to learn SQL Server

  • RE: I need to create a .cmd file to execute the sql files in a order

    You can create a batch file and list down all the sql script files in the batch file which you want to execute in the desired order and execute the...

    --------------------------------------------------------------------------------------------------
    I am just an another naive wannabe DBA trying to learn SQL Server

  • RE: Allocate memory to SELECT statement in sql server 2005

    It can be done for a particular login using resource governer but not for a query or a SP.What you do basically is create resource pool and assign that resource...

    --------------------------------------------------------------------------------------------------
    I am just an another naive wannabe DBA trying to learn SQL Server

  • RE: SQl query help

    My query will work considering the fact that the treatment Id will always be incrementing for each patientid whose treatments are overlapping.

    select * from patient p1

    where exists(select 1 from patient...

    --------------------------------------------------------------------------------------------------
    I am just an another naive wannabe DBA trying to learn SQL Server

  • RE: First time semi-complex query - its slow!!!

    Thanks.

    I am to getting somewhat the same results after testing both the methods.

    I am now gonna STOP using the CTE method in future 🙂

    --------------------------------------------------------------------------------------------------
    I am just an another naive wannabe DBA trying to learn SQL Server

  • RE: First time semi-complex query - its slow!!!

    No I havent.

    Can you post some link where it has been done?

    --------------------------------------------------------------------------------------------------
    I am just an another naive wannabe DBA trying to learn SQL Server

  • RE: First time semi-complex query - its slow!!!

    How about this ?

    ;with cte

    as

    (

    select e_start,e_end from #Source

    union all

    select DATEADD(minute,1,e_start),e_end from cte

    where DATEADD(minute,1,e_start)<=e_end

    )

    select e_start from cte order by e_start

    I think with Denali and introduction of SEQUENCES the above method will...

    --------------------------------------------------------------------------------------------------
    I am just an another naive wannabe DBA trying to learn SQL Server

  • RE: How to convert rows to columns where no. of columns are not known

    This?

    create table vehiclearrivalmonth

    (

    dealerid int,

    amgid int,

    arrivalmonth varchar(3)

    )

    insert into vehiclearrivalmonth

    values (100, 200, 'Jan')

    insert into vehiclearrivalmonth

    values (100, 200, 'Feb')

    insert into vehiclearrivalmonth

    values (100, 201, 'Jan')

    insert into vehiclearrivalmonth

    values (100, 201, 'Mar')

    insert...

    --------------------------------------------------------------------------------------------------
    I am just an another naive wannabe DBA trying to learn SQL Server

  • RE: parameter stored procedure select fileds

    Try this

    create proc [dbo].[MySelect](@filed varchar(max))

    as

    begin

    declare @sql nvarchar(max)

    select @sql = 'select ' + quotename(@filed,'[') + ' from Customers'

    EXECUTE sp_executesql @sql,N'@filed varchar(max)',@filed

    end

    go

    exec [MySelect] N'custid,custname'

    --------------------------------------------------------------------------------------------------
    I am just an another naive wannabe DBA trying to learn SQL Server

  • RE: Assist please: ASP.NET app pool keeps recycling because of CLR

    Have a look here.Seems more like an IIS issue

    http://remy.supertext.ch/2007/11/recycle-worker-process-iis-60/

    --------------------------------------------------------------------------------------------------
    I am just an another naive wannabe DBA trying to learn SQL Server

  • RE: INSERT performance on indexed files

    As a rule of thumb, follow these guidelines:

    Low Write Tables (100-1 read to write ratio): 100% fillfactor

    High Write Tables (where writes exceed reads): 50%-70% fillfactor

    Everything In-Between: 80%-90% fillfactor.

    You may...

    --------------------------------------------------------------------------------------------------
    I am just an another naive wannabe DBA trying to learn SQL Server

  • RE: Change a variable based on the results

    DECLARE @NextMonth AS nvarchar(7)

    SET @NextMonth = LEFT(datename(mm, dateadd(month, 1, GETDATE())), 3) + '-' + RIGHT(datename(yy, getdate()), 2)

    if @nextmonth = 'Jan-10'

    set @NextMonth = LEFT(datename(mm, dateadd(month, 1, GETDATE())), 3) + '-'...

    --------------------------------------------------------------------------------------------------
    I am just an another naive wannabe DBA trying to learn SQL Server

Viewing 15 posts - 256 through 270 (of 337 total)