Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

When generating a script for the object of stored procedure or function, one extra empty line is added to the end of definition. #43

Closed
AlexeyKasjanov opened this issue Nov 3, 2015 · 2 comments

Comments

@AlexeyKasjanov
Copy link

If a single script for a stored procedure or function, obtained by SchemaZen, perform on the database by the utility sqlcmd -i (after removing the existing object from the database), and then again get it via SchemaZen, the new version of the script will be different from the old version one empty line, although no manual modifications to the script file was not fulfilled.
It seems the new line is added to the definition of the object after it is created from a script by sqlcmd -i. Because the line with the following GO written to the definition as a carriage return.

@AlexeyKasjanov AlexeyKasjanov changed the title When generating a script for the object of stored procedure or function, one extra empty line is added to the end of script. When generating a script for the object of stored procedure or function, one extra empty line is added to the end of definition. Nov 3, 2015
@rmarskell
Copy link

I've also noticed similar issues with extra new lines being add to the beginning and end of scripts. Perhaps you could parse it to remove all newlines between the "GO" & the first proc line, and the last proc statement & the following "GO" statement.

@sethreno
Copy link
Owner

sethreno commented Mar 13, 2017

# for free to join this conversation on GitHub. Already have an account? # to comment
Projects
None yet
Development

No branches or pull requests

3 participants