final class SCollectionTypedOps[T <: HasAnnotation] extends AnyVal
Enhanced version of SCollection with BigQuery methods.
- Alphabetic
- By Inheritance
- SCollectionTypedOps
- AnyVal
- Any
- Hide All
- Show All
- Public
- Protected
Instance Constructors
- new SCollectionTypedOps(self: SCollection[T])
Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- Any
- final def ##: Int
- Definition Classes
- Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- Any
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def getClass(): Class[_ <: AnyVal]
- Definition Classes
- AnyVal → Any
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- def saveAsTypedBigQueryTable(table: Table, timePartitioning: TimePartitioning = TableWriteParam.DefaultTimePartitioning, writeDisposition: WriteDisposition = TableWriteParam.DefaultWriteDisposition, createDisposition: CreateDisposition = TableWriteParam.DefaultCreateDisposition)(implicit tt: scala.reflect.api.JavaUniverse.TypeTag[T], ct: ClassTag[T], coder: Coder[T]): ClosedTap[T]
Save this SCollection as a BigQuery table.
Save this SCollection as a BigQuery table. Note that element type
Tmust be annotated with BigQueryType.This could be a complete case class with BigQueryType.toTable. For example:
@BigQueryType.toTable case class Result(name: String, score: Double) val p: SCollection[Result] = // process data and convert elements to Result p.saveAsTypedBigQueryTable(Table.Spec("myproject:mydataset.mytable"))
It could also be an empty class with schema from BigQueryType.fromSchema, BigQueryType.fromTable, or BigQueryType.fromQuery. For example:
@BigQueryType.fromTable("bigquery-public-data:samples.gsod") class Row sc.typedBigQuery[Row]() .sample(withReplacement = false, fraction = 0.1) .saveAsTypedBigQueryTable(Table.Spec("myproject:samples.gsod"))
- def toString(): String
- Definition Classes
- Any