Foros del Web » Programando para Internet » ASPX (.net) »

[SOLUCIONADO] Error Name cannot begin with the '=' character, hexadecimal value 0x3D

Estas en el tema de Error Name cannot begin with the '=' character, hexadecimal value 0x3D en el foro de ASPX (.net) en Foros del Web. Buenos días, Tengo un problema con mi aplicacion. Me da el siguiente error a la hora de realizar un consulta del tipo Select. Consulta: @import ...
  #1 (permalink)  
Antiguo 21/05/2013, 02:21
 
Fecha de Ingreso: octubre-2012
Ubicación: Pozuelo de Alarcón
Mensajes: 67
Antigüedad: 11 años, 5 meses
Puntos: 1
Error Name cannot begin with the '=' character, hexadecimal value 0x3D

Buenos días,

Tengo un problema con mi aplicacion.

Me da el siguiente error a la hora de realizar un consulta del tipo Select.

Consulta:
Código XML:
Ver original
  1. <DbSource ConnectionRef="WALTConnectionString (Web.config)" DbObjectName="[COUNT]" DbObjectType="Table" FillMethodModifier="Public" FillMethodName="FillCountByDate2" GenerateMethods="Both" GenerateShortCommands="true" GeneratorGetMethodName="GetCountByLaunchDate2" GeneratorSourceName="FillCountByDate2" GetMethodModifier="Public" GetMethodName="GetCountByLaunchDate2" QueryType="Rowset" ScalarCallRetval="System.Object, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" UseOptimisticConcurrency="true" UserGetMethodName="GetCountByLaunchDate2" UserSourceName="FillCountByDate2">
  2.                 <SelectCommand>
  3.                   <DbCommand CommandType="Text" ModifiedByUser="true">
  4.                     <CommandText>SELECT        id_count, id_user, count_type, round, status, launch_date, comments, launched_by, counter_name, counter_mail, counter_phone, open_date, close_date
  5. FROM            [COUNT]
  6. WHERE        ([launch_date] <= ? ) AND ([launch_date] >= ? ) </CommandText>
  7.                     <Parameters>
  8.                       <Parameter AllowDbNull="true" AutogeneratedName="Param1" ColumnName="launch_date" DataSourceName="[COUNT]" DataTypeServer="DbType.Date" DbType="Date" Direction="Input" ParameterName="launch_date" Precision="0" ProviderType="Date" Scale="0" Size="0" SourceColumn="launch_date" SourceColumnNullMapping="false" SourceVersion="Current" />
  9.                       <Parameter AllowDbNull="true" AutogeneratedName="Param2" ColumnName="launch_date" DataSourceName="[COUNT]" DataTypeServer="DbType.Date" DbType="Date" Direction="Input" ParameterName="launch_date2" Precision="0" ProviderType="Date" Scale="0" Size="0" SourceColumn="launch_date" SourceColumnNullMapping="false" SourceVersion="Current" />
  10.                     </Parameters>
  11.                   </DbCommand>
  12.                 </SelectCommand>
  13.               </DbSource>


Al cambiar el <=/>= por el solo = funciona correctamente.

He probado la query directamente en la base de datos y me funciona bien.
No se porque me da ese error.

Muchas gracias de antemano.
Un saludo.
  #2 (permalink)  
Antiguo 22/05/2013, 02:41
 
Fecha de Ingreso: octubre-2012
Ubicación: Pozuelo de Alarcón
Mensajes: 67
Antigüedad: 11 años, 5 meses
Puntos: 1
Respuesta: Error Name cannot begin with the '=' character, hexadecimal value 0x3D

Buenas,

Encontre la solucion.

El problema es que XML no acepta los literales '<', '>'.
Para ellos hay que sustituirlo por &lt; y &gt;

Asi he conseguido resolver el problema.

Un saludo y Gracias.

Etiquetas: aplicacion, hexadecimal, server
Atención: Estás leyendo un tema que no tiene actividad desde hace más de 6 MESES, te recomendamos abrir un Nuevo tema en lugar de responder al actual.
Respuesta




La zona horaria es GMT -6. Ahora son las 11:23.