Source Control says it needs to push. Git says up to date

Dacius12Dacius12 Posts: 1 New member
edited November 30, 2021 9:58PM in SQL Source Control
We have a Git Repo that houses our SQL database source control. We use the RedGate tool to check in all of our objects and manage drift between our Git and Database. it is a very active repo with hundreds of changes a month. Every once in a while we will experience an issue with RedGate SSC program where is says I have a Push to make. When I click the Push Button is says. 

<div>Unable to push. This may be because a reference that you are trying to update on the remote contains commits that are not present locally. Try to pull from the Get Latest tab and try again.</div><div>To https://<ForkedversionofdatabaseRepo>.git</div><div>&nbsp;! [rejected]&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; master -> master (non-fast-forward)</div><div>error: failed to push some refs to '<Repo Location>'</div><div>hint: Updates were rejected because the tip of your current branch is behind</div><div>hint: its remote counterpart. Integrate the remote changes (e.g.</div><div>hint: 'git pull ...') before pushing again.</div><div>hint: See the 'Note about fast-forwards' in 'git push --help' for details.</div>
When I run a git status in command prompt it says the repo is up to date. Working tree is clean. When I pull and push from fork and upstream it says no changes. In git, it says my fork is up to date with the master.

I have tried dropping the local and re-cloning
I have tried deleting my fork and re-forking. 

Answers

  • Hello @Dacius12

    Sorry you're having trouble with SQL Source Control. Can you please try unlinking the database from source control, delete the content in the caches folder located in %localappdata%\Red Gate\SQL Source Control 7\Caches, then relink the database to source control and confirm if anything changes?

    Also, what happens if you first do a pull from the Get Latest tab then try to do a commit?

    Kind regards,

    Pete Ruiz

Sign In or Register to comment.