Re: IIF in SQL Stroed Proceedure
- From: "Sylvain Lafontaine" <sylvain aei ca (fill the blanks, no spam please)>
- Date: Mon, 25 Apr 2005 23:43:28 -0400
I'm afraid to tell you that you don't work with ADP in the same way as with
Access. You will have to learn how to write stored procedures on the
SQL-Server.
You can also choose to build your Select dynamically and then set the
recordsource of your form to it, something like:
Dim stringSQL as String
If (Me.CheckBox1) then
stringSQL = "select * from MyTable where [Individual Policy] <> 0"
else
stringSQL = "select * from MyTable where [Family Policy] <> 0"
end if
Me.RecordSource = stringSQL
However, you'll still have to learn how to program SQL-Server if you want to
work with it in any case.
--
Sylvain Lafontaine, ing.
MVP - Technologies Virtual-PC
"Randy Shaw via AccessMonster.com" <forum@xxxxxxxxxxxxxxxxx> wrote in
message news:441c2473bc63482496ccb42f467f2c7a@xxxxxxxxxxxxxxxxxxxx
>I have a bound check box on my form and I want to use Select If statement
> that will query the table and determine and return a vale in my query.
> Is
> like an IIF expression
>
> If [CkBox1] is checked 'Check Box 1 is Checked' or If [CkBox2] is checked
> 'Check Box 2 is Checked' 'ELSE 'No Boxes Checked'
>
> --
> Message posted via http://www.accessmonster.com
.
- References:
- IIF in SQL Stroed Proceedure
- From: Randy Shaw via AccessMonster.com
- Re: IIF in SQL Stroed Proceedure
- From: Sylvain Lafontaine
- Re: IIF in SQL Stroed Proceedure
- From: Randy Shaw via AccessMonster.com
- IIF in SQL Stroed Proceedure
- Prev by Date: Re: IIF in SQL Stroed Proceedure
- Next by Date: Re: How do I execute a stored procedure
- Previous by thread: Re: IIF in SQL Stroed Proceedure
- Index(es):