国产av日韩一区二区三区精品,成人性爱视频在线观看,国产,欧美,日韩,一区,www.成色av久久成人,2222eeee成人天堂

? ??? ?? C++ C#? SQL Server ?? ?????? ?? ?? ??? ????? ????? ??? ?? ????

C#? SQL Server ?? ?????? ?? ?? ??? ????? ????? ??? ?? ????

Jan 10, 2025 am 09:09 AM

How Can I Successfully Retrieve Output Parameters from a SQL Server Stored Procedure in C#?

C#?? ?? ???? ?? ???? ??

??

SQL Server ?? ????? ?? ????? C# ??? ???? ?? ??? ? ????. ??? ?? ??? ????? ???? ?? ???? ??? null ??? ?? ??? ?????.

?? ????

?? ??? ??????? ???? ?? ?? ?? ????? ????? ??? ?? ?? ???? usp_InsertContract? ??? ???.

CREATE PROCEDURE usp_InsertContract
    @ContractNumber varchar(7),
    @NewId int OUTPUT
AS
BEGIN
    INSERT INTO [dbo].[Contracts] (ContractNumber)
        VALUES (@ContractNumber);
    Select @NewId = Id From [dbo].[Contracts] where ContractNumber = @ContractNumber;
END

?????? ??

?? ??? ???? ?????? ??? ???.

pvConnectionString = "Server = Desktop-PC\SQLEXPRESS; Database = PVDatabase; User ID = sa;
    PASSWORD = *******; Trusted_Connection = True;";

try
{
    pvConnection = new SqlConnection(pvConnectionString);
    pvConnection.Open();
}
catch (Exception e)
{
    databaseError = true;
}

?? ??

?? ??? ???? ?? ????? ?????.

pvCommand = new SqlCommand("usp_InsertContract", pvConnection);

pvCommand.Transaction = pvTransaction;
pvCommand.CommandType = CommandType.StoredProcedure;

pvCommand.Parameters.Clear();
pvCommand.Parameters.Add(new SqlParameter("@ContractNumber", contractNumber));

SqlParameter pvNewId = new SqlParameter();
pvNewId.ParameterName = "@NewId";
pvNewId.DbType = DbType.Int32;
pvNewId.Direction = ParameterDirection.Output;
pvCommand.Parameters.Add(pvNewId);

try
{
    sqlRows = pvCommand.ExecuteNonQuery();

    if (sqlRows > 0)
        Debug.Print("New Id Inserted =  ", 
            pvCommand.Parameters["@NewId"].Value.ToString()); 
}
catch (Exception e)
{
    Debug.Print("Insert Exception Type: {0}", e.GetType());
    Debug.Print("  Message: {0}", e.Message);
}

???

SCOPE_IDENTITY()? ???? ?? ?? ???? ?? ????? ? ?? ???? null ? ??? ?????.

CREATE PROCEDURE usp_InsertContract
    @ContractNumber varchar(7),
    @NewId int OUTPUT
AS
BEGIN
    INSERT INTO [dbo].[Contracts] (ContractNumber)
    VALUES (@ContractNumber);
    SELECT @NewId = SCOPE_IDENTITY();
END

? ??? ?? ????? C#?? ????? ?? ??? ?????.

using(SqlConnection conn = new SqlConnection(pvConnectionString))
using(SqlCommand cmd = new SqlCommand("dbo.usp_InsertContract", conn))
{
    cmd.CommandType = CommandType.StoredProcedure;
    cmd.Parameters.Add("@ContractNumber", SqlDbType.VarChar, 7).Value = contractNumber;
    cmd.Parameters.Add("@NewId", SqlDbType.Int).Direction = ParameterDirection.Output;
    conn.Open();
    cmd.ExecuteNonQuery();
    int contractID = Convert.ToInt32(cmd.Parameters["@NewId"].Value);
    conn.Close();
}

? ??? ?? ?????? ??? ?? ?? ????? ???? ?????.

? ??? C#? SQL Server ?? ?????? ?? ?? ??? ????? ????? ??? ?? ????? ?? ?????. ??? ??? PHP ??? ????? ?? ?? ??? ?????!

? ????? ??
? ?? ??? ????? ???? ??? ??????, ???? ?????? ????. ? ???? ?? ???? ?? ??? ?? ????. ???? ??? ???? ???? ??? ?? admin@php.cn?? ?????.

? AI ??

Undresser.AI Undress

Undresser.AI Undress

???? ?? ??? ??? ?? AI ?? ?

AI Clothes Remover

AI Clothes Remover

???? ?? ???? ??? AI ?????.

Video Face Swap

Video Face Swap

??? ??? AI ?? ?? ??? ???? ?? ???? ??? ?? ????!

???

?? ??

?? : ????? ????? ??
1 ? ? ? By DDD
?? ?? ??
3 ? ? ? By Jack chen
???

??? ??

???++7.3.1

???++7.3.1

???? ?? ?? ?? ???

SublimeText3 ??? ??

SublimeText3 ??? ??

??? ??, ???? ?? ????.

???? 13.0.1 ???

???? 13.0.1 ???

??? PHP ?? ?? ??

???? CS6

???? CS6

??? ? ?? ??

SublimeText3 Mac ??

SublimeText3 Mac ??

? ??? ?? ?? ?????(SublimeText3)

???

??? ??

?? ????
1790
16
Cakephp ????
1732
56
??? ????
1582
29
PHP ????
1451
31
???
C ???? ?? ?????? ???? C ???? ?? ?????? ???? Jul 01, 2025 am 01:11 AM

?? ???? ??? C?? ??? ??? ???? ??? : ? ????? ? ? ????? C? ??? ? ????? ?? ?? ??? ?? ??? ???? ?????. 1. ?? ??? ???? C? ?? ??? ???? ?? ?? ?? Curly Braces {}? ???? ?? ??? ?? ??? ???????. 2. ?? ??? ? ??? ?? ???? C?? ?? ??? ?? ????? ??? ???? ???? ???? ??? ?????? ???????. RAII ??? ?? ??? ??? ? ????. 3. ?? ? ??? ???? C? ?? ?, ??? ? ???? ?? ??? ??????? ??? ???? ?? ?? ??? ???????. 4. ?? ????? ???? STL? ??? ????? ????? ????? ???? ????? ????? ???????. 5

C ??? : ?? ?? ?? C ??? : ?? ?? ?? Jun 22, 2025 am 12:16 AM

C DestructorseSpecialmembections? ScopeorisDeleted?? whoenanobjectgoesout.1) theaUcialmanagingMemory, FileHandles ? NetworkConnection.2) ??? wengrectdefiningdestructorsfordynamicmemory, LeadingTomemo

C? ?? ??? ????? (STL)? ?????? C? ?? ??? ????? (STL)? ?????? Jul 01, 2025 am 01:17 AM

C STL? ????, ???? ? ???? ?? ?? ?? ??? ???? ??? ?? ??? ??? ? ?? ?????. ??, ??, ? ? ??? ?? ????? ???? ???? ? ?????. ??? ?? ???? ???? ?? ??? ?????. ?? ?? ? ??? ?????? ??? ??????. ?? ??? ???? ?? ? ??? ?????? ?? ??? ?? ??? ?????. ??, ??, ??, ?? ? ??? ?? ????? ????? ???? ???? ????? ??? ???? ?????. ???? ????? ????? ????, ????? ???? ??? ??? ???? ??? ??????. ?? ?? ???? ?? ??, ???, ?? ?, ??, ?? ?? ? ??? ??? ???? ???? ?????. STL? ??? c

c OpenGL? ??? ??? ???????? ???? c OpenGL? ??? ??? ???????? ???? Jul 02, 2025 am 12:07 AM

C ???????? ??? ??? ???????? OpenGL? ?? ?????. ?? ?? ??? ???? GLFW ?? SDL? ???? ?? ??? GLEW ?? GLAD? ?? ???????? 3.3? ?? ???? ??? ???? ???????. ??, OpenGL? ?? ?? ??? ???? ?? ??? ????? ??????. ?? ??? ??? ?????, ??? ??? ? ???? ?? ??? ????, ?? ?? ??? ?????, ?? ??? ??? ???? ?? ?? ?? ????? LearnOpEngl, OpenGlredbook ? YouTube ??? ???? ?????. ?? ???

C ?? ??? ????? (STL)? ?? ???? C ?? ??? ????? (STL)? ?? ???? Jul 02, 2025 am 01:26 AM

STL (?? ??? ?????)? ????, ??? ? ????? ? ?? ?? ?? ??? ???? C ?? ?????? ??? ?????. 1. ??, ? ? ??? ?? ????? ???? ???? ? ?????. 2. ???? ???? ??? ????? ? ?????. 3. ?? ? ??? ?? ????? ???? ???? ? ?????. ????? ??? ? ??? ?? ??? ???? ?? ?? ? ??? ???? Deque? ?? ?? ?? ??? ???? MAP/Unordered_map? ? ? ? ??? ???? ??/UNORDERED_SET? ???? ?????. ????? ???? ?? ?? ??? ??????? ??? ? Lambda ???? ???????. ?? ???? ??? ??? ? ???? ?????? m? ???? ?????????.

std :: Chrono ?? c std :: Chrono ?? c Jul 15, 2025 am 01:30 AM

STD :: Chrono? ?? ?? ??, ?? ?? ??, ?? ?? ? ?? ?? ? ?? ?? ??? ???? C?? ???? ??? ?????. 1. std :: chrono :: system_clock :: now ()? ???? ?? ??? ?? ? ??? ?? ??? ???? ?? ? ? ??? ??? ??? ???? ?? ?? ? ????. 2. std :: Chrono :: steady_clock? ???? ?? ??? ???? ?? ??? ???? duration_cast? ?? ?? ?, ? ? ?? ??? ??????. 3. ?? (time_point) ? ?? (??)? ?? ??? ? ? ??? ?? ??? ? ?? epoch (epoch)???? ???????.

C ?? ???????? ???? C ?? ???????? ???? Jul 02, 2025 am 12:54 AM

C? ?????. ??? ? ? ?? ???? ???????. 1. ?? ??? ????? ?? ??? ??? ??? ?? ??, ??, ?? ??, ?? ?? ?? ??? ???????. 2. ??, ?, ??, ??? ? ??? ?? STL ????? ??? ????? ? ??? ???. 3. ?? ??? ?? ?? scanf ? printf ??? ?? ?? ?? ? ?? ??? ?????. 4. ???? ???? ???? ?? ??? ????? ???? ??????. 5. ?? ?? ? ??? ??? ?? ???? ?? ??? ?????.

C? ??/??? CIN ? Cout? ???? ??? ?????? C? ??/??? CIN ? Cout? ???? ??? ?????? Jul 02, 2025 am 01:10 AM

C?? Cin ? Cout? ?? ?? ? ??? ?????. 1. Cout? ???? ??? ?? ???? ??? ?? ? ?? ??? ???? ????. 3. ??? ?? ? ???? ?? ? GetLine (CIN, STR)? ??????. 4. CIN ? GetLine? ??? ?? ??? ??? ??? ???????. 5. ?? ?? ? ?? ?? ??? ????? cin.clear () ? cin.ignore ()? ???????. ??? ?? ???? ????? ???? ?? ????? ??????.

See all articles