Checking All Date Columns in a Table(s)
Find minimum and maximum values for all date columns in a table or range of tables, using a mask.
2016-09-15 (first published: 2014-10-27)
3,111 reads
Find minimum and maximum values for all date columns in a table or range of tables, using a mask.
2016-09-15 (first published: 2014-10-27)
3,111 reads
http://www.sqlservercentral.com/scripts/split+string/117123/
The above script will split upto 256 char length only. This new version will split upto N length.
2016-09-14 (first published: 2014-10-30)
1,871 reads
This function is used to get the distance between 2 coordinates/latlong in the different formats
2016-09-13 (first published: 2014-10-31)
1,717 reads
If you want to read trace file records from default trace location and want to print to see what are all the activities happened on SQL Server, the query will be helpful for you.
2016-09-12 (first published: 2014-11-12)
2,354 reads
This functions are used to convert integers/numbers into binary format and viceversa.
2016-09-09 (first published: 2014-11-18)
1,899 reads
This procedure takes in charge the clean-up for a given table based on a date field
given as parameter and a retention expressed as a number of days.
2016-09-08 (first published: 2014-11-19)
1,535 reads
2016-09-06 (first published: 2014-11-20)
1,864 reads
2016-09-05 (first published: 2015-05-20)
2,681 reads
The bar for entry into CodeSOD is pretty straight forward: professionally-developed code that elicits that certain What The— reaction. Though there have been a few exceptions over the years, generally speaking, student code, hobbyist code, and amateur code need not apply. That said, I'd like to try something a little different today. Today's example is not technically professionally-developed, it's a Stupid Coding Trick.
"So I was bored at work one day," Graeme Job explains, "and wondered, what's the most useless thing I could do with my time without actually doing anything. Then it hit me. I could use T-SQL to generate... Mandelbrot."
Graeme continued, "Following is a single T-SQL SELECT statement that generates a text-representation of a Mandelbrot Set. The results are best viewed in text-mode."
2016-09-02 (first published: 2014-12-12)
5,489 reads
This function is used to get the unused stored procedure list for which doesn't used for given noofdays.
2016-09-01 (first published: 2014-12-03)
3,351 reads
By ReviewMyDB
My T-SQL Tuesday #202 entry for Marlon Ribunal's invitation on memorable SQL Server outages....
A RAG pipeline that answers questions in the demo is not the same thing...
By Steve Jones
“A multitude of bad ideas is necessary for one good idea” – from Excellent...
Comments posted to this topic are about the item Adding new column with DEFAULT
I've got a web application for my side business. I've added a SQL Server...
Comments posted to this topic are about the item Looking for New Blood
Which number will the COUNT() return after executing the following statements:
DROP TABLE IF EXISTS #test; CREATE TABLE #test (id INT) INSERT INTO #test (id) SELECT * FROM GENERATE_SERIES(1, 3) AS gs ; ALTER TABLE #test ADD flag BIT CONSTRAINT DF_#test_flag DEFAULT 0; go UPDATE #test SET flag = 0 WHERE id = 1 UPDATE #test SET flag = 1 WHERE id = 2 INSERT INTO #test (id) VALUES (4) SELECT COUNT(*) FROM #test AS t WHERE flag = 0See possible answers