1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139
|
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="expires" content="0" />
<meta http-equiv="cache-control" content="no-cache" />
<meta http-equiv="pragma" content="no-cache" />
<meta name="author" content="Dominik Reichl" />
<meta name="DC.title" content="Field References - KeePass" />
<meta name="DC.creator" content="Dominik Reichl" />
<meta name="DC.type" content="Text" />
<meta name="DC.format" content="text/html" />
<meta name="DC.language" content="en" />
<meta name="DC.rights" content="Copyright (C) 2003-2019 Dominik Reichl" />
<meta name="robots" content="index, follow" />
<meta name="flattr:id" content="42rykv" />
<title>Field References - KeePass</title>
<base target="_self" />
<link rel="stylesheet" type="text/css" href="../../default.css" />
</head>
<body>
<table class="sectionsummary"><tr><td width="68">
<img src="../images/b64x64_usb.png" width="64" height="64"
class="singleimg" align="left" alt="Split" />
</td><td valign="middle"><h1>Field References</h1><br />
How to put references to data in fields of other entries.
</td></tr></table>
<ul>
<li><a href="#intro">Introduction</a></li>
<li><a href="#syntax">Placeholder Syntax</a></li>
<li><a href="#example">Example</a></li>
</ul>
<br />
<a name="intro"></a>
<h2 class="sectiontitle"><img src="../images/b16x16_help.png"
class="singleimg" alt="Text" /> Introduction</h2>
<p>KeePass can insert data stored in different
entries into fields of an entry.
This means that multiple entries can share a common
field (user name, password, ...), and by changing the actual data entry,
all other entries will also use the new value.</p>
<p>To create a field reference, you can either use the
convenient field references wizard (in the entry editing window,
click the 'Tools' button at the bottom left and select
'Insert Field Reference'), or insert the placeholder manually
(see the syntax below).</p>
<p>Note that field references are intended for referencing data stored
in <i>different</i> entries. If you want to insert data from the
<i>same/current</i> entry, you should use local placeholders, like
<code>{TITLE}</code> and <code>{S:<i>FieldName</i>}</code>;
see <a href="placeholders.html">Placeholders</a>.</p>
<br />
<a name="syntax"></a>
<h2 class="sectiontitle"><img src="../images/b16x16_rotate_cw.png"
class="singleimg" alt="Text" /> Placeholder Syntax</h2>
<p>The placeholder syntax for field references is the following:</p>
<p><code>{REF:<i><WantedField></i>@<i><SearchIn></i>:<i><Text></i>}</code></p>
<p>The <i>WantedField</i> and <i>SearchIn</i> parts need to be replaced by
1-letter codes identifying the field:</p>
<table class="tablebox75">
<tr><th width="25%">Code</th><th width="75%">Field</th></tr>
<tr><td width="25%">T</td><td width="75%">Title</td></tr>
<tr><td width="25%">U</td><td width="75%">User name</td></tr>
<tr><td width="25%">P</td><td width="75%">Password</td></tr>
<tr><td width="25%">A</td><td width="75%">URL</td></tr>
<tr><td width="25%">N</td><td width="75%">Notes</td></tr>
<tr><td width="25%">I</td><td width="75%">UUID</td></tr>
<tr><td width="25%">O</td><td width="75%">Other custom strings <i>(KeePass 2.x only)</i></td></tr>
</table>
<p>The <i>Text</i> part is the <a href="https://keepass.info/help/kb/faq.html#search"
target="_blank">search string</a>, which describes the text(s)
that must occur in the specified field of an entry to match.</p>
<p>If multiple entries match the specified search criterion, the first
entry will be used.
To avoid ambiguity, entries can be identified by their UUIDs, which are unique.
Example:
<code>{REF:P@I:46C9B1FFBD4ABC4BBB260C6190BAD20C}</code> would insert the
password of the entry having 46C9B1FFBD4ABC4BBB260C6190BAD20C as UUID.</p>
Referencing fields of other entries only works with standard fields, not
with custom user strings.
If you want to reference a custom user string, you need
to place a redirection in a standard field of the entry with the custom string,
using <code>{S:<i><Name></i>}</code>,
and reference the standard field.<br />
<br />
Custom strings can locally (i.e. within an entry) be referenced using
<code>{S:<i><Name></i>}</code>,
see the page <a href="placeholders.html">Placeholders</a> for details.<br />
<br />
You can use the <code>O</code> code to make KeePass search the database for
custom string fields (to identify the referenced source entry),
but <code>O</code> cannot be used to retrieve data from custom fields (i.e. the
code can't be used as <i>WantedField</i>).
<br />
<br />
<a name="example"></a>
<h2 class="sectiontitle"><img src="../images/b16x16_help.png"
class="singleimg" alt="Text" /> Example</h2>
<p>Let's assume you have two entries: one with title "Example Website"
and one with "Example Forum", and you want to insert the user name
of the website account into the URL of the forum entry. Within the forum entry's
URL, you could reference the user name like this:<br />
<code>https://forum.example.com/?user={REF:U@T:Example Website}</code></p>
</body></html>
|