.SH OPTIONS
.IP "\-d \fIsql_driver\fP"
-Driver to use: mysql, pg.
+Driver to use: mysql, pg, oracle.
.IP "\-b \fIdatabase\fP"
Name of the database to use.
.IP "\-h \fIhost\fP"
.IP "file_path"
The pathname of the SQL logfile to use.
+.SH NOTES
+.SS Oracle driver
+The command "radsqlrelay -d oracle -b db.domain.tld sql-relay" reads the
+database description stored in $TNS_ADMIN/tnsnames.ora:
+.PP
+.DS
+db.domain.tld =
+ (DESCRIPTION =
+ (ADDRESS_LIST =
+ (ADDRESS = (PROTOCOL = TCP)(HOST = db.domain.tld)(PORT = 1521))
+ )
+ (CONNECT_DATA =
+ (SERVICE_NAME = <DB SID>)
+ )
+ )
+.DE
+
.SH SEE ALSO
.BR rlm_sql_log (5)
##
## You should have received a copy of the GNU General Public License
## along with this program; if not, write to the Free Software
-## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
+## Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
##
use DBI;
-? Print this help message.
-1 One-shot mode: push the file to database and exit.
-b database Name of the database to use.
- -d sql_driver Driver to use: mysql, pg.
+ -d sql_driver Driver to use: mysql, pg, oracle.
-h host Connect to host.
-P port Port number to use for connection.
-p passord Password to use when connecting to server.
$data_source = "DBI:mysql:database=$args{b};host=$args{h}";
} elsif (lc($args{d}) eq 'pg') {
$data_source = "DBI:Pg:dbname=$args{b};host=$args{h}";
+} elsif (lc($args{d}) eq 'oracle') {
+ $data_source = "DBI:Oracle:$args{b}";
} else {
print STDERR "error: SQL driver not supported yet: $args{d}\n";
exit 1;