Technical Article

Find possible missing foreign key relationships

This procedure is intended for single column primary key relationships.First we will create two table functions. The first finds a list of all tables with their primary key columns. The second finds all existing foreign key relationships with their table and column names. Finally we find all tables with primary key column names that do […]

5 (2)

2007-02-26 (first published: )

815 reads

Technical Article

Date String format with optional Timestamp

I find it so annoying to format dates. Sometimes I want to include the timestamp, but if it is a midnight time stamp, the time is irrelevant. Sending in a datetime will return either the date string or a date string with a timestamp up to the seconds with either AM or PM.

5 (1)

2007-01-02 (first published: )

163 reads

Blogs

Why You Need Presentation Skills

By

And no, the answer is not because you want to be a Microsoft MVP....

Daily Coping 29 Sep 2022

By

Today’s coping tip is to avoid saying “I should” and make time to do...

How to Calculate Compound Rate in Power BI

By

Recently I had an interesting use case where I had to a compound calculation...

Read the latest Blogs

Forums

TCP Provider: A connection attempt failed for target server

By SQL Galaxy

Hi. In source SQL Instance target linked server has been created and connection tested...

Get Part number and display in Header

By Siten0308

Hello, so I have a part number, and I want to display it in...

BlobColumn to String

By yukinonon

I have this column in sql server that has value of "dog,cat,mouse" so I...

Visit the forum

Ask SSC Logo Ask SSC

SQL Server Q&A from the SQLServerCentral community

Get answers