Connect RedGate SQL Source Control to GIT

noob2016noob2016 Posts: 22 Bronze 3
So I have the following environments:
Desktop with SSMS and SQL Source Control installed
ServerA where GIT repository is created
ServerB where working directory will be.

I am hoping to create a connection from desktop --> serverB (scripts of database objects) --> serverA (added to GIT repository). I have not been able to set it up and not sure what I'm doing wrong.

Option 1:
These are the steps I took:
1. From my desktop, I have created a mapped Z drive to ServerB location (where the working directory will be).
2. Ran the GIT Gui on that folder and initialize (.git hidden folder created)
3. From desktop, click on database I want to add to SQL Source Control.
4. On the SQL Source Control tab, I click Setup menu.
5. I then choose Link to working folder and click Next
6. On the new window (Link to source control), working folder is chosen on the left panel. On the right panel, I tried to browse... to the Z drive folder that was created on Step 1; but, I can only choose local drive (C: and D: [which is a DVD drive]).

Question 1: Can I link to map drive? If so, how do I do it?

Option 2:
1. From my desktop, I have created a folder in my local directory (c:)
2. Ran the GIT Gui on that folder and initialize (.git hidden folder created)
3. From desktop, click on database I want to add to SQL Source Control.
4. On the SQL Source Control tab, I click Setup menu.
5. I chose Link to my source control system and click Next
6. I then choose Git in Choose your source control system page and click Next
7. I then browse to folder on local drive C: and click Link
At this point, everything looks to be successful. The database icon changed and the only object I have to test is blue and says "This table has changes to commit" when I hover over it.
8. I right click on the table object and choose Commit changes to source control
9. Here I got an error "sending files to source control server failed (see details above). Click to report this error" If I click on the error message, I get Error details as Command line hook failed.

I'm not really sure how to work this. Help?

Comments

  • Sergio RSergio R Posts: 610 Rose Gold 5
    Hi,

    I have logged a support ticket and will get in touch with you through that channel to troubleshoot this issue.

    Thank you,
    Sergio
    Product Support Engineer
    Redgate Software Ltd
    Please see our Help Center for detailed guides on how to use our tools
  • noob2016noob2016 Posts: 22 Bronze 3
    Thank you Sergio.
  • Sergio RSergio R Posts: 610 Rose Gold 5
    Regarding Option 1, the current version of SQL Source Control allows you to specify a mapped network drive as the location of the Working Folder, however in this case the user had mapped the drive with the account he had logged into Windows but was running SSMS under a different account.

    Regarding Option 2, this message is usually a result of the commit not having an associated comment
    Sergio
    Product Support Engineer
    Redgate Software Ltd
    Please see our Help Center for detailed guides on how to use our tools
  • KeanKean Posts: 3 New member
    edited March 6, 2020 8:43PM
    I'm encountering the same issue specified above in Option 1; however, I have confirmed that the account I am using to RDP into the Server is the same Login used to access SQL Server.  Is there any additional information about this issue of using a Mapped Network Drive?  I am currently running Source Control version: 7.1.10.10317

    To be more clear:
    I am trying to connect SQL Source Control to Git.  When I go to select a folder after choosing "Link to my source control system" the window just closes.  If I navigate to the parent folder (still on the mapped network drive) Source Control tells me "this folder is not a Git folder".  So that's confirmation that Source Control can in-fact see the mapped drive.  But when I go to the actual Repo Folder, it instantly closes and I don't have an option to move forward.
  • KeanKean Posts: 3 New member
    It appears as though uninstalling and re-installing SQL Source Control fixed this particular issue. ^
Sign In or Register to comment.