Index: src/docs/src/documentation/content/xdocs/inputoutput.xml =================================================================== --- src/docs/src/documentation/content/xdocs/inputoutput.xml (revision 1311550) +++ src/docs/src/documentation/content/xdocs/inputoutput.xml (working copy) @@ -162,7 +162,7 @@ -
Examples
+Read Example
The following very simple MapReduce program reads data from one table which it assumes to have an integer in the @@ -266,9 +266,16 @@
To scan just selected partitions of a table, a filter describing the desired partitions can be passed to -InputJobInfo.create. This filter can contain the operators '=', '<', '>', '<=', -'>=', '<>', 'and', 'or', and 'like'. Assume for example you have a web_logs -table that is partitioned by the column datestamp. You could select one partition of the table by changing
+InputJobInfo.create. To scan a single filter, the filter string should look like: "ds=20120401" where ds is the partition column name and 20120401 is the value you want to read. + +Filter Operators
+ +A filter can contain the operators 'and', 'or', 'like', '()', '=', '<>', '<', '>', '<=' +and '>='.
+ +Scan Filter
+ +Assume for example you have a web_logs table that is partitioned by the column datestamp. You could select one partition of the table by changing
This filter must reference only partition columns. Values from other columns will cause the job to fail.
+ +Write Filter
To write to a single partition you can change the above example to have a Map of key value pairs that describe all of the partition keys and values for that partition. In our example web_logs table, there is only one partition Index: src/docs/src/documentation/content/xdocs/loadstore.xml =================================================================== --- src/docs/src/documentation/content/xdocs/loadstore.xml (revision 1311550) +++ src/docs/src/documentation/content/xdocs/loadstore.xml (working copy) @@ -28,7 +28,7 @@
The HCatLoader and HCatStorer interfaces are used with Pig scripts to read and write data in HCatalog managed tables.
-Authentication
+ @@ -115,12 +115,22 @@Authentication
If you are using a secure cluster and a failure results in a message like "2010-11-03 16:17:28,225 WARN hive.metastore ... - Unable to connect metastore with URI thrift://..." in /tmp/<username>/hive.log, then make sure you have run "kinit <username>@FOO.COM" to get a Kerberos ticket and to be able to authenticate to the HCatalog server. |
@@ -192,6 +202,11 @@
b = filter a by datestamp >= '20110924' and datestamp <= '20110925';
+