News:

Plan-G has over 1700 followers on FACEBOOK! Click HERE and add your support

Main Menu
Menu

Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Show posts Menu

Messages - Highflyer525

#1
Plan-G / Re: Error building database
October 18, 2019, 07:46:10 AM
Hi Grimm, Tim,

The duplicated value problem happened to me once. Mine also failed to clear the database down first with the following error:

DeleteExistingData: System.IO.IOException: The process cannot access the file 'D:\Plan-G Files\Data\PlanG3_XPX.sdf' because it is being used by another process.

Turns out the other process was a previously started version of Plan-G that was still holing on in the background. It could be seen in task manager, but had moved down from Apps to background processes (in Windows 10 task manager that is) whilst it was trying to close down.

Once I'd terminated this instance with end task and started Plan-G again, all was well and it cleared the DB down the next time.

Just a one off.
#2
Hi Tim,

Just in case it didn't reach you for whatever reason, I did reply. :)

Cheers,

Mark.
#3
Hi Tim,

Hope you're well.

Just started to use your excellent application when I hit the 'The database file is larger than the configured maximum database size. This setting takes effect on the first concurrent database connection only. [ Required Max Database Size (in MB; 0 if unknown) = 257 ]' error.

I've looked around on your forum and I can see it's been lurking for a few years and you've not been able to reproduce it at your end so a bit of a nightmare to fix.

I've had a sniff around to see if I could help with what's going on from another developers perspective, to be your hands an eyes as this happens to both of my computers, the common denominator being the size of my X-Plane install.

After having a little play I'm pretty sure that;


  • It's a .NET EF app
  • It's using SQL CE (Compact Edition) as the back end
  • It's not using the Connection Strings in the App.config, maybe these are historic, so assuming it's using hard coded connection string in the app.

Having worked with it as well in the past I know 3.5 has a default limit of 256MB if the connection string doesn't stipulate a size. When I parse the X-Plane data, I watch the SDF file grow and sure enough it stops dead on 256MB half way through Airways in my particular instance. It also states the disk space as a secondary issue, but I think this is a red herring, it's referring to the disk space within the DB and not on the drive it resides.

Because it's not using the Connection Strings in the app.config (I think) it's ignoring your <parameter value="Max Database Size=4000"/> statement which is exactly what's needed to override the limit.

Would you mind if I suggest something? Would you be able to add the Max Database Size=4000 statement to the end of the Connection Strings within your code so it reads:

metadata=res://*/Data.FSData.csdl|res://*/Data.FSData.ssdl|res://*/Data.FSData.msl;provider=System.Data.SqlServerCe.3.5;provider connection string='Data Source=|DataDirectory|\Data\PlanG3_XPX.sdf';Max Database Size=4000

Hope you don't mind me chipping in like this, I'd just like to get it working but I'm obviously limited to what I can do. I'm pretty sure this will fix it.

If you want to PM me a private link with a temporary Beta version that I can test for you, that's no problem at all. Glad to help.

Cheers,

Mark.