Forum Replies Created

Viewing 15 posts - 9,211 through 9,225 (of 13,461 total)

  • RE: Query idea!

    Renis yes it is certainly possible;

    check out this example; it is getting the names of all the tables and putting it into five columns.

    in your case, you just need to...

  • RE: Email from DDL trigger

    smitty your syntax was close; i tested this with my profile, and it works fine:

    ALTER TRIGGER [ddl_trig_database]

    ON ALL SERVER

    FOR CREATE_DATABASE

    AS

    declare @results varchar(max)

    SELECT EVENTDATA().value('(/EVENT_INSTANCE/TSQLCommand/CommandText)[1]','nvarchar(max)')

    EXEC msdb.dbo.sp_send_dbmail

    @profile_name = 'Default Notifications',

    @recipients = 'lowell@mydomain.com',

    @body =...

  • RE: How to Merge 3 database to 1 database

    there's not a simple script that does it; everything depends on the specifics of the data in question...foreign keys, primary key definitions, and more. you'll need to analyze the data...

  • RE: Two Server have different times on processing ETL.

    well, the existing load on the production server would certainly affect the speed, as it has to share/complete for resources with regular users;

    the devleopment server probably has a near-no load...

  • RE: Easy SQL

    the trick is to join the table against itself, so you can exclude one group:

    something like this:

    SELECT *

    FROM SOMETABLE t1

    WHERE t1.contact_type = 'Requestor'

    AND t1.user_id NOT IN

    (SELECT user_id ...

  • RE: How to use sqlcmd to run my create database/tables/sp's script

    the are .NET references, and have nothing to do with having SQL installed or not.

    you should be able to go to the project references and add them.

    ==edit whoops my bad...you...

  • RE: DiskSpace```

    well there's a couple of ways to do it, but they are just different flavors of the same idea....the command must be run on each server.

    One way is to...

  • RE: How to use sqlcmd to run my create database/tables/sp's script

    niteshrajgopal (6/17/2010)


    Thank you Lowell. I will try that now. You are a lifesaver:-D

    I would really really appreciate it if you could do a sample of that form for me as...

  • RE: Login failed for user 'NT AUTHORITY\ANONYMOUS LOGON'. , but it works on the server

    when you create a linked server, you have one of 4 security options to use as far as which credentials.

    I suspect that the first option shown in the screenshot below...

  • RE: link server having two different database and also different login

    from the GUI, it's not obvious how to alias an existing SQL Server:

    --#################################################################################################

    --Linked server Syntax for SQL Server With Alias

    --#################################################################################################

    EXEC master.dbo.sp_addlinkedserver @server = N'MyLinkedServer',@srvproduct = N'', @datasrc = N'DBSQL2K5', @provider...

  • RE: link server having two different database and also different login

    biren (6/17/2010)


    yes I can link more than one server but what if like in my case I have linked the server having database AA with its login details now when...

  • RE: Create Identical Triggers for all Tables in One Database

    goodguy (6/17/2010)


    Thank you, all for your valuable inputs.

    @Lowell: most tables have the PK as the first column, yes, but some tables have composite PKs, made of two/three columns. Will it...

  • RE: Create Identical Triggers for all Tables in One Database

    here is something very similar to what Wayne posted, the only difference is my script makes an assumption that the FIRST column in a table is the Primary Key because...

  • RE: DateDiff In SSRS Problem

    are you trying to get a boolean value?

    DateDiff returns an integer, your example seems to be doing this:

    FORMAT (DateDiff("DAY", Fields!ReAdmitDate.Value, Fields!AdmitDate.Value) >= 30)

    'would be the same as this witht he...

  • RE: Corrupt Master Database?

    if you can log in to SQL Server, master is not corrupt; could it be the logins were deleted?

    If you open Object Explorer in SSMS, and expand the Security>>Logins...

Viewing 15 posts - 9,211 through 9,225 (of 13,461 total)