views:

152

answers:

7
+1  Q: 

C# and Access 2000

I have developed an network application that is in use in my company for last few years. At start it was managing information about users, rights etc. Over the time it grew with other functionality. It grew to the point that I have tables with, let's say 10-20 columns and even 20,000 - 40,000 records.

I keep hearing that Access in not good for multi-user environments. Second thing is the fact that when I try to read some records from the table over the network, the whole table has to be pulled to the client. It happens because there is no database engine on the server side and data filtering is done on the client side.

I would migrate this project to the SQL Server but unfortunately it cannot be done in this case.

I was wondering if there is more reliable solution for me than using Access Database and still stay with a single-file database system.

We have quite huge system using dBase IV. As far as I know it is fully multiuser database system.

Maybe it will be good to use it instead of Access? What makes me not sure is the fact that dBase IV is much older than Access 2000. I am not sure if it would be a good solution.

Maybe there are some other options?

A: 

Access is not a flat file database system! It's a relational database system.

John Saunders
Ok. I get what you talking about. I meant that it doesn't have an engine like SQL Server, Oracle etc...
aristo
I think he means single file ie one mdb file. Same way sqlite and sql anywhere are single file databases.
Aaron Fischer
But it's hardly a 'real' database system.
Henk Holterman
It's certainly a "real" database system. It just doesn't have a central server. It also has all the Form and Report ... stuff built into it, which distracts from the fact that there's actually a database in there.
John Saunders
John, I should have put a smiley in that comment. But people should be aware that there are stability and scalability issues with (all) shared-file databases.
Henk Holterman
@Downvoter: what's the problem?
John Saunders
A: 

You can't use SQL Server Express? Otherwise, MySQL is a good database.

But if you can't install ANYTHING (you should get into those politics sooner rather than later -- or it WILL be later), just use you existing database system.

Basically with Access, it cannot handle more than 5 people connected at the same time, or it will corrupt on you.

Chris Brandsma
I cannot install any software on this network.
aristo
You should ask to be able to, especially if it is being used and is important.
Callum Rogers
I think this same. But unfortuantely it won't work. There is a lot of politics about it which is not fully understood for me. At the end of the day there is nothing which can be installed on the network. One way is use something which you can just copy and run...
aristo
Remember he has multiple users accessing the database from different systems. If he replaces his database with a server-based database, even Express, then the server has to be located centrally and the users would then talk to the server.
John Saunders
I have a number of clients running 20 to 25 users in Access all day long with very few problems.
Tony Toews
Congratulations. You are beating the odds.
Chris Brandsma
Chris, I assume your comment was meant for me. If so one reason might be that my clients are running very good quality networks.
Tony Toews
@Tony, typically the issue is when two people make changes to the same table at the same time. Network errors and excessive latency can also cause errors. If your users are using the database at different times, or modifying different tables in the database, you could be ok. In one case I worked on the same access database was used across branches that were 1000 miles apart. The Access corrupted weekly there. In case others are reading, here is a Microsoft article on how to avoid corruption issues: http://support.microsoft.com/kb/300216/
Chris Brandsma
@Tony: "I have a number of clients running 20 to 25 users in Access" -- this is the one you recommended be ported to SQL Server, right?
onedaywhen
+3  A: 

You may wish to read this informative thread about Access: http://stackoverflow.com/questions/763888/is-ms-access-jet-suitable-for-multiuser-access

Remou
thanks for that link. It was useful. Upvote from me well deserved...
aristo
+1  A: 

The problems you experience with an Access Database shared amongst your users will be the same with any file based database.
A read will pull a lot of data into memory and writes are guarded with some type of file lock. Under your environment it sounds like you are going to have to make the best of what you have.

Aaron Fischer
Thanks for answer. I was asking about dBase IV as well because in our case it manages around 300-500 updates and inserts per hour non stop done by 20-30 network users. It sounds realiable for me. I have heard more bad things about Access on the other hand. I have heard even that it is not good for more than 1 user from quite known people as Carl Franklin on DotNetRocks for example.
aristo
It comes down to write collisions. The only corrupt access db I have dealt with is one that had a form ui we shared in an office. On the other had as a db I have access databases that support several people with out much trouble.
Aaron Fischer
Carl Franklin, tends to entertain and exaggerate slightly. And Most people like to bash Access.
Aaron Fischer
that's fantastic to know. I haven't noticed anything bad yet either. Maybe because I have used it as a back end only - as you've mentioned. I was just scared a bit by the fact that it grows quickly.I didn't wanted to face a fact that it reached some "limits" and put me into some trouble.
aristo
+4  A: 

If you're having problems with your Jet/ACE back end with the number of records you mentioned, it sounds like you have schema design problems or an inefficiently-structured application.

As I said in my comment to your original question, Jet does not retrieve full tables. This is a myth propagated by people who don't have a clue what they are talking about. If you have appropriate indexes, only the index pages will be requested from the file server (and then, only those pages needed to satisfy your criteria), and then the only data pages retrieved will be those that have the records that match the criteria in your request.

So, you should look at your indexing if you're seeing full table scans.

You don't mention your user population. If it's over 25 or so, you probably would benefit from upsizing your back end, especially if you're already comfortable with SQL Server.

But the problem you described for such tiny tables indicates a design error somewhere, either in your schema or in your application.

FWIW, I've had Access apps with Jet back ends with 100s of thousands of records in multiple tables, used by a dozen simultaneous users adding and updating records, and response time retrieving individual records and small data sets was nearly instantaneous (except for a few complex operations like checking newly entered records for duplication against existing data -- that's slower because it uses lots of LIKE comparisons and evaluation of expressions for comparison). What you're experiencing, while not an Access front end, is not commensurate with my long experience with Jet databases of all sizes.

David-W-Fenton
Thank you for that. You mentioned that not the whole table is pulled to the client side. This is something new for me and this same fantastic news. Would you be able to point me to some source which explain Access Databases more in details???
aristo
Second thing I wanted to mention is that I haven't wrote enywhere that I experience problems with my application. I actually don't. It works fine. One thing I was worry about is the fact that it grows quicker that I thought. I just don't know when it'll reach its limits...Thank you for pointing for indexes. If it is true what you say it seems critical important to have good designed indexes.ReagrdsMariusz
aristo
The unfortunate thing about the documentation for how the Jet database engine works is that the Jet Database Engine Developers Guide has never been put online, and was never updated for Jet 4.0. I have the hard copy of the Jet 3.5 version, the last one published, and it's full of things found nowhere else that I know of.
David-W-Fenton
Thank you. I will lookup for a hard copy as well. Thank you again for all that.
aristo
+2  A: 

For the record this answer is copied/edited from another question I answered.


Aristo,

You CAN use Access as your centralized data store.

It is simply NOT TRUE that access will choke in multi-user scenarios--at least up to 15-20 users.

It IS true that you need a good backup strategy with the Access data file. But last I checked you need a good backup strategy with SQL Server, too. (With the very important caveat that SQL Server can do "hot" backups but not Access.)

So...you CAN use access as your data store. Then if you can get beyond the company politics controlling your network, perhaps then you could begin moving toward upfitting your current application to use SQL Server.

I recently answered another question on how to split your database into two files. Here is the link. http://stackoverflow.com/questions/1147702/rookie-ms-access-creating-the-front-end-mde/1147858#1147858

Splitting your database file into front end : back end is sort of a key to making it more performant. (Assume, as David Fenton mentioned, that you have a reasonably good design.)

If I may mention one last thing...it is ridiculous that your company won't give you other deployment options. Surely there is someone there with some power who you can get to "imagine life without your application." I am just wondering if you have more power than you might realize.

Seth

Seth Spearman
Thank you for that.I won't comment on my company's politics because it is really radiculous. The thing is that the company I work for is not strictly IT related and consists of seven separate companies. At the end of the day they are one big corporation but some of their let's say "branches" networks are controlled by some external firms; and here is a problem because they have "standards" and don't allow certain things.
aristo
It would be probable difficult to explain really clearly because I myself don't get all this stuff very well either. Just wanted to put a bit light on how things can be twisted sometimes.The second thing is that I work among IT Pros but I am only developer up there. Rest of the people I work with don't have a clue about what I do. They see only ready products when done. They don't really get "development" requirements either and think that if it is possible to do it without paying few thousands for Sql Server that's exactly what we going to do.
aristo
There are pros of this kind of environment as well. One of them is that nobody is telling me how I supposed to do my work. (excluding cases as the one we talk about :-)Anyway, Live is going on and I have to live with Jet DB at the moment... Will try to learn more about Jet...
aristo
+1  A: 

"Second thing is the fact that when I try to read some records from the table over the network, the whole table has to be pulled to the client. "

Actually no. This is a common misstatement spread by folks who do not understand the nature of how Jet, the database engine inside Access, works. Pulling down all the records, or excessive number of records, happens because you don't have all the fields used in the selection criteria or sorting in the index. We've also found that indexing yes/no aka boolean fields can also make a huge difference in some queries.

What really happens is that Jet brings down the index pages and data pages which are required. While this is a lot more data than a database engine would create this is not the entire table.

I also have clients with 600K and 800K records in various tables and performance is just fine.

Tony Toews
"clients with 600K and 800K records in various tables" -- these are the ones you recommended be migrated to SQL Server, no?
onedaywhen
Yes, although for different reasons than sheer volume of records or performance. More that the businesses have grown in size such that it's worth spending the effort in upsizing relative to the risk of corruption. These clients have basically quadrupled or even up to ten fold in volume of activity in the last ten years.
Tony Toews