Skip to content

ErcanOPAK.com

  • ASP.Net WebForms
  • ASP.Net MVC
  • C#
  • SQL
  • MySQL
  • PHP
  • Devexpress
  • Reportviewer
  • About

Tag: stored

SQL

View the Definition of a Stored Procedure in SQL

- 31.12.19 - ErcanOPAK comment on View the Definition of a Stored Procedure in SQL

– In Object Explorer, connect to an instance of the Database Engine. – On the toolbar, click New Query. – In the query window, enter the following statement that uses the sp_helptext system stored procedure. Change the database name and stored procedure name to reference the database and stored procedure that you want. EXEC sp_helptext […]

Continue Reading ..
SQL

Drop all the tables, stored procedures, triggers, constraints and all the dependencies in one sql statement

- 27.10.19 | 22.11.19 - ErcanOPAK comment on Drop all the tables, stored procedures, triggers, constraints and all the dependencies in one sql statement

These 2 scripts clean all views, SPS, functions PKs, FKs and tables. 1. The First script by Adam Anderson, updated to support objects in other schemas than dbo: — check constraints select @stmt = isnull( @stmt + @n, ” ) + ‘alter table [‘ + schema_name(schema_id) + ‘].[‘ + object_name( parent_object_id ) + ‘] drop […]

Continue Reading ..
SQL

Create, Alter, Drop and Execute SQL Server Stored Procedures

- 23.09.19 | 22.11.19 - ErcanOPAK comment on Create, Alter, Drop and Execute SQL Server Stored Procedures

A stored procedure is a saved block of T-SQL code, such as a query to list the rows in a table.  A block of T-SQL code can be saved in a T-SQL script file.  You can also store the code from a script file in a stored procedure. There are several benefits that result from […]

Continue Reading ..
SQL

SQL Query to Find and Replace text in a stored procedures

- 20.09.19 | 22.11.19 - ErcanOPAK comment on SQL Query to Find and Replace text in a stored procedures

Declare @spnames CURSOR Declare @spname nvarchar(max) Declare @moddef nvarchar(max) Set @spnames = CURSOR FOR select distinct object_name(c.id) from syscomments c, sysobjects o where c.text like ‘%findtext%’ and c.id = o.id and o.type = ‘P’ OPEN @spnames FETCH NEXT FROM @spnames into @spname WHILE @@FETCH_STATUS = 0 BEGIN Set @moddef = (SELECT Replace ((REPLACE(definition,’findtext’,’replacetext’)),’ALTER’,’create’) FROM sys.sql_modules […]

Continue Reading ..
ASP.Net WebForms / SQL

How to solve “TableAdapter can’t see stored procedure returned fields when using temp table” problem

- 06.06.18 | 22.11.19 - ErcanOPAK comment on How to solve “TableAdapter can’t see stored procedure returned fields when using temp table” problem

Add these lines to the beginning of your stored procedure. The statement is never executed, but for some reason it gets the job done. I really don’t know how and why 🙂 IF 1=0 BEGIN SET FMTONLY OFF END

Continue Reading ..
April 2021
M T W T F S S
 1234
567891011
12131415161718
19202122232425
2627282930  
« Jan    

Most Viewed Posts

  • Get the First and Last Word from a String or Sentence in SQL (243)
  • How to use Map Mode for Vertical Scroll Mode in Visual Studio (194)
  • How to make some specific word(s) Bold or Underline in ReportViewer (187)
  • How to solve “Response.Redirect cannot be called in a Page callback” for DevExpress Components (183)
  • Confirm before process with ASPxButton in Devexpress (172)
  • ASPxGridView – Disable CheckBox based on condition in GridViewCommandColumn (170)
  • Find numbers with more than two decimal places in SQL (168)
  • Devexpress ASPxGridview Column Grouping in Code (164)
  • DATEADD Function in SQL (163)
  • Tense Changes When Using Reported Speech (160)

Recent Posts

  • How to check for ‘IS NOT NULL’ And ‘IS NOT EMPTY’ string in SQL
  • How to auto-scroll or manually to end of div when data is added
  • Filter Rows By Max Date in SQL
  • How to Validate a DateTime in C#?
  • Convert comma separated string into a List in C#
  • Converting a List to a comma separated string in C#
  • How to add placeholder to Multiple Selection DropDownList in Asp.Net MVC
  • How to use toFixed() for Float numbers in Javascript
  • Convert List to List in one line in C#
  • How to use column search in datatable when responsive is false

Recent Posts

  • How to check for ‘IS NOT NULL’ And ‘IS NOT EMPTY’ string in SQL
  • How to auto-scroll or manually to end of div when data is added
  • Filter Rows By Max Date in SQL
  • How to Validate a DateTime in C#?
  • Convert comma separated string into a List in C#

Most Viewed Posts

  • Get the First and Last Word from a String or Sentence in SQL (243)
  • How to use Map Mode for Vertical Scroll Mode in Visual Studio (194)
  • How to make some specific word(s) Bold or Underline in ReportViewer (187)
  • How to solve “Response.Redirect cannot be called in a Page callback” for DevExpress Components (183)
  • Confirm before process with ASPxButton in Devexpress (172)

Social

  • ErcanOPAK.com
  • GoodReads
  • LetterBoxD
  • Linkedin
  • The Blog
  • Twitter

powered by XBlog Plus WordPress Theme