?
Solved

MS Access - Unlimited or Infinity

Posted on 2004-03-28
6
Medium Priority
?
927 Views
Last Modified: 2008-03-06
Is there a way or symbol that can be entered into a number field to represent infinity or unlimited in a Microsoft Access database??
0
Comment
Question by:geekhelp
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
6 Comments
 
LVL 2

Expert Comment

by:eric_duncan
ID: 10701309
My understanding is that the number field has to have either a discrete value or null. I have seen other people solve this issue by "reserving" a specific value that will be used to indicate infinity - this is often the upper bound of the number field or a null value. The advantage of using null, if you don't need it otherwise, is that mathematical operations using null closely resemble mathematical operations using inifinity because the result is always null.

Let me know if this helps!

eric
0
 
LVL 53

Expert Comment

by:Ryan Chong
ID: 10701406
>>Is there a way or symbol that can be entered into a number field to represent infinity or unlimited in a Microsoft Access database??
The simplest way is to assign an 'impossible' value as Default to the number field to represent the 'infinity' or 'unlimited' value, like put a value of -1 in your field's Default value ?
0
 
LVL 2

Expert Comment

by:Carlovski
ID: 10703739
Eric is right,
Database nulls, and infinity do share many properties, but using a Null is likely to really confuse people who aren't used to databases, or mathematics!
Also, the properties that they do share, may not be want you want (i.e nothing is ever equal to eiher Null or infinity, even null or infinity!)
The safest thing may be to hold if it is infinite value in a separate field (Being picky, numeric fields should hold discrete values)
What exactly are you trying to record?
0
What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

 

Author Comment

by:geekhelp
ID: 10721508
The field is for a Doggy Daycare database - It keeps track of how many "available passes" the dog owner has on their account. When a dog is "Checked in" to our facility a pass is automatically deducted from this field.
Owners can purchase a monthly unlimited pass and I am trying to figure out how I can represent this in the database, so that it stays the same even when the field has 1 subtracted from it. Thanks
0
 
LVL 2

Accepted Solution

by:
eric_duncan earned 750 total points
ID: 10722752
There isn't any way you can make the database handle this situation automatically - you are going to have to use some application logic to figure out whether or not someone has an unlimited pass or not. Probably the easiest way to do that would be to add a Boolean field to the table to track whether or not someone has unlimited passes on their account and then check this value in your application logic.

Eric
0
 

Author Comment

by:geekhelp
ID: 10729256
Thank You all who helped reach this conclusion!
0

Featured Post

Get proactive database performance tuning online

At Percona’s web store you can order full Percona Database Performance Audit in minutes. Find out the health of your database, and how to improve it. Pay online with a credit card. Improve your database performance now!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A Stored Procedure in Microsoft SQL Server is a powerful feature that it can be used to execute the Data Manipulation Language (DML) or Data Definition Language (DDL). Depending on business requirements, a single Stored Procedure can return differe…
Microsoft Access is a place to store data within tables and represent this stored data using multiple database objects such as in form of macros, forms, reports, etc. After a MS Access database is created there is need to improve the performance and…
This is a high-level webinar that covers the history of enterprise open source database use. It addresses both the advantages companies see in using open source database technologies, as well as the fears and reservations they might have. In this…
In this video, Percona Director of Solution Engineering Jon Tobin discusses the function and features of Percona Server for MongoDB. How Percona can help Percona can help you determine if Percona Server for MongoDB is the right solution for …

800 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question