About 509,000 results
Open links in new tab
  1. sql server - How to use SCOPE_IDENTITY to retrieve the last ID …

    Jan 24, 2012 · SCOPE_IDENTITY (), like @@IDENTITY, will return the last identity value created in the current session, but it will also limit it to your current scope as well. In other words, it will …

  2. sql - What is the difference between Scope_Identity (), Identity ...

    The identity() function is not used to get an identity, it's used to create an identity in a select...into query. The session is the database connection. The scope is the current query or the current …

  3. sql - How to get the identity of an inserted row? - Stack Overflow

    How can I get the IDENTITY of an inserted row? I know about @@IDENTITY and IDENT_CURRENT and SCOPE_IDENTITY, but don't understand the implications or impacts …

  4. sql - @@IDENTITY, SCOPE_IDENTITY (), OUTPUT and other …

    In other words, it will return the last identity value that you explicitly created, rather than any identity that was created by a trigger or a user defined function. IDENT_CURRENT () Returns …

  5. sql server - Reset SCOPE_IDENTITY () - Stack Overflow

    Jan 26, 2017 · I am calling Scope_Identity () after the second insert to pick up the newly inserted record Identity. If the second insert does nothing due to a join, I want to check the …

  6. What is scope in SQL Server / how is it defined?

    9 I am trying to find documentation on SQL Server where concept of scope is defined. I just want to understand it better. I had been looking at scope_identity() function and it says that …

  7. SQL Server understand SCOPE_IDENTITY () - Stack Overflow

    Nov 22, 2011 · 7 In your query, SCOPE_IDENTITY() is going to return the last entered identity value into the database, for this scope. In this instance, it will be the identity for the AlertLogs …

  8. sql - ¿Es posible usar SCOPE_IDENTITY en un update?¿Alternativas ...

    Uso SCOPE_IDENTITY para recuperar la id de la inserción y así poder trabajar con el. Por lo tanto se que con las insert funciona. La pregunta es, ¿funciona con las update? He probado a …

  9. sql server - Stored procedure - return identity as output parameter …

    Jun 29, 2010 · VALUES (@col1) SELECT @new_identity = SCOPE_IDENTITY() SELECT @new_identity AS id RETURN END The output parameter is easier to work with in T-SQL …

  10. sql server - Correct use of SCOPE_IDENTITY function within simple ...

    I'd like to simply send some information from a simple client to a log file and then use the identity created for further processing. Is the following use of SCOPE_IDENTITY() correct? CREATE …