Thursday, March 22, 2012

Errors in Connecting to SQL Server Compact 3.4 ?

Hi everyone,
First, let me apologize for the cross-post. I was really at a loss for the
proper group.
I'm using Visual Studio 2008 with a SQL Server Compact 3.5 database.
Using the VS 2008 "Server Explorer", I wish to add an index on a column in
my database. I right-click on the table name and select "Table Properties".
This gives me an error:
"Index out of range. Must be non-negative and less than the size of the
collection. Parameter name: index".
I included a screenshot of the dialog window (e1.jpg).
Since that didn't work I tried to right-click on the table name and select
"Edit Table Schema". This gives me an error:
"The database file is larger than the configured maximum database size. This
setting takes effect on the first concurrent connection only. [Required Max
Database Size (in MB; 0 if unknown) = 0]".
I included a screenshot of the dialog window (e2.jpg).
The connection string for this database has an entry, "Max Database
Size=4091" and the size of the physical size of the file is 322 MB.
So, at this point I am getting these weird errors that are preventing me
from administering the SQL Server Compact DB.
Any help would be greatly appreciated.
Tom
Tom,
Have you tried selecting the database in VS 2008 Data Connections, then
right-click and select Modify Connection, then click the Advanced button to
change the Max Database Size?
Ginny Caughey
Device Application Development MVP
"Tom Baxter" <tlbaxter99@.yahoo.com> wrote in message
news:OIQfX7OQIHA.748@.TK2MSFTNGP04.phx.gbl...
> Hi everyone,
> First, let me apologize for the cross-post. I was really at a loss for the
> proper group.
> I'm using Visual Studio 2008 with a SQL Server Compact 3.5 database.
> Using the VS 2008 "Server Explorer", I wish to add an index on a column in
> my database. I right-click on the table name and select "Table
> Properties". This gives me an error:
> "Index out of range. Must be non-negative and less than the size of the
> collection. Parameter name: index".
> I included a screenshot of the dialog window (e1.jpg).
> Since that didn't work I tried to right-click on the table name and select
> "Edit Table Schema". This gives me an error:
> "The database file is larger than the configured maximum database size.
> This setting takes effect on the first concurrent connection only.
> [Required Max Database Size (in MB; 0 if unknown) = 0]".
> I included a screenshot of the dialog window (e2.jpg).
> The connection string for this database has an entry, "Max Database
> Size=4091" and the size of the physical size of the file is 322 MB.
> So, at this point I am getting these weird errors that are preventing me
> from administering the SQL Server Compact DB.
> Any help would be greatly appreciated.
> Tom
>
>
|||Yes, I've done that. (When you say, "Data Connections" I assume you mean the
"Data Connections" node in Server Explorer.)
My "Max Database Size" is listed as 4091.
"Ginny Caughey [MVP]" <ginny.caughey.online@.wasteworks.com> wrote in message
news:OTAhvKPQIHA.5524@.TK2MSFTNGP05.phx.gbl...
> Tom,
> Have you tried selecting the database in VS 2008 Data Connections, then
> right-click and select Modify Connection, then click the Advanced button
> to change the Max Database Size?
> --
> Ginny Caughey
> Device Application Development MVP
>
> "Tom Baxter" <tlbaxter99@.yahoo.com> wrote in message
> news:OIQfX7OQIHA.748@.TK2MSFTNGP04.phx.gbl...
>
|||Tom,
Are you not able to change the Max Database Size from there? I was able to
change the Max Database Size for one of my SSC 3.5 files, but it wasn't a
big one like yours is.
Ginny Caughey
Device Application Development MVP
"Tom Baxter" <tlbaxter99@.yahoo.com> wrote in message
news:%23rJshqYQIHA.1164@.TK2MSFTNGP02.phx.gbl...
> Yes, I've done that. (When you say, "Data Connections" I assume you mean
> the "Data Connections" node in Server Explorer.)
> My "Max Database Size" is listed as 4091.
>
> "Ginny Caughey [MVP]" <ginny.caughey.online@.wasteworks.com> wrote in
> message news:OTAhvKPQIHA.5524@.TK2MSFTNGP05.phx.gbl...
>
|||Yes, I *AM* able to change the Max Database Size there but it's already at
the maximum allowed (4091).
I still get the errors, even though the database appears to be configured
for its maximum size.
"Ginny Caughey [MVP]" <ginny.caughey.online@.wasteworks.com> wrote in message
news:A4BBC5A2-7626-42D8-B430-B560CB8C9648@.microsoft.com...
> Tom,
> Are you not able to change the Max Database Size from there? I was able to
> change the Max Database Size for one of my SSC 3.5 files, but it wasn't a
> big one like yours is.
> --
> Ginny Caughey
> Device Application Development MVP
>
> "Tom Baxter" <tlbaxter99@.yahoo.com> wrote in message
> news:%23rJshqYQIHA.1164@.TK2MSFTNGP02.phx.gbl...
>
|||Tom,
Yes it looks like you're right as the max size is supposed to represent
megabytes. Are you able to open the big database programmaticlly?
Ginny Caughey
Device Application Development MVP
"Tom Baxter" <tlbaxter99@.yahoo.com> wrote in message
news:ObL5RWcQIHA.5264@.TK2MSFTNGP02.phx.gbl...
> Yes, I *AM* able to change the Max Database Size there but it's already at
> the maximum allowed (4091).
> I still get the errors, even though the database appears to be configured
> for its maximum size.
>
>
> "Ginny Caughey [MVP]" <ginny.caughey.online@.wasteworks.com> wrote in
> message news:A4BBC5A2-7626-42D8-B430-B560CB8C9648@.microsoft.com...
>
|||Yes, Ginny, I am able to open the database programatically and I am able to
add records to it. The actual database size is only 322 MB.
It's a pretty simple situation. If you are really interested, send me a
private email and I will set up the file on an FTP server and maybe you can
look at it. If you really want to, my email is tlbaxter99 <at> Yahoo ~DOT~
com.
"Ginny Caughey [MVP]" <ginny.caughey.online@.wasteworks.com> wrote in message
news:44BF83D8-3C7D-4107-9546-21ABFDEFB860@.microsoft.com...
> Tom,
> Yes it looks like you're right as the max size is supposed to represent
> megabytes. Are you able to open the big database programmaticlly?
> --
> Ginny Caughey
> Device Application Development MVP
>
> "Tom Baxter" <tlbaxter99@.yahoo.com> wrote in message
> news:ObL5RWcQIHA.5264@.TK2MSFTNGP02.phx.gbl...
>
|||Tom, please see your email.
Ginny Caughey
Device Application Development MVP
"Tom Baxter" <tlbaxter99@.yahoo.com> wrote in message
news:O2pisxlQIHA.4712@.TK2MSFTNGP04.phx.gbl...
> Yes, Ginny, I am able to open the database programatically and I am able
> to add records to it. The actual database size is only 322 MB.
> It's a pretty simple situation. If you are really interested, send me a
> private email and I will set up the file on an FTP server and maybe you
> can look at it. If you really want to, my email is tlbaxter99 <at> Yahoo
> ~DOT~ com.
>
>
> "Ginny Caughey [MVP]" <ginny.caughey.online@.wasteworks.com> wrote in
> message news:44BF83D8-3C7D-4107-9546-21ABFDEFB860@.microsoft.com...
>
|||Tom Baxter wrote:

> I included a screenshot of the dialog window (e2.jpg).
Side note: this is an old no-no in Usenet (except for groups
with "binaries" in the name, and a handful of self-identified
exceptions). At least these weren't too big, but they eat
resources on every server carrying these groups (from whose
perspective Usenet is a push medium). The preferred alternative
is to either type it up (when practical, as would've been here),
or post the files somewhere else (e.g. web server, binaries group)
and then post a link here.
|||Tom,
Thanks for emailing me a download link to your big database. I was able to
reproduce your problem, but I was also able to work around it and
successfully connect to the database using VS 2008 by chaning the Connect
Timeout value to 500 from the default 30.
Ginny Caughey
Device Application Development MVP
"Tom Baxter" <tlbaxter99@.yahoo.com> wrote in message
news:O2pisxlQIHA.4712@.TK2MSFTNGP04.phx.gbl...
> Yes, Ginny, I am able to open the database programatically and I am able
> to add records to it. The actual database size is only 322 MB.
> It's a pretty simple situation. If you are really interested, send me a
> private email and I will set up the file on an FTP server and maybe you
> can look at it. If you really want to, my email is tlbaxter99 <at> Yahoo
> ~DOT~ com.
>
>
> "Ginny Caughey [MVP]" <ginny.caughey.online@.wasteworks.com> wrote in
> message news:44BF83D8-3C7D-4107-9546-21ABFDEFB860@.microsoft.com...
>

No comments:

Post a Comment