PC Review


Reply
Thread Tools Rate Thread

how do i insert a formula in microsoft access?

 
 
=?Utf-8?B?YXNo?=
Guest
Posts: n/a
 
      15th Jan 2006
i have created a new project in table and am on design view and was wondering
on how to insert a formula.

please reply a.s.a.p

thanks.
 
Reply With Quote
 
 
 
 
Allen Browne
Guest
Posts: n/a
 
      15th Jan 2006
In Access, you put the formula into the field in a query, not in the table.

Create the table without this field.
Then create a query, and type the calculation into the Field row.

More info and example:
Calculated fields
at:
http://allenbrowne.com/casu-14.html

--
Allen Browne - Microsoft MVP. Perth, Western Australia.
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.

"ash" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
>i have created a new project in table and am on design view and was
>wondering
> on how to insert a formula.
>
> please reply a.s.a.p
>
> thanks.



 
Reply With Quote
 
 
 
 
Douglas J. Steele
Guest
Posts: n/a
 
      15th Jan 2006
Just to amplify on Allen's advise.

You MUST put the formula into the field in a query, not in the table. Tables
cannot accept formulae.

--
Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no private e-mails, please)


"Allen Browne" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> In Access, you put the formula into the field in a query, not in the
> table.
>
> Create the table without this field.
> Then create a query, and type the calculation into the Field row.
>
> More info and example:
> Calculated fields
> at:
> http://allenbrowne.com/casu-14.html
>
> --
> Allen Browne - Microsoft MVP. Perth, Western Australia.
> Tips for Access users - http://allenbrowne.com/tips.html
> Reply to group, rather than allenbrowne at mvps dot org.
>
> "ash" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed)...
>>i have created a new project in table and am on design view and was
>>wondering
>> on how to insert a formula.
>>
>> please reply a.s.a.p
>>
>> thanks.

>
>



 
Reply With Quote
 
Tom Ellison
Guest
Posts: n/a
 
      16th Jan 2006
The statement "Tables cannot accept formulae" is true enough for Jet, but
not for MSDE/SQL Server (which is distributed with every version of Access
since 2000). This can be a valuable tool. It's a calculated column that
updates itself automatically as the values on which it depends are updated.
It's greatest value may be in the ability to index on the result. Other
than that, you could pretty much just put the formula into any query.
However, if that formula may be subject to later change, then the modular
nature of putting that formula into one place where it can be modified later
to change the whole application becomes very important indeed.

Tom Ellison


"Douglas J. Steele" <NOSPAM_djsteele@NOSPAM_canada.com> wrote in message
news:%(E-Mail Removed)...
> Just to amplify on Allen's advise.
>
> You MUST put the formula into the field in a query, not in the table.
> Tables cannot accept formulae.
>
> --
> Doug Steele, Microsoft Access MVP
> http://I.Am/DougSteele
> (no private e-mails, please)
>
>
> "Allen Browne" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed)...
>> In Access, you put the formula into the field in a query, not in the
>> table.
>>
>> Create the table without this field.
>> Then create a query, and type the calculation into the Field row.
>>
>> More info and example:
>> Calculated fields
>> at:
>> http://allenbrowne.com/casu-14.html
>>
>> --
>> Allen Browne - Microsoft MVP. Perth, Western Australia.
>> Tips for Access users - http://allenbrowne.com/tips.html
>> Reply to group, rather than allenbrowne at mvps dot org.
>>
>> "ash" <(E-Mail Removed)> wrote in message
>> news:(E-Mail Removed)...
>>>i have created a new project in table and am on design view and was
>>>wondering
>>> on how to insert a formula.
>>>
>>> please reply a.s.a.p
>>>
>>> thanks.

>>
>>

>
>



 
Reply With Quote
 
Douglas J. Steele
Guest
Posts: n/a
 
      29th Jan 2006
It's seldom recommended that you store computed values in tables. Not only
is it officially a violation of relational database normalization rules, but
as fellow Access MVP John Vinson likes to say "Storing calculated data
generally accomplishes only three things: it wastes disk space, it wastes
time (a disk fetch is much slower than almost any reasonable calculation),
and it risks data validity, since once it's stored in a table either the
Total or one of the fields that goes into the total may be changed, making
the value WRONG."

Put the formulae in a query, and use the query wherever you would otherwise
have used the table.

--
Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no private e-mails, please)


"bungie" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
>
> Same as ash, I have created my tables and forms (this is all new,
> MASSIVE learning curve here) got my formula's working in my form, but
> how do I then place the results into the field in the table that I
> want. Or am I missing something obvious here ?
>
> bungie
>
>
> --
> bungie
> ------------------------------------------------------------------------
> bungie's Profile: http://www.hightechtalks.com/m855
> View this thread: http://www.hightechtalks.com/t2332714
>



 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
ERROR [42000] [Microsoft][ODBC Microsoft Access Driver] Syntax error in INSERT INTO statement. Landley Microsoft ADO .NET 4 21st Sep 2005 08:38 PM
Insert | File > Attachmnet-Button Drop Down ;What is the difference between Insert and Insert As Attachmnet Oda Yujiro Microsoft Outlook 4 17th Jun 2004 01:53 AM
microsoft.public.developer.outlook.addins, microsoft.public.outlook.program_addins,microsoft.public.dotnet.languages.csharp,microsoft.public.outlook.general Anushya Microsoft C# .NET 0 15th Jan 2004 07:18 AM
microsoft.public.developer.outlook.addins,microsoft.public.dotnet.languages.csharp,microsoft.public.outlook.program_addins,microsoft.public.outlook.general Anushya Microsoft Dot NET Framework Forms 0 9th Jan 2004 08:21 AM
microsoft.public.dotnet.languages.vb.data,microsoft.public.dotnet.languages.vb.controls,microsoft.public .dotnet.languages.vb,microsoft.public.dotnet.languages.vb.upgrade Gladys Microsoft VB .NET 3 2nd Jan 2004 07:14 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 04:03 PM.