c# Programming Glossary: procedure
How to execute a stored procedure within C# program http://stackoverflow.com/questions/1260952/how-to-execute-a-stored-procedure-within-c-sharp-program to execute a stored procedure within C# program I want to execute this stored procedure from.. procedure within C# program I want to execute this stored procedure from a C# program. I have written the following stored procedure.. from a C# program. I have written the following stored procedure in a SqlServer query window and saved it as stored1 use master..
Are there any suggestions for developing a C# coding standards / best practices document? [closed] http://stackoverflow.com/questions/14967/are-there-any-suggestions-for-developing-a-c-sharp-coding-standards-best-pract So here goes .... any suggestions Any at all c# standards procedure share improve this question We start with Microsoft's .NET..
Using global keyboard hook (WH_KEYBOARD_LL) in WPF / C# http://stackoverflow.com/questions/1639331/using-global-keyboard-hook-wh-keyboard-ll-in-wpf-c-sharp hookedLowLevelKeyboardProc summary HookCallbackAsync procedure that calls accordingly the KeyDown or KeyUp events. summary..
Are there good reasons not to use an ORM? [closed] http://stackoverflow.com/questions/194147/are-there-good-reasons-not-to-use-an-orm in the every database call should be through a stored procedure mentality. Why would an ORM make things harder to debug You'll..
What is a message pump? http://stackoverflow.com/questions/2222365/what-is-a-message-pump keyboard messages. DispatchMessage ensures that the window procedure is called with the message. Every GUI enabled .NET program has.. that COM creates it uses PostMessage to have the window procedure of that window execute code. On the STA thread. The message..
Sharing sessions across applications using the ASP.NET Session State Service http://stackoverflow.com/questions/2868316/sharing-sessions-across-applications-using-the-asp-net-session-state-service the same machine key and making a small tweak to a stored procedure both apps can share any session keys and or forms authenication... aspnet_regsql.exe E ssadd sstype p S . SQLEXPRESS Stored procedure TempGetAppID tweak to @appId int OUTPUT AS start change Use..
Get output parameter value in ADO.NET http://stackoverflow.com/questions/290652/get-output-parameter-value-in-ado-net output parameter value in ADO.NET My stored procedure has an output parameter @ID INT OUT How can I retrieve this.. 's Parameters collection. Then execute the stored procedure and get the value of the parameter. Using your code sample SqlConnection..
Question about terminating a thread cleanly in .NET http://stackoverflow.com/questions/3632149/question-about-terminating-a-thread-cleanly-in-net before it hits it's next loop iteration I want this cancel procedure to be snappy don't tell me I need to sprinkle these while loops..
How to use DbContext.Database.SqlQuery<TElement>(sql, params) with stored procedure? EF Code First CTP5 http://stackoverflow.com/questions/4873607/how-to-use-dbcontext-database-sqlquerytelementsql-params-with-stored-proced TElement sql params with stored procedure EF Code First CTP5 I have a stored procedure that has three.. with stored procedure EF Code First CTP5 I have a stored procedure that has three parameters and I've been trying to use the following.. my question is how you can use this method with a stored procedure that expects parameters Thanks. c# sql ado.net linq to entities..
How to pass table value parameters to stored procedure from .net code http://stackoverflow.com/questions/5595353/how-to-pass-table-value-parameters-to-stored-procedure-from-net-code to pass table value parameters to stored procedure from .net code I have an MS SQL Server 2005 database. In a.. .net code I have an MS SQL Server 2005 database. In a few procedures I have table parameters that I pass to a stored proc as an.. value parameters and I know how to use them in stored procedures. But I don't know how to pass one to the parameters list in..
Fastest Way of Inserting in Entity Framework http://stackoverflow.com/questions/5940225/fastest-way-of-inserting-in-entity-framework 1 recreateContext false many hours That's your current procedure commitCount 100 recreateContext false more than 20 minutes commitCount..
C# DLL config file http://stackoverflow.com/questions/594298/c-sharp-dll-config-file assembly of that app domain is. Because of all this the procedure for creating a library specific config file is not so convenient...
Should you make multiple insert calls or pass XML? http://stackoverflow.com/questions/10295326/should-you-make-multiple-insert-calls-or-pass-xml NULL Now write down the sp in following manner. CREATE PROCEDURE AddToTarget @TargetUDT1 TargetUDT1 READONLY @TargetUDT2 TargetUDT2..
Insert entire DataTable into database at once instead of row by row? http://stackoverflow.com/questions/10405373/insert-entire-datatable-into-database-at-once-instead-of-row-by-row etc. The columns you have in your data table. GO CREATE PROCEDURE dbo.InsertMyDataTable @dt AS dbo.MyDataTable READONLY AS BEGIN..
How to pass an array into a SQL Server stored procedure http://stackoverflow.com/questions/11102358/how-to-pass-an-array-into-a-sql-server-stored-procedure TYPE dbo.EmployeeList AS TABLE EmployeeID INT GO CREATE PROCEDURE dbo.DoSomethingWithEmployees @List AS dbo.EmployeeList READONLY.. NOT NULL GO Now your stored procedure can just be CREATE PROCEDURE dbo.DoSomethingWithEmployees @List VARCHAR MAX AS BEGIN SET..
Sending an array of values to Oracle procedure to use in WHERE IN clause http://stackoverflow.com/questions/13580245/sending-an-array-of-values-to-oracle-procedure-to-use-in-where-in-clause I have a stored procedure in Oracle as shown below CREATE PROCEDURE MY_TEST_PROC CUR OUT SYS_REFCURSOR PARAM_THAT_WILL_BE _USED_INSIDE_WHERE_IN..
What's a good alternative to firing a stored procedure 368 times to update the database? http://stackoverflow.com/questions/3282254/whats-a-good-alternative-to-firing-a-stored-procedure-368-times-to-update-the-d to be stored somewhere right Stored Proc contents ALTER PROCEDURE dbo . spUpdateOrderDetailDiscountedItem Add the parameters for..
How to pass XML from C# to a stored procedure in SQL Server 2008? http://stackoverflow.com/questions/3600091/how-to-pass-xml-from-c-sharp-to-a-stored-procedure-in-sql-server-2008 to sql server stored procedure such as this CREATE PROCEDURE BookDetails_Insert @xml xml I want compare some field data with..
Does Entity Framework Code First support stored procedures? http://stackoverflow.com/questions/4845246/does-entity-framework-code-first-support-stored-procedures s.p.'s will get clobbered. You may need to add the CREATE PROCEDURE statements in your code. For EF 4.2 var customers context.Database.SqlQuery..
Error in Updating a table using datetime as parameter in Stored procedure http://stackoverflow.com/questions/5049173/error-in-updating-a-table-using-datetime-as-parameter-in-stored-procedure DateTime value. The statement has been terminated. ALTER PROCEDURE dbo . attendance_updatebyemployee_id @Employee_id int @AtDate..
C#/SQL - What's wrong with SqlDbType.Xml in procedures? http://stackoverflow.com/questions/574928/c-sql-whats-wrong-with-sqldbtype-xml-in-procedures 1 1 primary key XmlText xml NOT NULL And the sproc CREATE PROCEDURE XmlTest_Insert @XmlText xml AS INSERT INTO XmlTest XmlText VALUES..
Getting return value from stored procedure in C# http://stackoverflow.com/questions/706361/getting-return-value-from-stored-procedure-in-c-sharp query set ANSI_NULLS ON set QUOTED_IDENTIFIER ON go ALTER PROCEDURE dbo . Validate @a varchar 50 @b varchar 50 output AS SET @Password..
C# SQL Server - Passing a list to a stored procedure http://stackoverflow.com/questions/7097079/c-sharp-sql-server-passing-a-list-to-a-stored-procedure need to use it properly in your stored procedure CREATE PROCEDURE dbo . sp_UseStringList @list StringList READONLY AS BEGIN Just..
Entity Framework Stored Procedure Table Value Parameter http://stackoverflow.com/questions/8157345/entity-framework-stored-procedure-table-value-parameter and the Store proc looks like the following... ALTER PROCEDURE dbo . usp_RaiseWarnings_rs @CaseID int @UserID uniqueidentifier..
Get value output from SQL Server stored procedure into variable http://stackoverflow.com/questions/8618978/get-value-output-from-sql-server-stored-procedure-into-variable answer yet. I have the following stored procedure CREATE PROCEDURE dbo . AllocateId AS BEGIN TRANSACTION UPDATE TOP 1 IdReservation.. value as well you should amend you stored procedure CREATE PROCEDURE dbo . AllocateId AS BEGIN TRANSACTION declare @id int UPDATE..
SCOPE_IDENTITY() always returning 0 http://stackoverflow.com/questions/8633821/scope-identity-always-returning-0 always returning 0 My stored procedure is ALTER PROCEDURE dbo . Insert_QuickLabDump @Specimen_ID varchar 50 @Client_Key.. quick example which should work with ExecuteScalar CREATE PROCEDURE dbo.QuickExample @Name VARCHAR 50 AS INSERT INTO dbo.MyTable.. create a stored procedure with an output parameter CREATE PROCEDURE dbo.QuickExample @Name VARCHAR 50 @Id INT OUTPUT AS INSERT INTO..
How Can i display the output of SQL “PRINT” Command in C#? http://stackoverflow.com/questions/8689336/how-can-i-display-the-output-of-sql-print-command-in-c i.e the procedure in C# how can i do that here is the PROCEDURE ALTER PROC ResultsPoll @pollid INT AS DECLARE @count1 INT DECLARE..
How to insert a data table into SQL Server database table? http://stackoverflow.com/questions/9075159/how-to-insert-a-data-table-into-sql-server-database-table and define a parameter in your Stored Ptocedure CREATE PROCEDURE dbo . InsertTable @myTableType MyTableType readonly AS BEGIN..
How to pass User Defined Table Type as Stored Procedured parameter in C# http://stackoverflow.com/questions/1030848/how-to-pass-user-defined-table-type-as-stored-procedured-parameter-in-c-sharp to pass User Defined Table Type as Stored Procedured parameter in C# In SQL Server 2008 we can define a table type.. 2008 we can define a table type and use it as Stored Procedures' parameters. But How can I use it in C# invocation of this.. how to create a table or list and pass it into Stored Procedure in C# code with this new feature of SQL Server 2008 c# sql..
Get Stored Procedure from Data Context : Linq to SQl http://stackoverflow.com/questions/11310996/get-stored-procedure-from-data-context-linq-to-sql Stored Procedure from Data Context Linq to SQl I have a stored procedure named.. layer. Unlike GetTable method we don ™t have a GetStoredProcedure method for data context. How can we call the stored procedure.. int userID void UpdateBankAccountUsingStoredProcedure public class LijosSimpleBankRepository ILijosBankRepository..
how to get logged on users with their status on remote machine http://stackoverflow.com/questions/14212155/how-to-get-logged-on-users-with-their-status-on-remote-machine The RPC server is unavailable The Remote Procedure Call server is unavailable cannot check for logged on users..
Code-First Entity Framework w/ Stored Procedure returning results from complex Full-text Searches http://stackoverflow.com/questions/14243946/code-first-entity-framework-w-stored-procedure-returning-results-from-complex-f First Entity Framework w Stored Procedure returning results from complex Full text Searches I am looking.. public static IEnumerable TResult ExecuteStoredProcedure TResult this Database database IStoredProcedure TResult procedure.. TResult this Database database IStoredProcedure TResult procedure string spName var parameters CreateSqlParametersFromProperties..
Capture Stored Procedure print output in .NET http://stackoverflow.com/questions/1880471/capture-stored-procedure-print-output-in-net Stored Procedure print output in .NET Is it possible to capture print output.. TheConnection cmd.CommandType CommandType.StoredProcedure string ProcPrint c# .net stored procedures share improve..
Passing List<> to SQL Stored Procedure http://stackoverflow.com/questions/209686/passing-list-to-sql-stored-procedure List to SQL Stored Procedure I've often had to load multiple items to a particular record..
Sharing session state between 2 ASP.NET applications using SQL Server http://stackoverflow.com/questions/2402785/sharing-session-state-between-2-asp-net-applications-using-sql-server applications.aspx and hacked the TempGetAppID Stored Procedure to return the same application id 1 . This appears to work as..
Module not found http://stackoverflow.com/questions/2774741/module-not-found send in IntPtr.Zero for the hMod parameter when the Hook Procedure was in the local assembly. You can refer to the msdn documentation..
How to make this CLR work with 2005? http://stackoverflow.com/questions/3209193/how-to-make-this-clr-work-with-2005 say SAFE . Now I get this error Msg 6522 Level 16 State 1 Procedure StoredProcedure1 Line 0 A .NET Framework error occurred during.. I get this error Msg 6522 Level 16 State 1 Procedure StoredProcedure1 Line 0 A .NET Framework error occurred during execution of.. execution of user defined routine or aggregate 'StoredProcedure1' System.Security.HostProtectionException Attempted to perform..
Using DateTime in a SqlParameter for Stored Procedure, format error http://stackoverflow.com/questions/425870/using-datetime-in-a-sqlparameter-for-stored-procedure-format-error DateTime in a SqlParameter for Stored Procedure format error I'm trying to call a stored procedure on a SQL.. sprocCommand.CommandType System.Data.CommandType.StoredProcedure sprocCommand.Parameters.AddRange parameters.ToArray sprocCommand.ExecuteNonQuery.. type. command.CommandType System.Data.CommandType.StoredProcedure Add the parameter. SqlParameter parameter command.Parameters.Add..
How to use DbContext.Database.SqlQuery<TElement>(sql, params) with stored procedure? EF Code First CTP5 http://stackoverflow.com/questions/4873607/how-to-use-dbcontext-database-sqlquerytelementsql-params-with-stored-proced work and threw an SqlException with the following message Procedure or function 'mySpName' expects parameter '@param1' which was..
Mysql Haversine Procedure (radius)using a center point http://stackoverflow.com/questions/6352089/mysql-haversine-procedure-radiususing-a-center-point Haversine Procedure radius using a center point I'm fairly new to MySql and what..
HTML - How do I know when all frames are loaded? http://stackoverflow.com/questions/672731/html-how-do-i-know-when-all-frames-are-loaded this using System.Windows.Forms protected delegate void Procedure private void executeAfterLoadingComplete Procedure doNext WebBrowserDocumentCompletedEventHandler.. void Procedure private void executeAfterLoadingComplete Procedure doNext WebBrowserDocumentCompletedEventHandler handler null..
Call a stored procedure with parameter in c# http://stackoverflow.com/questions/7542517/call-a-stored-procedure-with-parameter-in-c-sharp program and I try to do an insert by call a created Store Procedure from my Data Base. This a button insert I make work well. private.. Command String con cmd.CommandType CommandType.StoredProcedure con.Open da. .ExecuteNonQuery con.Close dt.Clear da.Fill dt.. sp_Add_contact con cmd.CommandType CommandType.StoredProcedure cmd.Parameters.Add @FirstName SqlDbType.VarChar .Value txtFirstName.Text..
Entity Framework Stored Procedure Table Value Parameter http://stackoverflow.com/questions/8157345/entity-framework-stored-procedure-table-value-parameter Framework Stored Procedure Table Value Parameter I'm trying to call a stored procedure.. method public IEnumerable T ExecuteStoredProcedure T string procedureName params object parameters StringBuilder.. The command string ends up like this EXEC someStoredProcedureName 0 1 2 3 4 5 6 7 I tried to run this method on a stored procedure..
Timeout expired. The timeout period elapsed prior to completion of the operation or the server is not responding. The statement has been terminated http://stackoverflow.com/questions/8602395/timeout-expired-the-timeout-period-elapsed-prior-to-completion-of-the-operation 327 NovinMedia.Data.DbObject.RunProcedure String storedProcName IDataParameter parameters Int32 rowsAffected.. DateTime.Now false AddTask DoStuff 10 ant That StoredProcedure ALTER Procedure dbo . sp_OnlineUsers_Update_SessionEnd_And_Online.. false AddTask DoStuff 10 ant That StoredProcedure ALTER Procedure dbo . sp_OnlineUsers_Update_SessionEnd_And_Online @Session_End..
Get value output from SQL Server stored procedure into variable http://stackoverflow.com/questions/8618978/get-value-output-from-sql-server-stored-procedure-into-variable stored procedures share improve this question Procedure return value is different from result set s returned by that..
How Can i display the output of SQL “PRINT” Command in C#? http://stackoverflow.com/questions/8689336/how-can-i-display-the-output-of-sql-print-command-in-c of SQL &ldquo PRINT&rdquo Command in C# i am having a SQL Procedure that always returns PRINT Command and i want to extract the..
|