Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages

  
 
  

home | help
SQLRSH(1)			 User Commands			     SQLRSH(1)

NAME
       sqlrsh -	manual page for	sqlrsh 1.7.0

SYNOPSIS
       sqlrsh [OPTIONS]

DESCRIPTION
       sqlrsh is the SQL Relay command line database shell.

       It  can	be used	interactively, or non-interactively to run queries di-
       rectly from the command line, or	scripts	containing queries.

OPTIONS
   Connection options:
       -host host
	      Host name	or IP address of the server to connect to.

       -port port
	      Port to connect to.

       -socket socket
	      Local unix socket	file name to connect to.  Can be used  instead
	      of host/port for making connections to local servers.

       -user user
	      User name	to auth	with.

       -password password
	      Password to auth with.

   Alternate connection	options:
       -config config
	      Override the default configuration with the specified configura-
	      tion.

       -id instanceid
	      Derive connection	info and credentials from  the	specified  in-
	      stance, as defined in the	configuration.

       -krb   Use Kerberos authentication and encryption.

       -krbservice svc
	      Use the specified	kerberos service.

       -krbmech	mech
	      Use the specified	kerberos mechanism.

       -krbflags flags
	      Use the specified	kerberos flags,	comma-separated.

       -tls   Use TLS/SSL authentication and encrpyiton.

       -tlsversion version
	      Use the specified	TLS/SSL	version.

       -tlscert	file
	      Use the specified	certificate chain file.	 This file should con-
	      tain the client's	certificate, private key, and signing certifi-
	      cates,  as appropriate.  On Windows systems, this	must be	a .pfx
	      file.  On	non-Windows systems, a variety	of  file  formats  are
	      supported.

       -tlspassword pwd
	      Use  the specified password to acess the private key in the file
	      specified	by -tlscert.

       -tlsciphers "list"
	      Allow the	specified list of ciphers.  The	list should be	quoted
	      and the ciphers should be	separated by spaces.

       -tlsvalidate (no|ca|ca+host|ca+domain)
	      Certificate  validation  option.	 "no"  -  Don't	 validate  the
	      server's certificate.  "ca" - Validate that  the	server's  cer-
	      tificate	 was   signed  by  a  trusted  certificate  authority.
	      "ca+host"	- Perform "ca" validation and also validate  that  one
	      of  the  subject	alternate names	(or common name	if no SANs are
	      present) in the certificate matches the host parameter.	(Falls
	      back  to	"ca"  validation when a	unix socket is used.)  "ca+do-
	      main" - Perform "ca" validation and also validate	that  the  do-
	      main name	of one of the subject alternate	naames (or common name
	      if no SANs are present) in the certificate  matches  the	domain
	      name of the host parameter.  (Falls back to "ca" validation when
	      a	unix socket is used.)

       -tlsca file
	      Use the specified	certificate authority file when	validating the
	      server's	certificate.   Or,  if "file" is a directory, then use
	      all certificate authority	files found  in	 that  directory  when
	      validating the server's certifictate.

       -tlsdepth depth
	      Set the maximum certificate chain	validation depth to the	speci-
	      fied depth.

   Command options:
       -script filename
	      Run the specified	script which contains commands or queries that
	      could otherwise be run at	the sqlrsh prompt.

       -command	"commands"
	      Run  the provided	string which contains commands or queries that
	      could otherwise be run at	the sqlrsh prompt.

       -quiet Omit headers and stats in	output.

       -format plain|csv
	      Format the output	as specified.  Defaults	to plain.

       -locale env|locale_name calls setlocale(LC_ALL, locale_name).
	      env means	use LC variables.

       -getasnumber
	      calls getFieldAs(Integer|Double) as appropriate

       -noelapsed
	      do not print elapsed time

       -nextresultset
	      attempt to fetch multiple	resultsets

       -resultsetbuffersize rows
	      Fetch result sets	using the specified number of rows at once.

EXAMPLES
       Interactive session with	server at svr:9000 as usr/pwd.

	      sqlrsh -host svr -port 9000 -user	usr -password pwd

       Interactive session  with  local	 server	 on  socket  /tmp/svr.sock  as
       usr/pwd.

	      sqlrsh -socket /tmp/svr.sock -user usr -password pwd

       Interactive  session  using connection info and credentials from	an in-
       stance defined in the default configuration.

	      sqlrsh -id myinst

       Interactive session using connection info and credentials from  an  in-
       stance defined in the config file ./myconfig.conf

	      sqlrsh -config ./myconfig.conf -id myinst

       Non-interactive session,	running	commands from ./script.sql

	      sqlrsh -id myinst	-script	./script.sql

       Non-interactive session,	running	query "select *	from mytable" with csv
       output.

	      sqlrsh -id myinst	-command "select * from	mytable" -quiet	 -for-
	      mat csv

       Rudiments version: 1.2.1	Compiled: Oct 23 2019 21:56:42

AUTHOR
       Written by David	Muse.

COPYRIGHT
       Copyright (C) 1999-2018 David Muse
       This is free software; see the source for copying conditions.  There is
       NO warranty; not	even for MERCHANTABILITY or FITNESS FOR	 A  PARTICULAR
       PURPOSE.

SQL Relay			 October 2019			     SQLRSH(1)

NAME | SYNOPSIS | DESCRIPTION | OPTIONS | EXAMPLES | AUTHOR | COPYRIGHT

Want to link to this manual page? Use this URL:
<https://www.freebsd.org/cgi/man.cgi?query=sqlrsh&sektion=1&manpath=FreeBSD+13.0-RELEASE+and+Ports>

home | help