Forum Replies Created

Viewing 15 posts - 16 through 30 (of 31 total)

  • RE: why is this trigger not working ?

    David Burrows - Tuesday, January 17, 2017 2:06 AM

    1. The update should be in the trigger there is no need for an...

  • RE: why is this trigger not working ?

    I have tried another way :
    I have created a stored procedure  [dbo].[sp_timedifference] 
    and in it :

  • update JOURNAL set DIFF=
    CONCAT((DATEDIFF(Minute,start_date,
  • [end_date])/60),':',
                 (DATEDIFF(Minute,start_date,[end_date])%60))

  • RE: why is this trigger not working ?

    Steve Jones - SSC Editor - Monday, January 16, 2017 8:24 PM

    If you're updating, then why not put the UPDATE in the trigger?...

  • RE: why is this trigger not working ?

    I am actually just updating the end_date field. So when it gets written (updated) I wanted the trigger to calculate the time difference.
    So, yes...basically I want a result from...

  • RE: List users that belong to a specific database role

    Thats what I did but it does not work.Its like Lowell said.

  • RE: List users that belong to a specific database role

    Is there a way arround ?
    I need ordinary users to see who belongs in their group.

  • RE: List users that belong to a specific database role

    This, unfortunately,this  works only if I run it on the server. If I run it from my program then I only get one entry and that is only the first...

  • RE: what user membership to assign?

    Joie Andrew - Sunday, January 15, 2017 7:15 PM

    EXEC sp_helprolemember '<rolename>';

    everyone's telling me these builtin stored procedures are deprecated (?)...how can I write...

  • RE: what user membership to assign?

    I think adding a new role is very good idea.
    How can I list users that are a members of my new created role so not to loose track ?

  • RE: what user membership to assign?

    actually, it seems a better option to make all new users database owners and only if you need to deny them something you do that on the object in question....

  • RE: stored procedure is only returning one letter

    Lowell - Saturday, January 14, 2017 9:42 AM

    Senchi - Saturday, January 14, 2017 9:01 AM

    I have...

  • RE: How to Capture Deleted Records

    To TheSQLGuru:

    Inefficient ? Why ? The trigger only fires on the table you use it on.

    You can always see what was changed and when and by who But, is...

  • RE: How to Capture Deleted Records

    simple trigger and an audit table...

    CREATE TRIGGER tr_audit ON twitter FOR INSERT, UPDATE, DELETE

    AS

    DECLARE @bit INT ,

    @field INT ,

    ...

  • RE: Modifying a system stored procedure

    Sue, I tried your suggestion...

    I copied the sp_addlogin

    and created a new one.

    However, I got the error on :

    --execute sp_hexadecimal @passwdbin, @hextext OUT

    and

    --execute sys.sp_hexadecimal @sid, @hextext OUT

    No such stored...

  • RE: sp_addlogin,sp_adduser,sp_addrolemember

    There is no stored procedure for creating user under System Stored procedures

  • Viewing 15 posts - 16 through 30 (of 31 total)