Forum Replies Created

Viewing 15 posts - 196 through 210 (of 210 total)

  • RE: Deletion of TIF files using DTS Package & SP's

    Glad to help. As with all things, practice makes perfect.

  • RE: Deletion of TIF files using DTS Package & SP's

    This code snippet might work for you.

    create table #tbl (imagefile varchar(50), location varchar(50))

    declare @filename varchar(50)

    , @sql varchar(255)

    insert into #tbl (imagefile, location) values ('C:\Images\0\1.tif', 'backup')

    insert into #tbl (imagefile, location) values ('C:\Images\0\2.tif',...

  • RE: Regarding Two Database

    You could also create views in the current db that union tables across dbs (assuming they have the same structure).

    create view1

    as

    select * from db1.dbo.tblname

    union

    select * from db2.dbo.tblname

  • RE: DBCC DBREINDEX / DBCC SHRINKFILE

    This might be causing your problem

    FROM BOL (DBCC SHRINKFILE):

    If target_size is specified, DBCC SHRINKFILE attempts to shrink the file to the specified size. Used pages in the part of the...

  • RE: Join tables from two different database

    Use the fully qualified name in your FROM clause: [dbname].[owner].[tblname]

  • RE: Unused Tables identification

    I've unfortunately had to do this a number of times against a legacy db I inherited.

    I usually start off by checking for occurrences in the syscomments table and then wade...

  • RE: How to run.bat file via SSIS package

    I would just schedule a job executing xp_cmdshell.

  • RE: Reindex question

    Orlith (8/26/2008)


    Hi

    I found a solution ,perhaps not the perfect one 🙂 but it works now.

    Functional always trumps elegance!

  • RE: Reindex question

    Try replacing

    SELECT TABLE_NAME FROM INFORMATION_SCHEMA.TABLES

    with this

    SELECT TABLE_SCHEMA + '.' + TABLE_NAME FROM INFORMATION_SCHEMA.TABLES

  • RE: Cannot expand many dabase with SQL Enterprise Manager

    Server role dbcreator grants a user the ability to create, alter, and drop databases. This would give them access to modify any database on the server.

    Database roles db_owner and db_ddladmin...

  • RE: DEFRAG All Tables in a DB

    Sergiy (8/25/2008)


    Reindexing of clustered index changes order of pages for all other indexes on the same table.

    So, clustered indexes must be processed first. I don't see where your script takes...

  • RE: DEFRAG All Tables in a DB

    If you're interested, here's a script we run over the weekend (downtime) to identify and defrag indexes. It uses extent switching and logical scan fragmentation as the defrag indicators.

    Comments are...

  • RE: What is the Process of tracing only Insert and Update command using SQL Profiler

    You could add a LIKE filter on the TextData column for %insert% and %update%.

  • RE: DTS fails when it is scheduled

    The job runs under the account that started the SQL Server Agent service. Make sure that that account has adequate rights to run the DTS and has access to the...

  • RE: select query

    Working from your example, something like this might work:

    declare @col1 int, @col2 int, @col3 int

    declare @tbl table (col1 int, col2 int, col3 int)

    insert into @tbl values (1, 0, 0)

    insert into...

Viewing 15 posts - 196 through 210 (of 210 total)