.TH "md_doc_help_kdb-sget" 3elektra "Sun May 29 2016" "Version 0.8.14" "Elektra" \" -*- nroff -*- .ad l .nh .SH NAME md_doc_help_kdb-sget \- kdb-sget(1) -- Get the value of a key stored in the key database from a script \fCkdb sget \fP .PP Where \fCpath\fP is the full path to the key and \fCdefault-value\fP is the value that should be printed if no value can be retrieved\&. .PP .SS "DESCRIPTION" .PP This command is used to retrieve the value of a key from within a script\&. When using the kdb tool in a script, the user should use the \fCsget\fP command in place of the kdb-get(1) command\&. The kdb-get(1) command should not be used in scripts because it may return an error instead of printing a value in certain circumstances\&. The \fCsget\fP command guarantees that a value will be printed (unless the user passes faulty arugments)\&. This command will either print the value of the key it retrives or a default value that the user specifies\&. .PP .SS "EXAMPLES" .PP To get the value of a key from a script or return the value \fC0\fP: \fCkdb sget user/example/key 0\fP .PP To get the value of a key using a cascading lookup or return the value \fCnotfound\fP: \fCkdb get /example/key 'notfound'\fP .PP .SS "SEE ALSO" .PP .IP "\(bu" 2 \fBkdb-get(1)\fP .PP