Skip to content

Instantly share code, notes, and snippets.

@csdear
Created March 7, 2016 15:01
Show Gist options
  • Select an option

  • Save csdear/0a06ad94cbf2aaf64fb1 to your computer and use it in GitHub Desktop.

Select an option

Save csdear/0a06ad94cbf2aaf64fb1 to your computer and use it in GitHub Desktop.
CREATE TABLE
-- e.g., on a charge status table.
-- There mighte be a more effective bespoke way to do this in SSMS, as explicitly naming the
-- datatypes could be risky. Right clicking 'New Table' in SSMS perhaps...
-- the following creates a table 'charge_status'
-- columns arranged are charge_status_id cc_processor_invoice_id and success
-- charge_status_it is designated as the primary key.
-- it is a CLUSTERED index.
CREATE TABLE [dbo].[charge_status] (
[charge_status_id] INT IDENTITY (1, 1) NOT NULL,
[cc_processor_invoice_id] VARCHAR (64) NOT NULL,
[success] BIT NOT NULL,
PRIMARY KEY CLUSTERED ([charge_status_id] ASC)
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment