Sorry for my first don't-listen-to-the-man-in-the-corner-message.
Because nobody corrected me I'll try myself.
It would be enough to leave the tcParam empty to get all records, if you
CREATE VIEW v_test AS ;
SELECT * FROM test ;
WHERE test.cCharacter = ?tcParam
To get the same effect for a numeric type or a more complicated construction
you could issue
... WHERE IIF( EMPTY(tnParam), .T., test.nNumber <= ?tnParam )
I don't think it could be unprofessional to use "<="
Maybe somebody else has a better solution for you.
> > For all types it should be enough to leave the parameter empty to get
> > all records.
> > >How can I get all records when
> > >parameter is
> > > integer type?
> Hi Stefan,
> does it works for you?
> I have read in other messages from news they need to use operator
> and joker "%" to get all records with a string parameter, but it doesn't
> work if they don't use the "%".
> This happens for me too.
> The problem is that I don't know any joker to integer parameters, and
> leaving it empty doesn't work.
> I'm thinking on using two parameters: one with operator ">=" and the
> other whit "<=" but it seems not to be "professional".
> Can problem be in SQL Server Configuration?.
> I remember when I instaled SQL Server that there was to select some
> options like: "Case Sensitive", "Case Insensitive", etc., but I don't
> remember what for.