Competition: What’s your favorite Redgate tool? Enter now.

INSERT INTO

0101101001011010 Posts: 9 Bronze 2
edited November 3, 2015 2:51AM in SQL Prompt
Is it possible to change the INSERT INTO XXXX to automatically place the colums in a line instead of a list?

FROM
[code]INSERT INTO	dbo.IAAMHeader
        (ProjectNumber
       , SimulationType
       , SimulationStart
       , SimulationEnd
       , Storativity
       , Transmissivity
       , ComparisonUID
       , sysDateCreated
       , sysAuthor
        )
VALUES  ( -- ProjectNumber
 -- SimulationType
 -- SimulationStart
 -- SimulationEnd
 -- Storativity
 -- Transmissivity
 -- ComparisonUID
 -- sysDateCreated
 -- sysAuthor
        )[/code]

[b]TO[/b]
[code]INSERT INTO	dbo.IAAMHeader(ProjectNumber, SimulationType, SimulationStart, SimulationEnd, Storativity, Transmissivity, ComparisonUID, sysDateCreated, sysAuthor)        )
	VALUES  ( -- ProjectNumber
	 -- SimulationType
	 -- SimulationStart
	 -- SimulationEnd
	 -- Storativity
	 -- Transmissivity
	 -- ComparisonUID
	 -- sysDateCreated
	 -- sysAuthor
			)

Comments

  • Hi,

    At the moment there's no way of setting up Prompt to automatically put the column list on a single line.

    As a workaround, select the columns block:

    u1mi56Z.png

    Press and release the Ctrl key to open up the actions list, and start typing unformat:

    FksGRjY.png

    Once you press enter, your columns will be on a single line:

    3jilewA.png

    Otherwise, please do submit a UserVoice request to have this happen automatically when the INSERT INTO ... is expanded.

    Best regards,

    David
Sign In or Register to comment.