-
Notifications
You must be signed in to change notification settings - Fork 44
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Keep saying Module not found of sqlserverv8 #294
Comments
I am also seeing this, the issue began when I upgraded Node to LTS (18.16.1). I got it to work by going into /lib/util.js and changing the require path for |
Not work for me. It gives me same error of Module not found: Can't resolve '../build/Release/sqlserverv8' |
It didn't work for me either. I can even delete the util.js file, change whatever inside it, clean npm cache and it still fail to compile with same error. is there any other cache I should clean? |
what is the right approach after successfully npm install? I think docs are too much information and misleading too |
looks similar to this issue which can be fixed as described |
https://github.com/TimelordUK/node-sqlserver-v8/releases look at release notes this should now sort out NextJS based problems |
I installed this lib with setting NODE_TLS_REJECT_UNAUTHORIZED with 0.
But when I call it, it says:
./node_modules/msnodesqlv8/lib/util.js:5:20 Module not found: Can't resolve '../build/Release/sqlserverv8'
I ensure the sqlserverv8.node exist inside the node_modules.
But it just keep saying module not found.
I'm using it in a next.js web application and here is my code:
`import sql from "mssql/msnodesqlv8";
const conn = new sql.connect(
{
database: "db_name",
server: "1.1.1.1",
driver: "msnodesqlv8",
options: {
encrypt: false,
trustedConnection: true,
},
},
(err) => {
if (err) {
console.log(
Error while connecting database: ,${err}
);} else {
console.log(
connected to database
);}
}
);
export { conn };
`
The text was updated successfully, but these errors were encountered: