source: proiecte/HadoopJUnit/hadoop-0.20.1/docs/api/org/apache/hadoop/mapred/lib/db/DBOutputFormat.html @ 120

Last change on this file since 120 was 120, checked in by (none), 14 years ago

Added the mail files for the Hadoop JUNit Project

  • Property svn:executable set to *
File size: 24.7 KB
Line 
1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
2<!--NewPage-->
3<HTML>
4<HEAD>
5<!-- Generated by javadoc (build 1.6.0_07) on Tue Sep 01 20:56:57 UTC 2009 -->
6<TITLE>
7DBOutputFormat (Hadoop 0.20.1 API)
8</TITLE>
9
10<META NAME="date" CONTENT="2009-09-01">
11
12<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../../stylesheet.css" TITLE="Style">
13
14<SCRIPT type="text/javascript">
15function windowTitle()
16{
17    if (location.href.indexOf('is-external=true') == -1) {
18        parent.document.title="DBOutputFormat (Hadoop 0.20.1 API)";
19    }
20}
21</SCRIPT>
22<NOSCRIPT>
23</NOSCRIPT>
24
25</HEAD>
26
27<BODY BGCOLOR="white" onload="windowTitle();">
28<HR>
29
30
31<!-- ========= START OF TOP NAVBAR ======= -->
32<A NAME="navbar_top"><!-- --></A>
33<A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35<TR>
36<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37<A NAME="navbar_top_firstrow"><!-- --></A>
38<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39  <TR ALIGN="center" VALIGN="top">
40  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="class-use/DBOutputFormat.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48  </TR>
49</TABLE>
50</TD>
51<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52</EM>
53</TD>
54</TR>
55
56<TR>
57<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58&nbsp;<A HREF="../../../../../../org/apache/hadoop/mapred/lib/db/DBInputFormat.NullDBWritable.html" title="class in org.apache.hadoop.mapred.lib.db"><B>PREV CLASS</B></A>&nbsp;
59&nbsp;<A HREF="../../../../../../org/apache/hadoop/mapred/lib/db/DBOutputFormat.DBRecordWriter.html" title="class in org.apache.hadoop.mapred.lib.db"><B>NEXT CLASS</B></A></FONT></TD>
60<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61  <A HREF="../../../../../../index.html?org/apache/hadoop/mapred/lib/db/DBOutputFormat.html" target="_top"><B>FRAMES</B></A>  &nbsp;
62&nbsp;<A HREF="DBOutputFormat.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;
63&nbsp;<SCRIPT type="text/javascript">
64  <!--
65  if(window==top) {
66    document.writeln('<A HREF="../../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67  }
68  //-->
69</SCRIPT>
70<NOSCRIPT>
71  <A HREF="../../../../../../allclasses-noframe.html"><B>All Classes</B></A>
72</NOSCRIPT>
73
74
75</FONT></TD>
76</TR>
77<TR>
78<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79  SUMMARY:&nbsp;<A HREF="#nested_class_summary">NESTED</A>&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
80<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
82</TR>
83</TABLE>
84<A NAME="skip-navbar_top"></A>
85<!-- ========= END OF TOP NAVBAR ========= -->
86
87<HR>
88<!-- ======== START OF CLASS DATA ======== -->
89<H2>
90<FONT SIZE="-1">
91org.apache.hadoop.mapred.lib.db</FONT>
92<BR>
93Class DBOutputFormat&lt;K extends <A HREF="../../../../../../org/apache/hadoop/mapred/lib/db/DBWritable.html" title="interface in org.apache.hadoop.mapred.lib.db">DBWritable</A>,V&gt;</H2>
94<PRE>
95<A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</A>
96  <IMG SRC="../../../../../../resources/inherit.gif" ALT="extended by "><B>org.apache.hadoop.mapred.lib.db.DBOutputFormat&lt;K,V&gt;</B>
97</PRE>
98<DL>
99<DT><B>All Implemented Interfaces:</B> <DD><A HREF="../../../../../../org/apache/hadoop/mapred/OutputFormat.html" title="interface in org.apache.hadoop.mapred">OutputFormat</A>&lt;K,V&gt;</DD>
100</DL>
101<HR>
102<DL>
103<DT><PRE>public class <B>DBOutputFormat&lt;K extends <A HREF="../../../../../../org/apache/hadoop/mapred/lib/db/DBWritable.html" title="interface in org.apache.hadoop.mapred.lib.db">DBWritable</A>,V&gt;</B><DT>extends <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A><DT>implements <A HREF="../../../../../../org/apache/hadoop/mapred/OutputFormat.html" title="interface in org.apache.hadoop.mapred">OutputFormat</A>&lt;K,V&gt;</DL>
104</PRE>
105
106<P>
107A OutputFormat that sends the reduce output to a SQL table.
108 <p> 
109 <A HREF="../../../../../../org/apache/hadoop/mapred/lib/db/DBOutputFormat.html" title="class in org.apache.hadoop.mapred.lib.db"><CODE>DBOutputFormat</CODE></A> accepts &lt;key,value&gt; pairs, where
110 key has a type extending DBWritable. Returned <A HREF="../../../../../../org/apache/hadoop/mapred/lib/db/DBOutputFormat.DBRecordWriter.html" title="class in org.apache.hadoop.mapred.lib.db"><CODE>DBOutputFormat.DBRecordWriter</CODE></A> 
111 writes <b>only the key</b> to the database with a batch SQL query.
112<P>
113
114<P>
115<HR>
116
117<P>
118<!-- ======== NESTED CLASS SUMMARY ======== -->
119
120<A NAME="nested_class_summary"><!-- --></A>
121<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
122<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
123<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
124<B>Nested Class Summary</B></FONT></TH>
125</TR>
126<TR BGCOLOR="white" CLASS="TableRowColor">
127<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
128<CODE>protected &nbsp;class</CODE></FONT></TD>
129<TD><CODE><B><A HREF="../../../../../../org/apache/hadoop/mapred/lib/db/DBOutputFormat.DBRecordWriter.html" title="class in org.apache.hadoop.mapred.lib.db">DBOutputFormat.DBRecordWriter</A></B></CODE>
130
131<BR>
132&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;A RecordWriter that writes the reduce output to a SQL table</TD>
133</TR>
134</TABLE>
135&nbsp;
136<!-- ======== CONSTRUCTOR SUMMARY ======== -->
137
138<A NAME="constructor_summary"><!-- --></A>
139<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
140<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
141<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
142<B>Constructor Summary</B></FONT></TH>
143</TR>
144<TR BGCOLOR="white" CLASS="TableRowColor">
145<TD><CODE><B><A HREF="../../../../../../org/apache/hadoop/mapred/lib/db/DBOutputFormat.html#DBOutputFormat()">DBOutputFormat</A></B>()</CODE>
146
147<BR>
148&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
149</TR>
150</TABLE>
151&nbsp;
152<!-- ========== METHOD SUMMARY =========== -->
153
154<A NAME="method_summary"><!-- --></A>
155<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
156<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
157<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
158<B>Method Summary</B></FONT></TH>
159</TR>
160<TR BGCOLOR="white" CLASS="TableRowColor">
161<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
162<CODE>&nbsp;void</CODE></FONT></TD>
163<TD><CODE><B><A HREF="../../../../../../org/apache/hadoop/mapred/lib/db/DBOutputFormat.html#checkOutputSpecs(org.apache.hadoop.fs.FileSystem, org.apache.hadoop.mapred.JobConf)">checkOutputSpecs</A></B>(<A HREF="../../../../../../org/apache/hadoop/fs/FileSystem.html" title="class in org.apache.hadoop.fs">FileSystem</A>&nbsp;filesystem,
164                 <A HREF="../../../../../../org/apache/hadoop/mapred/JobConf.html" title="class in org.apache.hadoop.mapred">JobConf</A>&nbsp;job)</CODE>
165
166<BR>
167&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Check for validity of the output-specification for the job.</TD>
168</TR>
169<TR BGCOLOR="white" CLASS="TableRowColor">
170<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
171<CODE>protected &nbsp;<A HREF="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A></CODE></FONT></TD>
172<TD><CODE><B><A HREF="../../../../../../org/apache/hadoop/mapred/lib/db/DBOutputFormat.html#constructQuery(java.lang.String, java.lang.String[])">constructQuery</A></B>(<A HREF="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;table,
173               <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>[]&nbsp;fieldNames)</CODE>
174
175<BR>
176&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Constructs the query used as the prepared statement to insert data.</TD>
177</TR>
178<TR BGCOLOR="white" CLASS="TableRowColor">
179<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
180<CODE>&nbsp;<A HREF="../../../../../../org/apache/hadoop/mapred/RecordWriter.html" title="interface in org.apache.hadoop.mapred">RecordWriter</A>&lt;<A HREF="../../../../../../org/apache/hadoop/mapred/lib/db/DBOutputFormat.html" title="type parameter in DBOutputFormat">K</A>,<A HREF="../../../../../../org/apache/hadoop/mapred/lib/db/DBOutputFormat.html" title="type parameter in DBOutputFormat">V</A>&gt;</CODE></FONT></TD>
181<TD><CODE><B><A HREF="../../../../../../org/apache/hadoop/mapred/lib/db/DBOutputFormat.html#getRecordWriter(org.apache.hadoop.fs.FileSystem, org.apache.hadoop.mapred.JobConf, java.lang.String, org.apache.hadoop.util.Progressable)">getRecordWriter</A></B>(<A HREF="../../../../../../org/apache/hadoop/fs/FileSystem.html" title="class in org.apache.hadoop.fs">FileSystem</A>&nbsp;filesystem,
182                <A HREF="../../../../../../org/apache/hadoop/mapred/JobConf.html" title="class in org.apache.hadoop.mapred">JobConf</A>&nbsp;job,
183                <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;name,
184                <A HREF="../../../../../../org/apache/hadoop/util/Progressable.html" title="interface in org.apache.hadoop.util">Progressable</A>&nbsp;progress)</CODE>
185
186<BR>
187&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Get the <A HREF="../../../../../../org/apache/hadoop/mapred/RecordWriter.html" title="interface in org.apache.hadoop.mapred"><CODE>RecordWriter</CODE></A> for the given job.</TD>
188</TR>
189<TR BGCOLOR="white" CLASS="TableRowColor">
190<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
191<CODE>static&nbsp;void</CODE></FONT></TD>
192<TD><CODE><B><A HREF="../../../../../../org/apache/hadoop/mapred/lib/db/DBOutputFormat.html#setOutput(org.apache.hadoop.mapred.JobConf, java.lang.String, java.lang.String...)">setOutput</A></B>(<A HREF="../../../../../../org/apache/hadoop/mapred/JobConf.html" title="class in org.apache.hadoop.mapred">JobConf</A>&nbsp;job,
193          <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;tableName,
194          <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>...&nbsp;fieldNames)</CODE>
195
196<BR>
197&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Initializes the reduce-part of the job with the appropriate output settings</TD>
198</TR>
199</TABLE>
200&nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
201<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
202<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
203<TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></B></TH>
204</TR>
205<TR BGCOLOR="white" CLASS="TableRowColor">
206<TD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#clone()" title="class or interface in java.lang">clone</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.lang">equals</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#finalize()" title="class or interface in java.lang">finalize</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#getClass()" title="class or interface in java.lang">getClass</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#hashCode()" title="class or interface in java.lang">hashCode</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#notify()" title="class or interface in java.lang">notify</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#notifyAll()" title="class or interface in java.lang">notifyAll</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#toString()" title="class or interface in java.lang">toString</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#wait()" title="class or interface in java.lang">wait</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#wait(long)" title="class or interface in java.lang">wait</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD>
207</TR>
208</TABLE>
209&nbsp;
210<P>
211
212<!-- ========= CONSTRUCTOR DETAIL ======== -->
213
214<A NAME="constructor_detail"><!-- --></A>
215<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
216<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
217<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
218<B>Constructor Detail</B></FONT></TH>
219</TR>
220</TABLE>
221
222<A NAME="DBOutputFormat()"><!-- --></A><H3>
223DBOutputFormat</H3>
224<PRE>
225public <B>DBOutputFormat</B>()</PRE>
226<DL>
227</DL>
228
229<!-- ============ METHOD DETAIL ========== -->
230
231<A NAME="method_detail"><!-- --></A>
232<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
233<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
234<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
235<B>Method Detail</B></FONT></TH>
236</TR>
237</TABLE>
238
239<A NAME="constructQuery(java.lang.String, java.lang.String[])"><!-- --></A><H3>
240constructQuery</H3>
241<PRE>
242protected <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A> <B>constructQuery</B>(<A HREF="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;table,
243                                <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>[]&nbsp;fieldNames)</PRE>
244<DL>
245<DD>Constructs the query used as the prepared statement to insert data.
246<P>
247<DD><DL>
248</DL>
249</DD>
250<DD><DL>
251<DT><B>Parameters:</B><DD><CODE>table</CODE> - the table to insert into<DD><CODE>fieldNames</CODE> - the fields to insert into. If field names are unknown, supply an
252          array of nulls.</DL>
253</DD>
254</DL>
255<HR>
256
257<A NAME="checkOutputSpecs(org.apache.hadoop.fs.FileSystem, org.apache.hadoop.mapred.JobConf)"><!-- --></A><H3>
258checkOutputSpecs</H3>
259<PRE>
260public void <B>checkOutputSpecs</B>(<A HREF="../../../../../../org/apache/hadoop/fs/FileSystem.html" title="class in org.apache.hadoop.fs">FileSystem</A>&nbsp;filesystem,
261                             <A HREF="../../../../../../org/apache/hadoop/mapred/JobConf.html" title="class in org.apache.hadoop.mapred">JobConf</A>&nbsp;job)
262                      throws <A HREF="http://java.sun.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
263<DL>
264<DD>Check for validity of the output-specification for the job.
265 
266 <p>This is to validate the output specification for the job when it is
267 a job is submitted.  Typically checks that it does not already exist,
268 throwing an exception when it already exists, so that output is not
269 overwritten.</p>
270<P>
271<DD><DL>
272<DT><B>Specified by:</B><DD><CODE><A HREF="../../../../../../org/apache/hadoop/mapred/OutputFormat.html#checkOutputSpecs(org.apache.hadoop.fs.FileSystem, org.apache.hadoop.mapred.JobConf)">checkOutputSpecs</A></CODE> in interface <CODE><A HREF="../../../../../../org/apache/hadoop/mapred/OutputFormat.html" title="interface in org.apache.hadoop.mapred">OutputFormat</A>&lt;<A HREF="../../../../../../org/apache/hadoop/mapred/lib/db/DBOutputFormat.html" title="type parameter in DBOutputFormat">K</A> extends <A HREF="../../../../../../org/apache/hadoop/mapred/lib/db/DBWritable.html" title="interface in org.apache.hadoop.mapred.lib.db">DBWritable</A>,<A HREF="../../../../../../org/apache/hadoop/mapred/lib/db/DBOutputFormat.html" title="type parameter in DBOutputFormat">V</A>&gt;</CODE></DL>
273</DD>
274<DD><DL>
275<DD><CODE>job</CODE> - job configuration.
276<DT><B>Throws:</B>
277<DD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE> - when output should not be attempted</DL>
278</DD>
279</DL>
280<HR>
281
282<A NAME="getRecordWriter(org.apache.hadoop.fs.FileSystem, org.apache.hadoop.mapred.JobConf, java.lang.String, org.apache.hadoop.util.Progressable)"><!-- --></A><H3>
283getRecordWriter</H3>
284<PRE>
285public <A HREF="../../../../../../org/apache/hadoop/mapred/RecordWriter.html" title="interface in org.apache.hadoop.mapred">RecordWriter</A>&lt;<A HREF="../../../../../../org/apache/hadoop/mapred/lib/db/DBOutputFormat.html" title="type parameter in DBOutputFormat">K</A>,<A HREF="../../../../../../org/apache/hadoop/mapred/lib/db/DBOutputFormat.html" title="type parameter in DBOutputFormat">V</A>&gt; <B>getRecordWriter</B>(<A HREF="../../../../../../org/apache/hadoop/fs/FileSystem.html" title="class in org.apache.hadoop.fs">FileSystem</A>&nbsp;filesystem,
286                                         <A HREF="../../../../../../org/apache/hadoop/mapred/JobConf.html" title="class in org.apache.hadoop.mapred">JobConf</A>&nbsp;job,
287                                         <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;name,
288                                         <A HREF="../../../../../../org/apache/hadoop/util/Progressable.html" title="interface in org.apache.hadoop.util">Progressable</A>&nbsp;progress)
289                                                     throws <A HREF="http://java.sun.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
290<DL>
291<DD>Get the <A HREF="../../../../../../org/apache/hadoop/mapred/RecordWriter.html" title="interface in org.apache.hadoop.mapred"><CODE>RecordWriter</CODE></A> for the given job.
292<P>
293<DD><DL>
294<DT><B>Specified by:</B><DD><CODE><A HREF="../../../../../../org/apache/hadoop/mapred/OutputFormat.html#getRecordWriter(org.apache.hadoop.fs.FileSystem, org.apache.hadoop.mapred.JobConf, java.lang.String, org.apache.hadoop.util.Progressable)">getRecordWriter</A></CODE> in interface <CODE><A HREF="../../../../../../org/apache/hadoop/mapred/OutputFormat.html" title="interface in org.apache.hadoop.mapred">OutputFormat</A>&lt;<A HREF="../../../../../../org/apache/hadoop/mapred/lib/db/DBOutputFormat.html" title="type parameter in DBOutputFormat">K</A> extends <A HREF="../../../../../../org/apache/hadoop/mapred/lib/db/DBWritable.html" title="interface in org.apache.hadoop.mapred.lib.db">DBWritable</A>,<A HREF="../../../../../../org/apache/hadoop/mapred/lib/db/DBOutputFormat.html" title="type parameter in DBOutputFormat">V</A>&gt;</CODE></DL>
295</DD>
296<DD><DL>
297<DD><CODE>job</CODE> - configuration for the job whose output is being written.<DD><CODE>name</CODE> - the unique name for this part of the output.<DD><CODE>progress</CODE> - mechanism for reporting progress while writing to file.
298<DT><B>Returns:</B><DD>a <A HREF="../../../../../../org/apache/hadoop/mapred/RecordWriter.html" title="interface in org.apache.hadoop.mapred"><CODE>RecordWriter</CODE></A> to write the output for the job.
299<DT><B>Throws:</B>
300<DD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE></DL>
301</DD>
302</DL>
303<HR>
304
305<A NAME="setOutput(org.apache.hadoop.mapred.JobConf, java.lang.String, java.lang.String...)"><!-- --></A><H3>
306setOutput</H3>
307<PRE>
308public static void <B>setOutput</B>(<A HREF="../../../../../../org/apache/hadoop/mapred/JobConf.html" title="class in org.apache.hadoop.mapred">JobConf</A>&nbsp;job,
309                             <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;tableName,
310                             <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>...&nbsp;fieldNames)</PRE>
311<DL>
312<DD>Initializes the reduce-part of the job with the appropriate output settings
313<P>
314<DD><DL>
315</DL>
316</DD>
317<DD><DL>
318<DT><B>Parameters:</B><DD><CODE>job</CODE> - The job<DD><CODE>tableName</CODE> - The table to insert data into<DD><CODE>fieldNames</CODE> - The field names in the table. If unknown, supply the appropriate
319          number of nulls.</DL>
320</DD>
321</DL>
322<!-- ========= END OF CLASS DATA ========= -->
323<HR>
324
325
326<!-- ======= START OF BOTTOM NAVBAR ====== -->
327<A NAME="navbar_bottom"><!-- --></A>
328<A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
329<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
330<TR>
331<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
332<A NAME="navbar_bottom_firstrow"><!-- --></A>
333<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
334  <TR ALIGN="center" VALIGN="top">
335  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
336  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
337  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
338  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="class-use/DBOutputFormat.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
339  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
340  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
341  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
342  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
343  </TR>
344</TABLE>
345</TD>
346<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
347</EM>
348</TD>
349</TR>
350
351<TR>
352<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
353&nbsp;<A HREF="../../../../../../org/apache/hadoop/mapred/lib/db/DBInputFormat.NullDBWritable.html" title="class in org.apache.hadoop.mapred.lib.db"><B>PREV CLASS</B></A>&nbsp;
354&nbsp;<A HREF="../../../../../../org/apache/hadoop/mapred/lib/db/DBOutputFormat.DBRecordWriter.html" title="class in org.apache.hadoop.mapred.lib.db"><B>NEXT CLASS</B></A></FONT></TD>
355<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
356  <A HREF="../../../../../../index.html?org/apache/hadoop/mapred/lib/db/DBOutputFormat.html" target="_top"><B>FRAMES</B></A>  &nbsp;
357&nbsp;<A HREF="DBOutputFormat.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;
358&nbsp;<SCRIPT type="text/javascript">
359  <!--
360  if(window==top) {
361    document.writeln('<A HREF="../../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
362  }
363  //-->
364</SCRIPT>
365<NOSCRIPT>
366  <A HREF="../../../../../../allclasses-noframe.html"><B>All Classes</B></A>
367</NOSCRIPT>
368
369
370</FONT></TD>
371</TR>
372<TR>
373<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
374  SUMMARY:&nbsp;<A HREF="#nested_class_summary">NESTED</A>&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
375<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
376DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
377</TR>
378</TABLE>
379<A NAME="skip-navbar_bottom"></A>
380<!-- ======== END OF BOTTOM NAVBAR ======= -->
381
382<HR>
383Copyright &copy; 2009 The Apache Software Foundation
384</BODY>
385</HTML>
Note: See TracBrowser for help on using the repository browser.