resulta que tengo esto:
Código HTML:
select nombres, appat, apmat from cliente where rut = @rut order by appat, apmat, nombres asc
Código HTML:
select nombres, appat, apmat from cliente where rut = @rut [COLOR=Red]and valor = @valor[/COLOR] order by appat, apmat, nombres asc
intenté hacer esto:
Código HTML:
select nombres, appat, apmat from cliente
where rut = @rut
[COLOR=Red]
IF @valor not null
BEGIN
and valor = @valor
END
[/COLOR]
order by appat, apmat, nombres asc

