Win32::SqlServer::DTS::Credential - credentials to authenticate against a MS SQL Server 2000
use Win32::SqlServer::DTS::Credential; # regular authentication method my $credential = Win32::SqlServer::DTS::Credential->new( { server => 'somedatabase', user => 'user', password => 'password', use_trusted_connection => 0 } ); #trusted authentication mode my $credential2 = Win32::SqlServer::DTS::Credential->new( { server => 'somedatabase', use_trusted_connection => 1 } );
Win32::SqlServer::DTS::Credential implements the authentication scheme expected by MS SQL Server connection depending on the mode that will be used (regular authentication or trusted connection).
Win32::SqlServer::DTS::Credential
This class was created to be able to invoke the DTS Application LoadFromSQLServer (and others) method in a polymorphic way, since these methods expect a lot of parameters given in the correct order (some parameters are even unused, but one must inform them anyway).
LoadFromSQLServer
One should not need to use this class directly: it is used by the Win32::SqlServer::DTS::Application module and, if you're using this class there is nothing to worry about authentication.
Nothing.
Win32::SqlServer::DTS::Credential does not inherients from any superclass. This means that the methods available in DTS are not available.
This method creates a new Win32::SqlServer::DTS::Credential object. A hash reference must be passed as a parameter (see SYNOPSIS for examples).
Depending on the authentication method, user and password are necessary or not. The Trusted Connection does not need such values, but the new method will abort with an error if you pass no keys with the necessary values.
user
password
new
A Win32::SqlServer::DTS::Credential object will have the following attributes:
server
auth_code
auth_code is defined by the DTS Application object documentation to be defined as explained below:
Constant DTSSQLStgFlag_Default = 0
Constant DTSSQLStgFlag_UseTrustedConnection = 256
Returns all attributes of the object in a ordered list. This will be used during method invoking to authenticate the request against the MS SQL Server. The list is returned in this order:
Win32::OLE at perldoc.
perldoc
MSDN on Microsoft website and MS SQL Server 2000 Books Online are a reference about using DTS' object hierarchy. You will need to convert examples written in VBScript to Perl code.
Alceu Rodrigues de Freitas Junior, <arfreitas@cpan.org>
Copyright (C) 2006 by Alceu Rodrigues de Freitas Junior
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.8 or, at your option, any later version of Perl 5 you may have available.
To install Win32::SqlServer::DTS, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Win32::SqlServer::DTS
CPAN shell
perl -MCPAN -e shell install Win32::SqlServer::DTS
For more information on module installation, please visit the detailed CPAN module installation guide.