Re: SQL Query - precision error

Tech-Archive recommends: Fix windows errors by optimizing your registry



Hi Art,

What exactly is the value of f_docnumber?

--
HTH,

Kevin Spencer
Microsoft MVP
..Net Developer
Sometimes you eat the elephant.
Sometimes the elephant eats you.

"Art" <Art@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:A380A1E7-E75B-45B2-A759-814C0DE042E8@xxxxxxxxxxxxxxxx
> The database is a runny under SQL 2000. We cannot change the precision as
> itis software set.
>
> That said, why would I get a precision error when querying that database
> from a Front Page query?
>
> If I run the query in Query Analyzer without the Front Page Search
> variable,
> it works fine.
>
>
>
> "Kevin Spencer" wrote:
>
>> Hi Art,
>>
>> Precision refers to the precision (number of digits, both to the right
>> and
>> left of the decimal point) in a floating point number. According to your
>> field definition, the precision is 10, which means that you can store a
>> decimal number with a maximum of 10 digits in it. The second number is
>> scale, which is the number of digits allowed to the right of the decimal
>> point of the number, which you've defined as 0 (IOW, you can store an
>> integer with a maximum of 10 digits). I can't tell you much more, as you
>> mentioned a "SQL table." SQL is a query language, and SQL Server is a
>> database. Since a lot of non-database-professionals use the terms
>> interchangeably, I don't know what kind of database you're using.
>>
>> --
>> HTH,
>>
>> Kevin Spencer
>> Microsoft MVP
>> ..Net Developer
>> Sometimes you eat the elephant.
>> Sometimes the elephant eats you.
>>
>> "Art" <Art@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
>> news:97BDEFB4-A914-42A4-826A-85F2A115C7B0@xxxxxxxxxxxxxxxx
>> >I am using a very basic query in Front Page 2002 against a SQL table
>> >
>> > SELECT * FROM tablename WHERE (f_docnumber = ::f_docnumber::)
>> >
>> > and f_docnumber is a search form field.
>> >
>> > When I run I get
>> >
>> > Description: The precision is invalid.
>> > Number: -2147467259 (0x80004005)
>> >
>> > The field is defined in the table as numberic 9(10,0)
>> >
>> > Any ideas?
>> >
>> >
>> > Thanks
>> >
>>
>>
>>


.



Relevant Pages

  • Re: SQL Query - precision error
    ... "Kevin Spencer" wrote: ... We cannot change the precision as ... >>> decimal number with a maximum of 10 digits in it. ... >>> Sometimes the elephant eats you. ...
    (microsoft.public.frontpage.programming)
  • Re: Maketable query a text field is changing to expoential number?
    ... If you do want decimal places, you can use the currency data type -- this will give you 15 digits before the decimal and 4 digits after ... It is not a good idea to use single or double precision numbers to link fields or for exact comparisons, because of the way they are stored ... I then have a make table query to make tables needed to view the results in reports based on product lines. ... Also for some of the items it is changing it is duplicating, but if I run a find duplicates query is shows nothing, implying there are no duplicates. ...
    (microsoft.public.access.queries)
  • Re: SQL Query - precision error
    ... Precision refers to the precision (number of digits, ... decimal number with a maximum of 10 digits in it. ... mentioned a "SQL table." ... Sometimes the elephant eats you. ...
    (microsoft.public.frontpage.programming)
  • Re: SQL Query - precision error
    ... wouldn't get a precision error if that was the case. ... Response.Write statement just after the query is formed, ... >> ..Net Developer ... >> Sometimes the elephant eats you. ...
    (microsoft.public.frontpage.programming)
  • Re: SQL Query - precision error
    ... I wish he could Response.Write the query out to the ... Thoughts, Kevin? ... >>>Hi Art, ... >>>Sometimes the elephant eats you. ...
    (microsoft.public.frontpage.programming)