source: www/manuals/PHP_manual/function.pg-escape-bytea.html@ 1

Last change on this file since 1 was 1, checked in by george, 17 years ago

Prvotní import všeho

File size: 3.4 KB
Line 
1<HTML
2><HEAD
3><TITLE
4>pg_escape_bytea</TITLE
5><META
6NAME="GENERATOR"
7CONTENT="Modular DocBook HTML Stylesheet Version 1.7"><LINK
8REL="HOME"
9TITLE="Manuál PHP"
10HREF="index.html"><LINK
11REL="UP"
12TITLE="PostgreSQL functions"
13HREF="ref.pgsql.html"><LINK
14REL="PREVIOUS"
15TITLE="pg_end_copy"
16HREF="function.pg-end-copy.html"><LINK
17REL="NEXT"
18TITLE="pg_escape_string"
19HREF="function.pg-escape-string.html"><META
20HTTP-EQUIV="Content-type"
21CONTENT="text/html; charset=ISO-8859-2"></HEAD
22><BODY
23CLASS="refentry"
24BGCOLOR="#FFFFFF"
25TEXT="#000000"
26LINK="#0000FF"
27VLINK="#840084"
28ALINK="#0000FF"
29><DIV
30CLASS="NAVHEADER"
31><TABLE
32SUMMARY="Header navigation table"
33WIDTH="100%"
34BORDER="0"
35CELLPADDING="0"
36CELLSPACING="0"
37><TR
38><TH
39COLSPAN="3"
40ALIGN="center"
41>Manuál PHP</TH
42></TR
43><TR
44><TD
45WIDTH="10%"
46ALIGN="left"
47VALIGN="bottom"
48><A
49HREF="function.pg-end-copy.html"
50ACCESSKEY="P"
51>Pøedcházející</A
52></TD
53><TD
54WIDTH="80%"
55ALIGN="center"
56VALIGN="bottom"
57></TD
58><TD
59WIDTH="10%"
60ALIGN="right"
61VALIGN="bottom"
62><A
63HREF="function.pg-escape-string.html"
64ACCESSKEY="N"
65>Dal¹í</A
66></TD
67></TR
68></TABLE
69><HR
70ALIGN="LEFT"
71WIDTH="100%"></DIV
72><H1
73><A
74NAME="function.pg-escape-bytea"
75></A
76>pg_escape_bytea</H1
77><DIV
78CLASS="refnamediv"
79><A
80NAME="AEN70264"
81></A
82><P
83> (PHP 4 &#62;= 4.2.0)</P
84>pg_escape_bytea&nbsp;--&nbsp;
85 Escape binary for bytea type
86 </DIV
87><DIV
88CLASS="refsect1"
89><A
90NAME="AEN70267"
91></A
92><H2
93>Description</H2
94>string <B
95CLASS="methodname"
96>pg_escape_bytea</B
97> ( string data)<BR
98></BR
99><P
100>&#13; <B
101CLASS="function"
102>pg_escape_bytea()</B
103> escapes string for
104 bytea datatype. It returns escaped string.
105 </P
106><DIV
107CLASS="note"
108><BLOCKQUOTE
109CLASS="note"
110><P
111><B
112>Poznámka: </B
113>
114 When you SELECT bytea type, PostgreSQL returns octal byte value
115 prefixed by \ (e.g. \032). Users are supposed to convert back to
116 binary format by yourself.
117 </P
118><P
119>&#13; This function requires PostgreSQL 7.2 or later. With PostgreSQL
120 7.2.0 and 7.2.1, bytea type must be casted when you enable
121 multi-byte support. i.e. <TT
122CLASS="literal"
123>INSERT INTO test_table (image)
124 VALUES ('$image_escaped'::bytea);</TT
125> PostgreSQL 7.2.2 or
126 later does not need cast. Exception is when client and backend
127 character encoding does not match, there may be multi-byte
128 stream error. User must cast to bytea to avoid this error.
129 </P
130><P
131>&#13; Newer PostgreSQL will support unescape function. Support for
132 built-in unescape function will be added when it's available.
133 </P
134></BLOCKQUOTE
135></DIV
136><P
137>&#13; See also <A
138HREF="function.pg-escape-string.html"
139><B
140CLASS="function"
141>pg_escape_string()</B
142></A
143>
144 </P
145></DIV
146><DIV
147CLASS="NAVFOOTER"
148><HR
149ALIGN="LEFT"
150WIDTH="100%"><TABLE
151SUMMARY="Footer navigation table"
152WIDTH="100%"
153BORDER="0"
154CELLPADDING="0"
155CELLSPACING="0"
156><TR
157><TD
158WIDTH="33%"
159ALIGN="left"
160VALIGN="top"
161><A
162HREF="function.pg-end-copy.html"
163ACCESSKEY="P"
164>Pøedcházející</A
165></TD
166><TD
167WIDTH="34%"
168ALIGN="center"
169VALIGN="top"
170><A
171HREF="index.html"
172ACCESSKEY="H"
173>Domù</A
174></TD
175><TD
176WIDTH="33%"
177ALIGN="right"
178VALIGN="top"
179><A
180HREF="function.pg-escape-string.html"
181ACCESSKEY="N"
182>Dal¹í</A
183></TD
184></TR
185><TR
186><TD
187WIDTH="33%"
188ALIGN="left"
189VALIGN="top"
190>pg_end_copy</TD
191><TD
192WIDTH="34%"
193ALIGN="center"
194VALIGN="top"
195><A
196HREF="ref.pgsql.html"
197ACCESSKEY="U"
198>Nahoru</A
199></TD
200><TD
201WIDTH="33%"
202ALIGN="right"
203VALIGN="top"
204>pg_escape_string</TD
205></TR
206></TABLE
207></DIV
208></BODY
209></HTML
210>
Note: See TracBrowser for help on using the repository browser.