Forum Replies Created

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

  • RE: trigger problem

    Ambrose

    when you update a row in sql server it creates an entry in the inserted and deleted logical tables before the update is carried out. This means that your code...

  • RE: Auditing inserts updates etc

    Never used this but you could give it a try

    http://www.logpi.com/

    Dave

  • RE: Initializing input variable.

    You must specify the word default when using a default value in a user defined function e.g.

    select name, dbo.udfgetloc(1, DEFAULT) Location from

    SEE BOL EXCERPT

    A user-defined function takes zero or...

  • RE: Select Where IN or nested?

    The only way i can see of doing this is to alias the table and self join the tables.

    Select

    ID

    FROM Table a INNER JOIN Table b on a.ID = b.ID

    INNER JOIN...

  • RE: Using Information Schema to retrive columns - require help

    The following will list primary and foreign keys and the columns they use.

    select TABLE_NAME, CONSTRAINT_NAME, COLUMN_NAME

    from INFORMATION_SCHEMA.CONSTRAINT_COLUMN_USAGE

    ORDER BY TABLE_NAME, CONSTRAINT_NAME

  • RE: Using Information Schema to retrive columns - require help

    The above will also return views which i'm not sure if you want or not. You could write it like this just for users base tables.

    SELECT c.TABLE_NAME, COLUMN_NAME,

    DATA_TYPE, CHARACTER_MAXIMUM_LENGTH,

    ORDINAL_POSITION

    FROM INFORMATION_SCHEMA.columns...

  • RE: DTS and Triggers

    You need to turn off the fast load option in DTS.

    I haven't got it in front of me at the moment but i think it should

    be in one of tabs...

  • RE: How to quickly obtain number of rows in a table?

    if you use sp_spaceused tablename then it is not always accurate you have to run (especially about the space being used)

    sp_spaceused tablename @updateusage = 'TRUE'

    and it takes a bit longer....

  • RE: DateTime Precision

    Oh well. I'd better go and use Informix or Oracle then.

    Thanks anyway.

    Dave

  • RE: SQLServerAgentMail error

    Hans

    We used to get the same issue. Usually you had to stop and start the MAPI service on the server to fix it. If you've just installed the mail stuff...

  • RE: Delete Large records 20 million rows!!! FAST

    I would use the the TRUNCATE command. The deletions will not be logged in the transaction log. e.g.

    TRUNCATE TABLE authors

    You need to be either a member of the sysadmin role...

  • RE: sql mail

    Our internal mail server will only let people it knows and trusts send smtp stuff through it, so need for password it just knows to let that particular SQL Server...

  • RE: sql mail

    OOps don't know what I managed to do there but that won't create a stored procedure for you. The procedure is identical on 2000 & 2003 but if you still...

  • RE: sql mail

    Well here you go then

    --***************Configuring the Message Object ******************

    -- This is to configure a remote SMTP server.

    -- http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cdosys/html/_cdosys_schema_configuration_sendusing.asp

    EXEC @hr = sp_OASetProperty @iMsg, 'Configuration.fields("http://schemas.microsoft.com/cdo/configuration/sendusing").Value','2'

    -- This is...

  • RE: sql mail

    I used to sql mail but it can be a bit of a pain as it's always chaking the pop 3 mailbox even if you don;t want it process SQL...

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