Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Q1:
When I pull data and I have a field and the field appears to be either Null, an empty string, or it has a few spaces in it, and when I use the script,
Where not IsNull([Field Name]) and Len(trim([Field Name])) >0 and it still does not delete those empty lines, what should I do to get rid of them?
Q2: Then just by chance I did this with a resident load, trim([Field Name]) as [Field Name] and it deleted all the lines where Field Name was empty. I did not have any code after that. How did this get rid of empty rows when I only told it to trim them, not delte them? Maybe I am not understanding the use of trim or? Any who, please answer both Q's so I can figure this out. Many Thanks, Sean
WHERE LEN(TRIM([Field Name])) should do the selection.
Think that you need to specify the use of the NOT:
WHERE NOT(ISNULL([Field Name])) AND ....
should then work.
HTH
Peter