My Assistant
![]() ![]() |
|
|
Mar 3 2012, 09:40 PM
Post
#1
|
|
|
UtterAccess Member Posts: 48 |
Hello -
I have a field that looks empty but it's not. If you use Len(), it has a value of 4. And I know it's not 4 spaces. Is there a way I can tell what type of character is in there so I can create another field to match up to it? Thank you!! |
|
|
|
Mar 3 2012, 09:42 PM
Post
#2
|
|
|
UtterAccess VIP Posts: 17,613 From: Don Mills, ON (Canada) |
Use the Asc to find out the Ascii value of each character:
Format(Asc(Mid([NameOfField], 1, 1), "000") & "_" & Format(Asc(Mid([NameOfField], 2, 1), "000") & "_" & Format(Asc(Mid([NameOfField], 3, 1), "000") & "_" & Format(Asc(Mid([NameOfField], 4, 1), "000") |
|
|
|
Mar 3 2012, 10:07 PM
Post
#3
|
|
|
UtterAccess Member Posts: 48 |
Thank you, Doug. I got the following result:
032_032_032_032 My next question is, how do I create a field like that? Should I post that in the Query forum? Thanks! |
|
|
|
Mar 3 2012, 11:16 PM
Post
#4
|
|
|
UtterAccess Ruler Posts: 1,812 From: SoCal, USA |
QUOTE QUOTE I have a field that looks empty but it's not. If you use Len(), it has a value of 4. And I know it's not 4 spaces. Is there a way I can tell what type of character is in there so I can create another field to match up to it? Thank you, Doug. I got the following result 032_032_032_032 Visual Basic Help in A2003 has a table "Character Set (0 – 127)". Character code 32 is listed as [space] in that table. my guess is that data is being written to that field programmatically, perhaps from an outside source? or via an Append query, perhaps one that has a calculated field where the calculation may return spaces only. hth tina |
|
|
|
Mar 4 2012, 12:12 PM
Post
#5
|
|
|
UtterAccess VIP Posts: 1,875 From: UK |
char 32 is a space, so the field does appear to contain 4 spaces.
|
|
|
|
![]() ![]() |
|
Go to Top · Lo-Fi Version | Time is now: 19th May 2013 - 10:38 PM |