Skip to content

Commit

Permalink
feat: [+] #105 raiseError with interpolator & location link
Browse files Browse the repository at this point in the history
  • Loading branch information
eruizalo committed Oct 3, 2022
1 parent 5c9100a commit 08af017
Showing 1 changed file with 2 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -32,12 +32,7 @@ private[syntax] trait StringColumns31 {
* @see [[org.apache.spark.sql.functions.raise_error]]
*/
def raiseError(implicit l: Location): NullColumn =
concat(
s,
"\n at ".lit,
l.fileName.value.lit,
":".lit,
l.lineNumber.value.toString.lit
).elem.map(f.raise_error).toDC
ds"""$s
located at . ${l.getLocation.lit}""".elem.map(f.raise_error).toDC
}
}

0 comments on commit 08af017

Please sign in to comment.