# Learn module : how to select data
#' @title Learn module : how to select data
#' @description Learn to select data
#'
#' @param id shiny id
#' @param input internal
#' @param output internal
#' @param session internal
#'
#' @rdname mod_learn_select
#'
#' @keywords internal
#' @importFrom shiny NS tagList fluidRow
#' @importFrom shinyAce aceEditor
mod_learn_select_ui <- function(id){
ns <- NS(id)
fluidRow(
column(
width = 12,
tags$div(
h1("Select data")
),
tags$div(
h2("Select all columns from a table"),
# learning_block(file = "select/select_all.Rmd"),
column(
width = 6,
tags$div(
h4("With SQL..."),
sql_onlyread_editor("hgh", HTML("SELECT * \nFROM toto"))
)
),
column(
width = 6,
tags$div(
h4("With dplyr..."),
r_onlyread_editor("jhjhs", "plauers %>% select(everything())")
)
)
)
)
)
}
# Module Server
#' @rdname mod_learn_select
#' @keywords internal
mod_learn_select_server <- function(input, output, session){
ns <- session$ns
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.