#deleted on linked table select query

M

Mark

I'm doing a select query on linked tables where the source data is in an
AS400 database. It's a left outer join query (tableA left outer join tableB
on tableA.ID = tableB.ID)

The problem happens when tableB.ID doesn't exist. I want to return a field
from tableB (call it MemberNum), but MemberNum shows as #Deleted for those
records where tableB.ID doesn't exist. I tried Nz and iif with isnull and
neither work. Any ideas on how to change that #Deleted to a blank or 0?

Thanks!
-Mark
 
M

Mark

Hi,

Thanks for your response. Yeah, I tried that too. Didn't work. I actually
found what the problem was. For anyone curious, it's at
http://support.microsoft.com/kb/128809

Basically, as I read it, it's the way Access queries the db. The suggestion
I ended up using was to convert to a passthrough query, then using the AS400
coalesce function to change the nulls to 0's.

Golfinray said:
Try IIF(tableb.id]is null, "0",[tableb.id])

Mark said:
I'm doing a select query on linked tables where the source data is in an
AS400 database. It's a left outer join query (tableA left outer join tableB
on tableA.ID = tableB.ID)

The problem happens when tableB.ID doesn't exist. I want to return a field
from tableB (call it MemberNum), but MemberNum shows as #Deleted for those
records where tableB.ID doesn't exist. I tried Nz and iif with isnull and
neither work. Any ideas on how to change that #Deleted to a blank or 0?

Thanks!
-Mark
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top