ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Help / WLanguage / Managing databases / Big Data / Managing Memcached databases
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Others
Stored procedures
Modifies the value of a key if this one was not modified.
Example
MemcachedCAS(memConnection, "key", "value")
Syntax
<Result> = MemcachedCAS(<Connection> , <Key> , <Value> , <Cas> [, <Expiration> [, <Additional value>]])
<Result>: Boolean
  • True if the operation was performed,
  • False if an error occurred. To get more details on the error, use ErrorInfo with the errMessage constant.
<Connection>: memcachedConnection variable
Name of the memcachedConnection variable that corresponds to the connection to Memcached.
<Key>: Character string
Key to modify.
<Value>: Character string or Buffer
Value to store.
<Cas>: Integer
Value of previous version.
<Expiration>: Integer or optional duration
Duration during which the key is stored in the cache. This duration is expressed in seconds. This duration can correspond to:
  • an integer corresponding to the number of seconds,
  • a Duration variable.
  • the direct indication of duration ('10s' for example).
This duration is set to 0 by default. In this case, the duration is unlimited: if there is not enough memory, the oldest keys are deleted.
<Additional value>: Optional integer
Used to store an additional value associated with the Key/Value couple. This parameter can be used to describe the key or the value for example.
Remarks
To use this function, the Memcached server must support CAS (SupportCAS property of the memcachedConnection variable set to True). CAS (Check And Set) is used to perform a data modification only if this data was not modified since it was last read.
Component: wd290big.dll
Minimum version required
  • Version 23
This page is also available for…
Comments
Click [Add] to post a comment

Last update: 05/26/2022

Send a report | Local help