Github user olarayej commented on a diff in the pull request:
    --- Diff: R/pkg/R/functions.R ---
    @@ -2836,7 +2845,11 @@ setMethod("lpad", signature(x = "Column", len = 
"numeric", pad = "character"),
     setMethod("rand", signature(seed = "missing"),
               function(seed) {
                 jc <- callJStatic("org.apache.spark.sql.functions", "rand")
    -            column(jc)
    +            # By assigning a one-row data.frame, the result of this 
function can be collected
    +            # returning a one-element Column
    +            df <- as.DataFrame(sparkRSQL.init(), data.frame(0))
    --- End diff --
    @felixcheung That's a good idea. I have created a singleton accordingly.

If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at or file a JIRA ticket
with INFRA.

To unsubscribe, e-mail:
For additional commands, e-mail:

Reply via email to