Is it possible to have a "post Get latest" script?

After doing a "Get latest" on my local database, I would like to run a tool that generates code from my updated database.

Is there functionality for a post "Get latest" script? Or executing a batch or something to that extent?

Best Answer

Answers

  • Thanks for your response. The post script I'm hoping to execute is not for deployment, but solely for development, but I'll have to look into the options there; maybe that will be viable.
  • You're welcome! if you have any other issues or questions please don't hesitate to contact us at support!

    Kind regards

    Dan Calver | Redgate Software
    Have you visited our 
    Help Center?

  • Thanks for your response. The post script I'm hoping to execute is not for deployment, but solely for development, but I'll have to look into the options there; maybe that will be viable.
    @Louis_Gigantisch - Out of interest, what is your post script doing? Knowing this would help us suggest a solution. One option that springs to mind is trying to use xp_cmdshell in a post-deployment script.

    David Atkinson
    Product Manager
    Redgate Software
  • We have an ASP.NET project that generates code from the database using SQLMetal. Currently, we run SQLMetal on every project build, but ideally it only runs when the database has changed. Running it only after every "Get latest" would be preferable.
  • We have an ASP.NET project that generates code from the database using SQLMetal. Currently, we run SQLMetal on every project build, but ideally it only runs when the database has changed. Running it only after every "Get latest" would be preferable.
    I see. The only option I can think of is if you create a batch file and use the SQL Compare command line instead of the built in "get latest" feature. This way you can configure the SQLMetal command to run afterwards.
    David Atkinson
    Product Manager
    Redgate Software
Sign In or Register to comment.