0x80004005: The precision is invalid.

Ask a Question related to ASP Database, Design and Development.

  1. #1

    Default 0x80004005: The precision is invalid.

    Hi,
    I am Tring to send a decimal to a SQL stored Procedure and get a The
    precision is invalid.

    The Fields are set for 4 precision 2 scale decimal

    @HOURHoliday [decimal](4,2),
    @HOURSOT [decimal](4,2),
    @HOURSREG [decimal](4,2),
    @HOURSVAC [decimal](4,2),

    The ado code area is

    P.Append CN.CreateParameter("@HOURHoliday",adDecimal,1,4)
    P.Append CN.CreateParameter("@HOURSOT",adDecimal,1,4)
    P.Append CN.CreateParameter("@HOURSREG",adDecimal,1,4)
    P.Append CN.CreateParameter("@HOURSVAC",adDecimal,1,4)

    this code also result in the same error
    P.Append CN.CreateParameter("@HOURHoliday",adDecimal,1)
    P.Append CN.CreateParameter("@HOURSOT",adDecimal,1)
    P.Append CN.CreateParameter("@HOURSREG",adDecimal,1)
    P.Append CN.CreateParameter("@HOURSVAC",adDecimal,1)

    this is where the paramater are set
    CN("@HOURHoliday") = HolidayHours
    CN("@HOURSOT") = OverTimeHours
    CN("@HOURSREG") = RegularHours
    CN("@HOURSVAC") = VacationHours

    I am sure there is a problem between the stored proc and the ado pramater.
    basic value I would send to all is like 10.75

    D


    DJP Guest

  2. Similar Questions and Discussions

    1. 0x80004005 error
      Hi I am getting an unspecified 0x80004005 error accessing my access db. What steps can I take to find out where the problem lies? Thanks ...
    2. Jet Error 0x80004005
      http://www.aspfaq.com/show.asp?id=2009 "Si" <nospam@nospam.com> wrote in message news:%23G6CY3knDHA.1708@TK2MSFTNGP12.phx.gbl... or be
    3. ASP 0105 (0X80004005)
      Someone coud help me about this message: Error Type: Request object, ASP 0105 (0x80004005) An array index is out of range....
    4. Error 0x80004005
      Hi all... in first I'm sorry for my english... I've a problem... I work on pc with win xp pro and for testing my website I use iis and odbc...
    5. Error Type: 0x80004005
      Hi all, I am supposd to be teaching DWMX right now and have broke for an early lunch as we are having problems with: Error Type: Provider...
  3. #2

    Default Re: 0x80004005: The precision is invalid.

    You cannot set the precision and scale properties in the CreateParameter
    method. Those Parameter properties need to be set after the Parameter is
    completed. You may want to try my Stored Procedure Code generator. It is
    available here:
    [url]http://www.thrasherwebdesign.com/index.asp?pi=links&hp=links.asp[/url]

    HTH,
    Bob Barrows

    DJP wrote:
    > Hi,
    > I am Tring to send a decimal to a SQL stored Procedure and get a
    > The precision is invalid.
    >
    > The Fields are set for 4 precision 2 scale decimal
    >
    > @HOURHoliday [decimal](4,2),
    > @HOURSOT [decimal](4,2),
    > @HOURSREG [decimal](4,2),
    > @HOURSVAC [decimal](4,2),
    >
    > The ado code area is
    >
    > P.Append CN.CreateParameter("@HOURHoliday",adDecimal,1,4)
    > P.Append CN.CreateParameter("@HOURSOT",adDecimal,1,4)
    > P.Append CN.CreateParameter("@HOURSREG",adDecimal,1,4)
    > P.Append CN.CreateParameter("@HOURSVAC",adDecimal,1,4)
    >
    > this code also result in the same error
    > P.Append CN.CreateParameter("@HOURHoliday",adDecimal,1)
    > P.Append CN.CreateParameter("@HOURSOT",adDecimal,1)
    > P.Append CN.CreateParameter("@HOURSREG",adDecimal,1)
    > P.Append CN.CreateParameter("@HOURSVAC",adDecimal,1)
    >
    > this is where the paramater are set
    > CN("@HOURHoliday") = HolidayHours
    > CN("@HOURSOT") = OverTimeHours
    > CN("@HOURSREG") = RegularHours
    > CN("@HOURSVAC") = VacationHours
    >
    > I am sure there is a problem between the stored proc and the ado
    > pramater. basic value I would send to all is like 10.75
    >
    > D

    Bob Barrows Guest

Posting Permissions

  • You may not post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139