System.InvalidOperationException: The 'HorasSolicitadas' property on 'SolicitudVacacion' could not be set to a 'Int32' value. You must set this property to a non-null value of type 'Decimal'. at System.Data.Common.Internal.Materialization.Shaper.ErrorHandlingValueReader`1.GetValue(DbDataReader reader, Int32 ordinal) at System.Data.Common.Internal.Materialization.Shaper.GetPropertyValueWithErrorHandling[TProperty](Int32 ordinal, String propertyName, String typeName) at lambda_method(Closure , Shaper ) at System.Data.Common.Internal.Materialization.Shaper.HandleEntityAppendOnly[TEntity](Func`2 constructEntityDelegate, EntityKey entityKey, EntitySet entitySet) at lambda_method(Closure , Shaper ) at System.Data.Common.Internal.Materialization.Coordinator`1.ReadNextElement(Shaper shaper) at System.Data.Common.Internal.Materialization.Shaper`1.SimpleEnumerator.MoveNext() at System.Linq.Enumerable.FirstOrDefault[TSource](IEnumerable`1 source) at System.Linq.Queryable.FirstOrDefault[TSource](IQueryable`1 source) at Aseinfo.Infrastructure.Base.Entity.EntityServiceBase`2.GetEntityById(IdT id, Expression`1[] includes) in C:\BuildAgent\work\2af027e4cc30ca96\Infrastructure\Base\Entity\EntityServiceBase.cs:line 260 at Aseinfo.VH4.Acciones.Controllers.SolicitudVacacionController.Edit(Int32 id) in c:\BuildAgent\work\2af027e4cc30ca96\VH4\Acciones\Controllers\SolicitudVacacionController.cs:line 327 at lambda_method(Closure , ControllerBase , Object[] ) at System.Web.Mvc.ReflectedActionDescriptor.Execute(ControllerContext controllerContext, IDictionary`2 parameters) at System.Web.Mvc.ControllerActionInvoker.InvokeActionMethod(ControllerContext controllerContext, ActionDescriptor actionDescriptor, IDictionary`2 parameters) at System.Web.Mvc.ControllerActionInvoker.<>c__DisplayClass15.<InvokeActionMethodWithFilters>b__12() at System.Web.Mvc.ControllerActionInvoker.InvokeActionMethodFilter(IActionFilter filter, ActionExecutingContext preContext, Func`1 continuation) at System.Web.Mvc.ControllerActionInvoker.InvokeActionMethodFilter(IActionFilter filter, ActionExecutingContext preContext, Func`1 continuation) at System.Web.Mvc.ControllerActionInvoker.InvokeActionMethodWithFilters(ControllerContext controllerContext, IList`1 filters, ActionDescriptor actionDescriptor, IDictionary`2 parameters) at System.Web.Mvc.ControllerActionInvoker.InvokeAction(ControllerContext controllerContext, String actionName)

Es en Evolution version 1.7.1

asked 12 Aug '13, 19:49

JulioRosales's gravatar image

JulioRosales
(suspended)
accept rate: 26%

edited 12 Aug '13, 19:53


Parece que la columna sdv-dias o sdv-horas de la tabla acc.sdv-solicitud-dias-vacacion estén definidas de tipo entero.

En el script de upgrade a la versión 1.7.1 las columnas se modificaron para que quedaran así:

   [sdv_dias] [numeric](19, 4) NOT NULL,
   [sdv_horas] [numeric](19, 4) NOT NULL,

Solo que el upgrade no se halla ejecutado correctamente. En cuyo caso, a saber que otras cosas no actualizaste correctamente ...

link

answered 12 Aug '13, 20:32

Fernando%20Paz's gravatar image

Fernando Paz ♦♦
17.3k81635
accept rate: 51%

edited 12 Aug '13, 20:33

Revisando la estructura de los dos campos que me indico, solo se efectuo uno y el otro sdv_horas me aparece aun como tipo INT.

Por como se maneja aquí en guatemala el levantamiento de versiones, los Upgrade son por parte del equipo de IT de la empresa que posee el servicio ya nosotros no realizamos dicho upgrade.

Trate de realizar un alter column pero no me dejo debido a un constraint que posee la misma tabla por lo que procedi a crear de nuevo el constraint para un default decimal

(12 Aug '13, 20:46) JulioRosales JulioRosales's gravatar image
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Evolution en BitBucket

En este sitio puede acceder al código fuente, centro de descargas y reportar bugs, propuestas y mejoras para Evolution.

Evolution en JIRA

En este sitio puedes sugerir nueva funcionalidad para Evolution, o puedes votar por la funcionalidad ya propuesta por otros usuarios.

Tags:

×31

Asked: 12 Aug '13, 19:49

Seen: 2,042 times

Last updated: 12 Aug '13, 21:10

[Acerca de] [Preguntas Frecuentes] [Privacidad] [Soporte] [Contacto]
Copyright 2013-2018. Asesores en Informática