Okay so I reinstalled my PC a month ago and decided to get back to my api project. When I tried to run it, it gave me an error.

unable to open tcp connection with host 'localhost:1433': dial tcp [::1]:1433: connectex: No connection could be made because the target machine actively refused it.

which I don't understand why it's giving me this, I'm using MSSQL, I have it installed, I checked the database name, created the same database etc.

For context, I think these are the files that are most relevant

package main import ( "database/sql" "log" _ "github.com/denisenkom/go-mssqldb" "github.com/myGit/testGoApi/cmd/api" "github.com/myGit/testGoApi/db" ) fun...

Similar Posts

Loading similar posts...

Keyboard Shortcuts

Navigation
Next / previous item
j/k
Open post
oorEnter
Preview post
v
Post Actions
Love post
a
Like post
l
Dislike post
d
Undo reaction
u
Recommendations
Add interest / feed
Enter
Not interested
x
Go to
Home
gh
Interests
gi
Feeds
gf
Likes
gl
History
gy
Changelog
gc
Settings
gs
Browse
gb
Search
/
General
Show this help
?
Submit feedback
!
Close modal / unfocus
Esc

Press ? anytime to show this help