-
- Preview browser
- Page designer
- DQL editor
- Application wide settings
- Security settings
- Page caching module
- Modules
- Snippets
- Actions
- Context editor
- Task editor
- Scheduler editor
- Search engine editor
- Web server console
- Site layout editor
- Template editor
- Robots editor
- Style definitions
- Database manipulation
- Table designer
- Transfer editor
- Reporter
- Deployment module
- Deployment server settings
- Debugger
- .end
- .form header
- .form trailer
- .items
- assign
- application status
- backup db
- begin transaction
- break
- call menu
- call program
- case
- cluster by
- commit
- connect
- copy all from
- data-entry
- db status
- delete records
- define
- disconnect
- do
- documents
- exec SQL
- else
- end
- enter a record
- error messages off
- error messages on
- exit
- export
- for
- global
- if
- import
- imports
- in
- input using
- install application
- into
- list records
- lock
- lock db
- modify records
- message
- named
- others
- prompt
- query selection
- record entry
- records
- reorganize
- restore db
- rollback
- run procedure
- servers
- temp
- then
- tran off
- tran on
- unclustered
- unlock
- unlock db
- via form
- while
- with
- abs
- acos
- addressof
- ampm
- anylookup
- asin
- atan
- atan2
- ceil
- CHR
- concat
- ConsoleCopy
- ConsoleMemoCopy
- ConsoleShow
- ConsoleWriteToFile
- cos
- cosh
- date
- DatePicker
- day
- DEOS
- DialogOpen
- DialogOpenRelated
- DocumentCloseName
- DoesObjectExist
- ExecDQL
- ExecuteFile
- exp
- FileExecDQL
- firstc
- firstlast
- firstw
- FixedWidth
- floor
- futurevalue
- GetCurrent
- GetVar
- hours
- if
- installment
- jointext
- julian
- lastc
- lastfirst
- lastw
- length
- log
- log10
- lower
- MemoChunk
- MemoCopy
- MemoDecodePair
- MemoExecDQL
- MemoFind
- MemoGetGlobal
- MemoLength
- MemoMemoCopy
- MemoMemoReplace
- MemoReadFromFile
- MemoReplace
- MemoSetGlobal
- MemoStringBetween
- MemoStringFrom
- MemoStringTo
- MemoWordCount
- MemoWriteToFile
- midc
- midw
- minutes
- mod
- month
- OpenForm
- OpenMenu
- OpenProcedure
- OpenReport
- periods
- power
- presentvalue
- proper
- random
- rate
- RefreshForm
- RefreshScreen
- RefreshStatus
- Remote
- Remote authentication
- Remote POP3
- Remote IMAP
- Remote SMTP
- Remote XML
- seconds
- SetColor
- SetCurrent
- SetFocus
- SetLabelText
- SetMemoValue
- SetState
- SetStyle
- SetValue
- SetVar
- sin
- sinh
- spellcurrency
- spelldate
- spellmonth
- spellnumber
- spellweekday
- sqrt
- StringBetween
- StringEscape
- StringFind
- StringFrom
- StringReplace
- StringTo
- tan
- tanh
- textpos
- timeampm
- ToText
- UniqueID
- upper
- Wait
- weekday
- WriteToFile
- year
- yearday
- yearweek
- " (quotation marks)
- () (parentheses)
- + (addition)
- , (comma)
- - (subtraction)
- . (period)
- -- (comment)
- / (division)
- * (multiplication)
- * (asterisk)
- ? (question mark)
- ~ (tilde)
- : (colon)
- := (assignment operator)
- ; (semicolon)
- < (less than)
- <= (less than or equal to)
- = (equals)
- > (greater than)
- >= (greater than or equal to)
- all
- all files
- and
- any
- between
- blank
- count
- count of
- file
- highest of
- in groups
- in groups with group-totals
- in order
- in reverse
- item (Statistical)
- item (Conditional Statistical)
- lock files
- lock nothing
- lock records
- lookup
- lowest of
- max
- mean
- mean of
- min
- not
- number
- numeric string
- or
- pause
- percent
- selected record
- std.dev.
- std.err.
- sum
- sum of
- text
- time
- to
- variance
- window
- Rules for queries
- * (asterisk)
- ? (question mark)
- ~ (tilde)
- and
- or
- not
- ( ) (parentheses)
- Debug querys
- Livetext tags
- xdg3 query
- Sessions
- Pagination
- Free text search
- Intro on fields
- Text
- Hidden
- Date
- Dropdown
- List
- Checkbox
- Radio button
- Text edit
- Redactor (richtext)
- CKEditor
- TinyMCE
- Intro
- hasPrismConnection
- doAction
- doDerivation
- doMenuItem
- doPrismDerivation
- setFormField
- runPrismFunction
- @GetDefinition
- . document
- . listcommands
- . listdocuments
- . listdrives
- . listfiles
- . listfunctions
- . listinternals
- . listoperators
- . listrelated
- . listtables
- . object
- . table
- . testdql
- @SetDefinition
- . document
- . object
- Extra modules intro
- python
- Qt
- wkhtmltopdf
- PySide
- PyXCC
- django
- Apache
- LightTPD
- nginx
- pywin32
- flup
- cssutils
- Pillow
- psutil
- mysqldb
- psycopg2
- pyodbc
- python_dateutil
- requests
- suds-ews
- setuptools
- Whoosh
- wmi
- django-send
- bootstrap
- bootstrapmultiselect
- jquery
- jqueryui
- ckedit
- tinymce
- redactor
- JavaScript EU VAT Number Validation
- feedparser
- beautifulsoup
- appsdir
- six
- pycparser
- pyOpenSSL
- cryptography
- cffi
- enum34
- pyasn1
- idna
- ipaddress
- PyYAML
- coverage
- coveralls
- docopt
- mock
- funcsigs
- pbr
- nose
- paypalrestsdk
- paypal
- libcurl
- 7zipcpp
- cef
- cpp-jwt
MemoChunk
Function::Memo
MemoChunk
MemoChunk(MEMO FIELD,NUMERIC VALUE)
MemoChunk(MyMemo,3)To "decompile" or "unwind" a Memo field into 256 long chunks that can be handled by ordinary DataEase functions and saved in Text fields.
Pre DataEase 8 there was no way one could manipulate of use the content of Memo fields. The only way one could add to the was by manually keying in the content and the only way one could exploit the content was via reading it on screen.
In 8 Memo fields are one of the most important field types and visual controls.
We have added a entirely new class of functions simply to manipulate, populate and extract data from memo fields.
MemoChunk() is a function that will simply retrieve a 256 bytes large chunk from a Memo field and return it as a normal text string(256).
The usage of MemoChunk() can be for saving the content of a Virtual Memo Control into normal text fields for indexing, searching etc.
!Hint to legacy DataEase users!
If you have problems with your old style Memo fields being migrated to new style from 6.5x to 7.x you can use this function to unwind your data back into a Fields structure like the old style Memos. You can also use the New Style memo for editing and then unwind it back into a standard field structure.
Parameters
MEMO FIELD
This is the memo field you want to unwind into manageable chunks.
NUMERIC VALUE
This is the number of the 256 byte large chunk you want to retrieve. The first one is 0 and the second one is 1 etc.
Returns/Result
Returns a String(256) that contain the content of the chunk indicated by NUMERIC VALUE. If it returns blank, you have come to the end of the memo. The last Chunk of a memo will be between 1 and 256 bytes long.
Examples
Example 1
To make it easy for the example create we say we have a memo that contain a ledger where each entry is exactly 256 characters long ;-)
Each entry start with the number of the entry and then it continues with the name of the person etc.
First entry is 1. Andy MacNicol, born...Entry 40 starts with 40. Peter Cool born... and entry 1143 starts with 1143. Albin Youn born...MemoChunk(MyMemo,0)
Returns: 1. Andy MacNicol born.... etc for 256 characters.
MemoChunk(MyMemo,39)
Returns: 40. Peter Cool born.... etc...
MemoChunk(MyMemo,1142)
Returns: 1143. Albin Youn born....
(I think you got it now)
Example 2
In this example we see a memo field with a HTMLEdit field control. When the record is saved the content of the memo is split into 4 Text fields by each of the calling.
MemoChunk(MyMemo,0) through MemoChunk(MyMemo,3).
Reference
We have now looked at a lot of functions that manipulate,extend, copy and append to a Memo field.What about "normalising" it again. A lot of you traditionalist, don't and never will trust a memo field, and anyhow, even us "extremists" can't use traditional DataEase functions on a Memo field.
Maybe there is times we want to unwind a Memo field and save it in a normal DataEase table structure. It is not such a big defeat, we can simply rebuild it if we like with the MemoMemoCopy Function etc.
Enter MemoChunk().
string(256) MemoChunk(MemoToChunk,Chunk#)
Chunk# is proper Data techy, 0 is the first, 1 is the second, 2 is the third and on we go...Why make it easy?MemoChunk(MemoToChunk,0) will return the first 256 bytes of the memo field , and MemoChunk(MemoToChunk,1) the next 256 and so we go.
So how do I know when I have reached the end of the Memo?
Firstly this is proper DataEase functionality, it will not GPF even though you try to take a chunk that doesn't exist, so don't worry. It will simply return nothing, like a good little boy, and this is how you can tell that you have come to the end...
When MemoChunk(MemoToChunk,N) returns blank, it is all over.