Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Another interview question

Re: Another interview question

From: <hcinet_at_vdn.com>
Date: 1997/07/18
Message-ID: <33ced3af.20310577@news.vdn.com>#1/1

We experienced similar problems.

Are you or anybody you know available for a contract job working with Oracle.

Location: San Francisco Bay Area
Pay rate: High
Starting time: As soon as possible.

If you or anybody you know is interested, please respond.

HCI
hcinet_at_vdn.com

On Thu, 10 Jul 1997 16:56:19 -0700, Tim Witort <trwAT_at_ATmedicalert.DOTorg> wrote:

>Michael Serbanescu wrote:
>>
>> "A production database table contains a column defined as NUMBER(6,2).
>> However, at this point in the life of the application using the table,
>> *only integer numbers* can be used (although this may change in the
>> future, hence the column format). All the values currently contained in
>> the column are integers. Can you, the ORACLE DBA, provide as soon as
>> possible, a solution to this problem, i.e. allow only integers in that
>> column ? Your solution must have minimal or no impact on the
>> application, be easy to implement, flexible and generic."
>
>An insert and update trigger on the table would do it.
>The trigger code could round or truncate (or whatever you
>want) the column value to integer if the updated or
>inserted value is not integer. Or it could raise an
>exception if you don't want the trigger to change the
>column value transparently - that way users would know
>that only integers could be entered because when the
>try to update or insert non-integers they get an error.
>If you don't raise an exception, you may get the users
>looking at the values they had already inserted, and
>say, "Hey! I thought I entered 12.5 there, not 13!"
>
>-- TRW
>--
>|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
>| Tim Witort || He is not silent. He is not |
>| trwATmedicalertDOTorg || whispering. We are not quiet |
>| || we are not listening. |
>| Pin: TZ, only one :^( || - Out of the Grey |
>|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Received on Fri Jul 18 1997 - 00:00:00 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US