Guest User

Untitled

a guest
May 22nd, 2018
109
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 8.18 KB | None | 0 0
  1. Beeline version 3.0.0.3.0.0.0-1320 by Apache Hive
  2. 0: jdbc:hive2://localhost:10000> CREATE TABLE IF NOT EXISTS trucks( driverid string, truckid string, model string, jun13_miles int, jun13_gas int, may13_miles int, may13_gas int, apr13_miles int, apr13_gas int, mar13_miles int, mar13_gas int, feb13_miles int, feb13_gas int, jan13_miles int, jan13_gas int, dec12_miles int, dec12_gas int, nov12_miles int, nov12_gas int, oct12_miles int, oct12_gas int, sep12_miles int, sep12_gas int, aug12_miles int, aug12_gas int, jul12_miles int, jul12_gas int, jun12_miles int, jun12_gas int, may12_miles int, may12_gas int, apr12_miles int, apr12_gas int, mar12_miles int, mar12_gas int, feb12_miles int, feb12_gas int, jan12_miles int, jan12_gas int, dec11_miles int, dec11_gas int, nov11_miles int, nov11_gas int, oct11_miles int, oct11_gas int, sep11_miles int, sep11_gas int, aug11_miles int, aug11_gas int, jul11_miles int, jul11_gas int, jun11_miles int, jun11_gas int, may11_miles int, may11_gas int, apr11_miles int, apr11_gas int, mar11_miles int, mar11_gas int, feb11_miles int, feb11_gas int, jan11_miles int, jan11_gas int, dec10_miles int, dec10_gas int, nov10_miles int, nov10_gas int, oct10_miles int, oct10_gas int, sep10_miles int, sep10_gas int, aug10_miles int, aug10_gas int, jul10_miles int, jul10_gas int, jun10_miles int, jun10_gas int, may10_miles int, may10_gas int, apr10_miles int, apr10_gas int, mar10_miles int, mar10_gas int, feb10_miles int, feb10_gas int, jan10_miles int, jan10_gas int, dec09_miles int, dec09_gas int, nov09_miles int, nov09_gas int, oct09_miles int, oct09_gas int, sep09_miles int, sep09_gas int, aug09_miles int, aug09_gas int, jul09_miles int, jul09_gas int, jun09_miles int, jun09_gas int, may09_miles int, may09_gas int, apr09_miles int, apr09_gas int, mar09_miles int, mar09_gas int, feb09_miles int, feb09_gas int, jan09_miles int, jan09_gas int)
  3. . . . . . . . . . . . . . . . .> ROW FORMAT delimited fields terminated by ','
  4. . . . . . . . . . . . . . . . .> LOCATION
  5. . . . . . . . . . . . . . . . .> 'hdfs://sandbox-hdp.hortonworks.com:8020/apps/hive/warehouse/trucks'
  6. . . . . . . . . . . . . . . . .> TBLPROPERTIES (
  7. . . . . . . . . . . . . . . . .> 'COLUMN_STATS_ACCURATE={\"BASIC_STATS\":\"true\"},
  8. . . . . . . . . . . . . . . . .> numFiles=1,
  9. . . . . . . . . . . . . . . . .> numRows=100,
  10. . . . . . . . . . . . . . . . .> rawDataSize=69500,
  11. . . . . . . . . . . . . . . . .> totalSize=28674,
  12. . . . . . . . . . . . . . . . .> transient_lastDdlTime=1517406950');
  13. INFO : Compiling command(queryId=hive_20180517120247_3f674187-17d2-480a-85bd-b07672491010): CREATE TABLE IF NOT EXISTS trucks( driverid string, truckid string, model string, jun13_miles int, jun13_gas int, may13_miles int, may13_gas int, apr13_miles int, apr13_gas int, mar13_miles int, mar13_gas int, feb13_miles int, feb13_gas int, jan13_miles int, jan13_gas int, dec12_miles int, dec12_gas int, nov12_miles int, nov12_gas int, oct12_miles int, oct12_gas int, sep12_miles int, sep12_gas int, aug12_miles int, aug12_gas int, jul12_miles int, jul12_gas int, jun12_miles int, jun12_gas int, may12_miles int, may12_gas int, apr12_miles int, apr12_gas int, mar12_miles int, mar12_gas int, feb12_miles int, feb12_gas int, jan12_miles int, jan12_gas int, dec11_miles int, dec11_gas int, nov11_miles int, nov11_gas int, oct11_miles int, oct11_gas int, sep11_miles int, sep11_gas int, aug11_miles int, aug11_gas int, jul11_miles int, jul11_gas int, jun11_miles int, jun11_gas int, may11_miles int, may11_gas int, apr11_miles int, apr11_gas int, mar11_miles int, mar11_gas int, feb11_miles int, feb11_gas int, jan11_miles int, jan11_gas int, dec10_miles int, dec10_gas int, nov10_miles int, nov10_gas int, oct10_miles int, oct10_gas int, sep10_miles int, sep10_gas int, aug10_miles int, aug10_gas int, jul10_miles int, jul10_gas int, jun10_miles int, jun10_gas int, may10_miles int, may10_gas int, apr10_miles int, apr10_gas int, mar10_miles int, mar10_gas int, feb10_miles int, feb10_gas int, jan10_miles int, jan10_gas int, dec09_miles int, dec09_gas int, nov09_miles int, nov09_gas int, oct09_miles int, oct09_gas int, sep09_miles int, sep09_gas int, aug09_miles int, aug09_gas int, jul09_miles int, jul09_gas int, jun09_miles int, jun09_gas int, may09_miles int, may09_gas int, apr09_miles int, apr09_gas int, mar09_miles int, mar09_gas int, feb09_miles int, feb09_gas int, jan09_miles int, jan09_gas int)
  14. ROW FORMAT delimited fields terminated by ','
  15. LOCATION
  16. 'hdfs://sandbox-hdp.hortonworks.com:8020/apps/hive/warehouse/trucks'
  17. TBLPROPERTIES (
  18. 'COLUMN_STATS_ACCURATE={\"BASIC_STATS\":\"true\"},
  19. numFiles=1,
  20. numRows=100,
  21. rawDataSize=69500,
  22. totalSize=28674,
  23. transient_lastDdlTime=1517406950')
  24. INFO : Semantic Analysis Completed
  25. INFO : Returning Hive schema: Schema(fieldSchemas:null, properties:null)
  26. INFO : Completed compiling command(queryId=hive_20180517120247_3f674187-17d2-480a-85bd-b07672491010); Time taken: 0.07 seconds
  27. INFO : Executing command(queryId=hive_20180517120247_3f674187-17d2-480a-85bd-b07672491010): CREATE TABLE IF NOT EXISTS trucks( driverid string, truckid string, model string, jun13_miles int, jun13_gas int, may13_miles int, may13_gas int, apr13_miles int, apr13_gas int, mar13_miles int, mar13_gas int, feb13_miles int, feb13_gas int, jan13_miles int, jan13_gas int, dec12_miles int, dec12_gas int, nov12_miles int, nov12_gas int, oct12_miles int, oct12_gas int, sep12_miles int, sep12_gas int, aug12_miles int, aug12_gas int, jul12_miles int, jul12_gas int, jun12_miles int, jun12_gas int, may12_miles int, may12_gas int, apr12_miles int, apr12_gas int, mar12_miles int, mar12_gas int, feb12_miles int, feb12_gas int, jan12_miles int, jan12_gas int, dec11_miles int, dec11_gas int, nov11_miles int, nov11_gas int, oct11_miles int, oct11_gas int, sep11_miles int, sep11_gas int, aug11_miles int, aug11_gas int, jul11_miles int, jul11_gas int, jun11_miles int, jun11_gas int, may11_miles int, may11_gas int, apr11_miles int, apr11_gas int, mar11_miles int, mar11_gas int, feb11_miles int, feb11_gas int, jan11_miles int, jan11_gas int, dec10_miles int, dec10_gas int, nov10_miles int, nov10_gas int, oct10_miles int, oct10_gas int, sep10_miles int, sep10_gas int, aug10_miles int, aug10_gas int, jul10_miles int, jul10_gas int, jun10_miles int, jun10_gas int, may10_miles int, may10_gas int, apr10_miles int, apr10_gas int, mar10_miles int, mar10_gas int, feb10_miles int, feb10_gas int, jan10_miles int, jan10_gas int, dec09_miles int, dec09_gas int, nov09_miles int, nov09_gas int, oct09_miles int, oct09_gas int, sep09_miles int, sep09_gas int, aug09_miles int, aug09_gas int, jul09_miles int, jul09_gas int, jun09_miles int, jun09_gas int, may09_miles int, may09_gas int, apr09_miles int, apr09_gas int, mar09_miles int, mar09_gas int, feb09_miles int, feb09_gas int, jan09_miles int, jan09_gas int)
  28. ROW FORMAT delimited fields terminated by ','
  29. LOCATION
  30. 'hdfs://sandbox-hdp.hortonworks.com:8020/apps/hive/warehouse/trucks'
  31. TBLPROPERTIES (
  32. 'COLUMN_STATS_ACCURATE={\"BASIC_STATS\":\"true\"},
  33. numFiles=1,
  34. numRows=100,
  35. rawDataSize=69500,
  36. totalSize=28674,
  37. transient_lastDdlTime=1517406950')
  38. INFO : Starting task [Stage-0:DDL] in serial mode
  39. INFO : Completed executing command(queryId=hive_20180517120247_3f674187-17d2-480a-85bd-b07672491010); Time taken: 2.279 seconds
  40. INFO : OK
  41. No rows affected (2.747 seconds)
  42. 0: jdbc:hive2://localhost:10000> LOAD DATA INPATH '/user/maria_dev/data/trucks.csv' OVERWRITE INTO TABLE trucks;
  43. Error: Error while compiling statement: FAILED: SemanticException Unable to load data to destination table. Error: The file that you are trying to load does not match the file format of the destination table. (state=42000,code=40000)
Add Comment
Please, Sign In to add comment