# Define a new data source, named 'entropy'.
sqrlSource("entropy", uid = "ludwig",
driver = "{SQL Server Native Client 11.0}",
server = "Clausius", database = "Gibbs")
# The source comes with an interface of the same name.
sqrlInterface("entropy")
entropy("sources")
# Change the name of the interface function.
sqrlInterface(entropy = "S")
# An equivalent alternative form.
sqrlInterface("entropy", "S")
# The name of the source remains unchanged.
sqrlInterface("entropy")
S("sources")
# Submit a dummy 'query', via the interface.
# Normally, you'd put some SQL in here, but
# the source would have to exist for that.
S(" 'hello, world'")
# Remove the source's interface function.
sqrlInterface(entropy = NULL)
# An equivalent alternative form.
sqrlInterface("entropy", "remove")
# The source remains, but has no interface.
sqrlInterface("entropy")
sqrlSources()
Run the code above in your browser using DataLab