A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Running & Setting Up Queries
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

access query



 
 
Thread Tools Display Modes
  #1  
Old January 26th, 2007, 10:22 PM posted to microsoft.public.access.queries
sierralightfoot
external usenet poster
 
Posts: 167
Default access query

if[status] = "active" then[listdate]
if [status]= 'withdrawn" or "canceled" or "expired" then [statuschangedate]
if[status]= "*pend" or "sold" then [saledate]
  #2  
Old January 27th, 2007, 12:37 AM posted to microsoft.public.access.queries
Smartin
external usenet poster
 
Posts: 192
Default access query

sierralightfoot wrote:
if[status] = "active" then[listdate]
if [status]= 'withdrawn" or "canceled" or "expired" then [statuschangedate]
if[status]= "*pend" or "sold" then [saledate]


You could use nested IIf statements to pick various outcomes based on
[status], if that's what you are trying to do.

Untested:

Expr1: IIf(status='active', listdate,
IIf(status IN ('withdrawn','canceled','expired'), statuschangedate,
IIf(status LIKE '*pend' OR status='sold',saledate,'undefined')
)
)

HTH
--
Smartin
  #3  
Old January 27th, 2007, 12:40 AM posted to microsoft.public.access.queries
Jeff Boyce
external usenet poster
 
Posts: 8,621
Default access query

I'm sure there's a question somewhere, but I didn't find it here.

Regards

Jeff Boyce
Microsoft Office/Access MVP


"sierralightfoot" wrote in
message ...
if[status] = "active" then[listdate]
if [status]= 'withdrawn" or "canceled" or "expired" then
[statuschangedate]
if[status]= "*pend" or "sold" then [saledate]



  #4  
Old January 27th, 2007, 01:10 AM posted to microsoft.public.access.queries
Smartin
external usenet poster
 
Posts: 192
Default access query

Jeff Boyce wrote:
I'm sure there's a question somewhere, but I didn't find it here.

Regards

Jeff Boyce
Microsoft Office/Access MVP


forks over some fresh batteries for Jeff's crystal ball

(^:

--
Smartin
  #5  
Old January 27th, 2007, 02:06 AM posted to microsoft.public.access.queries
John Vinson
external usenet poster
 
Posts: 4,033
Default access query

On Fri, 26 Jan 2007 14:22:01 -0800, sierralightfoot
wrote:

if[status] = "active" then[listdate]
if [status]= 'withdrawn" or "canceled" or "expired" then [statuschangedate]
if[status]= "*pend" or "sold" then [saledate]


Do you have a question, Sierra?

You've posted part of what looks like pseudocode - it's certainly not
an Access query, and we don't have any way to know the context or what
you're trying to accomplish.

John W. Vinson[MVP]
 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 07:53 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.