FOROS PROFESIONALES
WINDEV
,
WEBDEV
y
WINDEV Mobile
Inicio
|
Mensajes recientes
|
Conéctese...
|
Desconectar
|
Español
Inicio
→
WINDEV 2024
→
Recorrer un Query
Recorrer un Query
Iniciado por victor, 15,dic. 2008 15:47 - 2 respuestas
Conéctese…
victor
#1
Publicado el 15,diciembre 2008 - 15:47
Hola
Windev Express 12
Necesito recorrer un Query tengo el siguiente codigo
HExecuteQuery(EXPRESS_QRY_Parametros,hQueryDefault,EXPRESS_DASHDATA.DashId)
HReadFirst(EXPRESS_QRY_Parametros)
WHILE NOT HOut(EXPRESS_QRY_Parametros)
// Process the record
TableAddLine(TablaParametro,EXPRESS_QRY_Parametros.DescParametro, EXPRESS_QRY_Parametros.Valor,EXPRESS_QRY_Parametros.nombreCampoValor)
HReadNext(EXPRESS_QRY_Parametros)
END
El tema es que cuando el query EXPRESS_QRY_Parametros no tiene registros
HReadFirst(EXPRESS_QRY_Parametros) siempre me devuelve true como si encontrara
registro y en realidad no tiene nada.
Como debo buscar o recorrer un query luego de ejecutar HExecuteQuery
Desde ya muchas gracias
Victor Pereyra
Argentina-Cordboba
Informar
0
0
Réda
#2
Publicado el 16,diciembre 2008 - 08:01
Hola victor..
First of all I don't think that you will need to use the boolean value of HReadFirst(...)in your code? entering in the 'while' loop wouldn't do any harm.
Any way, If I were you I should
-Check the ORDER BY field of the query ..
or..
-Make sure that the source file deosn't contain empty lines entered by mistake in the source file, especialy when you are using an "id" as a parameter
Other wise your code seems to be correct
tip:
To fill a table with data from a query better : open the description window an indicate that the query is the source of the object "Table"
ciao
Informar
0
0
Francisco J. Acedo M.
#3
Publicado el 25,diciembre 2008 - 12:20
for each <query>
......
end
"victor" <vihupe@yahoo.com.ar> escribió en el mensaje de noticias
news:d9b3e43dbcf01e5dedf8c2ed1b830c7e@news.pcsoft...
Hola
Windev Express 12
Necesito recorrer un Query tengo el siguiente codigo
HExecuteQuery(EXPRESS_QRY_Parametros,hQueryDefault,EXPRESS_DASHDATA.DashId)
HReadFirst(EXPRESS_QRY_Parametros)
WHILE NOT HOut(EXPRESS_QRY_Parametros)
// Process the record
TableAddLine(TablaParametro,EXPRESS_QRY_Parametros.DescParametro,
EXPRESS_QRY_Parametros.Valor,EXPRESS_QRY_Parametros.nombreCampoValor)
HReadNext(EXPRESS_QRY_Parametros)
END
El tema es que cuando el query EXPRESS_QRY_Parametros no tiene registros
HReadFirst(EXPRESS_QRY_Parametros) siempre me devuelve true como si
encontrara
registro y en realidad no tiene nada.
Como debo buscar o recorrer un query luego de ejecutar HExecuteQuery
Desde ya muchas gracias
Victor Pereyra
Argentina-Cordboba
Informar
0
0
→ Volver a WINDEV 2024
WINDEV 2024
WEBDEV 2024
Français
English
Español
Portuguesa
Fermer cette fenêtre
Búsqueda Tipo
Sólo temas
Todos los mensajes
Periodo Buscar
Cualquier fecha
Última hora
Última 24 horas
Última semana
Último mes
Último año
Cancelar
Vista previa del mensaje
Añadiendo una imagen
Importar una imagen desde una URL
Enviar una imagen desde un archivo de su disco
Arrastrar un archivo o click en "Examinar..."
o
Cancelar
0%
WLanguage
SQL
XML, HTML
JAVA, Javascript
Texto