Snowflake68
Registered User.
- Local time
- Today, 17:38
- Joined
- May 28, 2014
- Messages
- 452
Hi I have inherited a database that I will need to develop at some point but in the meantime I am trying to understand some of the code within it.
Can anyone help with understand the syntax below which is part of a query that displays the last note added to a memo field in a table. The data in the table has carriage returns with many user notes added.
I can see the results and can understand a little with how it works but I am trying to get my head around how the syntax it made up. I have tried breaking this down into separate sections but I am still a little puzzled as to how it all works together, especially the 'String' bit.
I know that Trim removes leading and trailing spaces and I can see that the right function is taking the last 500 characters of the Notes field but its just the replace bit that really puzzles me.
Can anyone help explain the whole thing please.
Thanks
Can anyone help with understand the syntax below which is part of a query that displays the last note added to a memo field in a table. The data in the table has carriage returns with many user notes added.
Code:
Trim(Right(Replace([Task Update],Chr(10),String(500," ")),500))
I can see the results and can understand a little with how it works but I am trying to get my head around how the syntax it made up. I have tried breaking this down into separate sections but I am still a little puzzled as to how it all works together, especially the 'String' bit.
I know that Trim removes leading and trailing spaces and I can see that the right function is taking the last 500 characters of the Notes field but its just the replace bit that really puzzles me.
Can anyone help explain the whole thing please.
Thanks
Last edited: