Skip to main content
-1 votes
1 answer
59 views

After INSERT and setting a variable (@scopeID) with SCOPE_IDENTITY(), when I try to JOIN tables with @scopeID, I can only see the value of @scopeID, and other variables are NULL. INSERT INTO ...
yelim lee's user avatar
0 votes
0 answers
351 views

I am trying to utilize a vendors stored procedure that I cannot change. In C# I need the Scope_Identity value. If I could I would set @ID as an output variable. Running the procedure in SQL Developer ...
gwill1010's user avatar
1 vote
0 answers
1k views

The documentation for SCOPE_IDENTITY states that it Returns the last identity value inserted into an identity column in the same scope. I wonder what last really means. Is it the largest value ...
andowero's user avatar
  • 519
-3 votes
1 answer
733 views

I have stored procedure in which I use scope_identity() Create table table1 id int, name varchar, age int Create procedure details @id int, @name varchar, age int ...
jitender singh's user avatar
-1 votes
2 answers
330 views

MS Access front-end with a SQL Server back-end, using pass-through queries in Access over OBDC connection. No ADO, just simple DAO query objects. After an INSERT query is executed, a "SELECT ...
JoshL's user avatar
  • 1
0 votes
0 answers
16 views

How to use scope_identity in JDBC? I have to insert one table (which is in SQL Server ) primary key value into another table which is using first table primary key as foreign key.
Arav's user avatar
  • 1
0 votes
0 answers
57 views

im using PHP and SQL Server i have 2 tables: 1. user (Id_user, user_name) 2. purchase (Id_purchase, Id_user, description) i want to in insert into "user" and then insert into "purchase" with the same ...
Roy RW's user avatar
  • 21
2 votes
1 answer
353 views

I have an auto incrementing ID called deviceID in one of my fields. I was wanting to pass this to a session in php to use later on and was planning on using scope_identity() as I understand that this ...
b.man's user avatar
  • 41
1 vote
0 answers
68 views

I am inserting a row into a remote MS SQL server and want to to retrieve the inserted row ID. I am using sp_executesql and passing in input parameters. The row is inserting but the OUTPUT parameter is ...
VIH's user avatar
  • 11
2 votes
2 answers
108 views

I have a stored procedure for inserting a record in a table. I'm trying to use Scope_Identity() to get back the created ID value. I call the procedure from a method named Add_Claimant(). The method ...
MIkeN's user avatar
  • 21
-2 votes
2 answers
545 views

I am in the middle of a project where we are moving from Oracle to SQL Server. I was wondering if, like the title says,there are any SQL Server equivalent for Oracle's built in function ...
VianneN's user avatar
  • 143
0 votes
1 answer
326 views

I have a simple table : CREATE TABLE [MyTable] ( [ID] [INT] IDENTITY(1,1) NOT NULL, [NAME] [NVARCHAR](100) NOT NULL, [DATA] [NVARCHAR](max) NOT NULL, CONSTRAINT [PK_MyTable] ...
BaltoStar's user avatar
  • 9,151
0 votes
2 answers
1k views

There are a few answers about this problem, but my question is about the particular code I have. I'm trying to get the last inserted ID of this query executing on VBA code. Public Function Execute(...
SercioSoydanov's user avatar
0 votes
1 answer
1k views

With Python and SQL Server, I am inserting a row into table. Post record insertion, I am using SCOPE_IDENTITY() to get latest ID for inserted record. Instead of receiving expected ID, the function is ...
user2961127's user avatar
  • 1,183
0 votes
0 answers
153 views

When I create a new record in a table that has a primary key of type INT and I want to retrieve the value of its ID, I use something like this: INSERT INTO MyTable (Fields) VALUES (MyValues); ...
Osprey's user avatar
  • 1,555

15 30 50 per page
1
2 3 4 5
9