SQL Max Size database?

Discussion of application development using iX Developer, including but not limited to getting started, using the functions tab, properties, objects and installation.
Post Reply
jcjelektro
Posts: 40
Joined: Tue Nov 22, 2011 3:54 am
Location: Gjerlev, Denmark
Contact:

SQL Max Size database?

Post by jcjelektro »

Hello

I have a problem with the SQL database.
Now it's grown to 256MB, and when i want to export a datalogger, the IX software crash.

How can i fix that problem?

Can i change the max size of the database?

I have deleted/renamed the database, and then it made a new file, but i have "lost" my data.

In IX 1.31, dataloggers were made seperate instead off combined in the database. It worked better i think.

I'm running a C2D box pc, with IX2.0 Runtime.

- Emil Gundersen
JCJelektro.dk


From Log file:

2012-09-26 09:49:50,218 [5] ERROR Neo.ApplicationFramework.Tools.Database.DatabaseServiceCF [(null)] - Connect to database failed.
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) = 0 ]
2012-09-26 09:49:50,218 [5] ERROR Neo.ApplicationFramework.Tools.Database.DatabaseServiceCF [(null)] - With SqlCeErrors:
2012-09-26 09:49:50,218 [5] ERROR Neo.ApplicationFramework.Tools.Database.DatabaseServiceCF [(null)] - System.Data.SqlServerCe.SqlCeError: 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) = 0 ]
2012-09-26 09:49:50,234 [5] FATAL Neo.ApplicationFramework.Common.Runtime.GlobalsBase [(null)] - Unhandled Exception causing shutdown.
System.InvalidOperationException: ExecuteReader: Connection property has not been initialized.
at System.Data.SqlServerCe.SqlCeCommand.ValidateCommand(String method)
at System.Data.SqlServerCe.SqlCeCommand.ExecuteCommand(CommandBehavior behavior, String method, ResultSetOptions options)
at System.Data.SqlServerCe.SqlCeCommand.ExecuteReader(CommandBehavior behavior)
at Neo.ApplicationFramework.Tools.Database.DatabaseServiceCF.t(IDatabaseData A_0, String A_1)
at Neo.ApplicationFramework.Tools.Database.DatabaseServiceCF.m(IDatabaseData A_0)
at Neo.ApplicationFramework.Tools.Database.DatabaseServiceCF.DatabaseExportToCSV(Object parameters)
at System.Threading.QueueUserWorkItemCallback.WaitCallback_Context(Object state)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean ignoreSyncCtx)
at System.Threading.QueueUserWorkItemCallback.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem()
at System.Threading.ThreadPoolWorkQueue.Dispatch()
at System.Threading._ThreadPoolWaitCallback.PerformWaitCallback()
--
Emil Gundersen
JCJelektro.dk

mark.monroe
Posts: 824
Joined: Tue Mar 13, 2012 9:53 am

Re: SQL Max Size database?

Post by mark.monroe »

We have been able to reproduce the problem. The max database size is supposed to be 4 GB, which is the max size that SQL mobile allows.
Best Regards,
Mark Monroe

Beijer Electronics, Inc. | Applications Engineer

jcjelektro
Posts: 40
Joined: Tue Nov 22, 2011 3:54 am
Location: Gjerlev, Denmark
Contact:

Re: SQL Max Size database?

Post by jcjelektro »

Hello Again

The biggest problem is i have lost som data from 4-5day's. :-(
I can't open the database file with SQL Viewer programs, they all close and say that the database is at it's max size, and then closes.

I suggest that the dataloggers can be stored in seperate files like in IX1.31

- Emil
--
Emil Gundersen
JCJelektro.dk

mark.monroe
Posts: 824
Joined: Tue Mar 13, 2012 9:53 am

Re: SQL Max Size database?

Post by mark.monroe »

You should be able to open the database using a Database viewer application. From what I understand the max size is determined via the connection string when you connect to the database.

If the database viewer sends a connection string with a larger database size value, then you should be able to open it up. You can check to see how the viewers you are using connect to the database and whether you can modify the connection string. If they just use the default database size in the connection string, then they will not be able to open any database larger that 256 MB.

Version 1.31 stored the data in a database as well, you will end up with the same issue whether each datalogger has its own database or whether all are in the same database. It all depends on how much data you are saving.
Best Regards,
Mark Monroe

Beijer Electronics, Inc. | Applications Engineer

mark.monroe
Posts: 824
Joined: Tue Mar 13, 2012 9:53 am

Re: SQL Max Size database?

Post by mark.monroe »

This has been fixed and will be included in the next iX Developer release. You will still need to change the connection string to the database in your script as mention in the above post.
Best Regards,
Mark Monroe

Beijer Electronics, Inc. | Applications Engineer

jcjelektro
Posts: 40
Joined: Tue Nov 22, 2011 3:54 am
Location: Gjerlev, Denmark
Contact:

Re: SQL Max Size database?

Post by jcjelektro »

Hello Again

I don't know to change the connection string?
If i try to open the database file with Database viewer from Beijer, it wont.
I have tried 2 other programs with the same result.?

- Emil
--
Emil Gundersen
JCJelektro.dk

mark.monroe
Posts: 824
Joined: Tue Mar 13, 2012 9:53 am

Re: SQL Max Size database?

Post by mark.monroe »

When you connect to a database you use a connection string. That connection string has parameters that tell it the max size of the database. In a prior post to this thread I posted a URL that tells you about this. The Beijer database viewer doesn't allow you to change this connection string.

The fix needed in iX Developer has not yet been released. Until that is released, you will not be able to open large databases regardless of whether or not you change the connection string.
Best Regards,
Mark Monroe

Beijer Electronics, Inc. | Applications Engineer

Post Reply