Getting rid of event log references to mssqllocaldb  Topic is solved

Discussions relating to plugin development, and the Jiwa API.

Getting rid of event log references to mssqllocaldb

Postby DannyC » Mon Feb 04, 2019 12:40 pm

Hi,

In the event log are several entries relating to the JiwDemo database on mssqllocaldb.
How can we get rid of those and any reference to JiwaDemo?

Jiwa event log.png
User avatar
DannyC
Senpai
Senpai
 
Posts: 638
Joined: Fri Mar 22, 2013 12:23 pm
Topics Solved: 30

Re: Getting rid of event log references to mssqllocaldb

Postby Mike.Sheen » Mon Feb 04, 2019 1:03 pm

That's odd.

When Jiwa.exe is first loaded, we read the JiwaConnections.xml from the users %appdata%\Roaming\Jiwa Financials\Jiwa 7\%version% folder.

If that file does not exist, we check to see if JiwaConnectionsTemplate.xml is present in the Program Files (x86)\Jiwa Financials\Jiwa 7 folder.

If that also does not exist, only then we will try creating a new JiwaConnections.xml and setting up a localdb database by copying JiwaDemo_Primary.mdf from the Program Files (x86)\Jiwa Financials\Jiwa 7\Data Files folder to the C:\Users\%username%\AppData\LocalMicrosoft\Microsoft SQL Server Local DB\Instances\mssqllocaldb folder.

The log entry you are seeing is the failure to copy to the C:\Users\%username%\AppData\LocalMicrosoft\Microsoft SQL Server Local DB\Instances\mssqllocaldb folder because the JiwaDemo_Primary.mdf file already there - but we check immediately before copying it to see if it is present - that's how we know whether to copy it or not.

It might be a permission issue on that file or folder - try manually copying the JiwaDemo_Primary.mdf file from the Program Files (x86)\Jiwa Financials\Jiwa 7\Data Files folder to the C:\Users\%username%\AppData\LocalMicrosoft\Microsoft SQL Server Local DB\Instances\mssqllocaldb folder - it might be enough to get it to skip the setting up of the localdb database.
Mike Sheen
Chief Software Engineer
Jiwa Financials

If I do answer your question to your satisfaction, please mark it as the post solving the topic so others with the same issue can readily identify the solution
User avatar
Mike.Sheen
Overflow Error
Overflow Error
 
Posts: 2445
Joined: Tue Feb 12, 2008 11:12 am
Location: Perth, Republic of Western Australia
Topics Solved: 757

Re: Getting rid of event log references to mssqllocaldb

Postby DannyC » Mon Feb 04, 2019 1:42 pm

Thanks.
We have different Windows accounts set up to run the plugin scheduler service (not running on Local System) and the REST API service.

As these Windows users are not really logging into the Jiwa GUI, I gather based on the information you've provided that I should log into the Jiwa GUI and create a connection to their live Jiwa database. This'll create the JiwaConnections.XML file.
I can also see that the JiwaDemo_Primary.MDF and log file are already in their mssqllocaldb folder.

So if I create a connection for each Windows user i.e. to create a JiwaConnections.XML file, can I then delete the JiwaDemo_Primary database files from the profile? I'd like to free up 190Mb for each user who doesn't need the mssqllocaldb database.

cheers
User avatar
DannyC
Senpai
Senpai
 
Posts: 638
Joined: Fri Mar 22, 2013 12:23 pm
Topics Solved: 30

Re: Getting rid of event log references to mssqllocaldb  Topic is solved

Postby Mike.Sheen » Mon Feb 04, 2019 1:57 pm

DannyC wrote:So if I create a connection for each Windows user i.e. to create a JiwaConnections.XML file, can I then delete the JiwaDemo_Primary database files from the profile? I'd like to free up 190Mb for each user who doesn't need the mssqllocaldb database.


Yes - if the JiwaConnections.xml is there, we'll not try to copy the JiwaDemo_Primary.mdf.
Mike Sheen
Chief Software Engineer
Jiwa Financials

If I do answer your question to your satisfaction, please mark it as the post solving the topic so others with the same issue can readily identify the solution
User avatar
Mike.Sheen
Overflow Error
Overflow Error
 
Posts: 2445
Joined: Tue Feb 12, 2008 11:12 am
Location: Perth, Republic of Western Australia
Topics Solved: 757


Return to Technical and or Programming

Who is online

Users browsing this forum: No registered users and 2 guests