12.07.2015 Views

Microsoft Access Tutorial B - Cengage Learning

Microsoft Access Tutorial B - Cengage Learning

Microsoft Access Tutorial B - Cengage Learning

SHOW MORE
SHOW LESS
  • No tags were found...

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

show the SSN, the current wage rate, and the higher rate (which should be titled New Ratein the output). Figure B-10 shows how to set up the query.Figure B-10Query set-up for the calculated fieldThe Salaried field is needed, with the Criteria =No, to select hourly workers. The Showbox for that field is not checked, so the Salaried field values will not show in the query output.Note the expression for the calculated field, which you see in the rightmost field cell:New Rate: 1.1*[Wage Rate]New Rate: merely specifies the desired output heading. (Don’t forget the colon.) The1.1*[Wage Rate] multiplies the old wage rate by 110%, which results in the 10% raise.In the expression, the field name Wage Rate must be enclosed in square brackets. This isa rule: Any time that an <strong>Access</strong> expression refers to a field name, it must be enclosed insquare brackets.If you run this query, your output should resemble that shown in Figure B-11.Figure B-11Output for a query with calculated fieldNotice that the calculated field output is not shown in Currency format; it’s shown as aDouble—a number with digits after the decimal point. To convert the output to Currency format,click the line above the calculated field expression, thus activating the column (it darkens).Your data-entry screen should resemble the one shown in Figure B-12.18 <strong>Tutorial</strong> B

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!