T-SQL

Technical Article

Correction to parsestring

  • Script

The original function fails when a mistaken split char is being snet to the function.This can easly be corrected by adding an if to check the value of the @holdpos inside the loop before sending it to the substring functionif the value is 0 then break the loop

You rated this post out of 5. Change rating

2005-02-23 (first published: )

108 reads

Technical Article

Script to return datetime as just date

  • Script

You can return the date as a string (varchar) in whatever date format you like by adding a 'style' to the CONVERT statement. Exmaples of style values are (two left hand columns):1 101 USA mm/dd/yy 2 102 ANSI yy.mm.dd 3 103 British/French dd/mm/yy 4 104 German dd.mm.yy 5 105 Italian dd-mm-yy 6 106 - dd […]

3.33 (3)

You rated this post out of 5. Change rating

2005-02-18 (first published: )

191 reads

Blogs

How Redgate Flyway Can Boost Your DevOps Journey

By

A brief introduction to the tool and its advantages for database migrations DevOps is...

Building a Docker image with Docker Build Cloud

By

In a previous blog post we went through how to build a Docker container...

Top 8 Courses to Learn SQL for Data Science in 2024 & Beyond

By

Businesses are drowning in data, but starving for insights. That's where SQL experts swoop...

Read the latest Blogs

Forums

SQL server native CDC

By SQL_Surfer

Have anyone implemented CDC, and if so, what has been your experience with it?...

Import and Export wizard stuck on Guest user

By Sam-263310

I'm getting a error when using the Import and Export wizard to copy tables...

Aligning Compatibility Version Strategy

By BOR15K

I have joined a new project, where the business uses Azure SQL Hyperscale for...

Visit the forum

Question of the Day

Initial Config of tempdb

What are the initial config sizes for the tempdb primary data files, secondary data files, and log files in SQL Server 2022?

See possible answers