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

FreeBSD Manual Pages

  
 
  

home | help
SQL::Translator::ProduUser:Contributed)SQL::Translator::Producer::SQLServer(3)

NAME
       SQL::Translator::Producer::SQLServer - MS SQLServer producer for
       SQL::Translator

SYNOPSIS
	 use SQL::Translator;

	 my $t = SQL::Translator->new( parser => '...',	producer => 'SQLServer'	);
	 $t->translate;

DESCRIPTION
       This is currently a thin	wrapper	around the nextgen
       SQL::Translator::Generator::DDL::SQLServer DDL maker.

Extra Attributes
       field.list
	   List	of values for an enum field.

TODO
	* !! Write some	tests !!
	* Reserved words list needs updating to	SQLServer.
	* Triggers, Procedures and Views DO NOT	WORK

	   # Text of view is already a 'create view' statement so no need to
	   # be	fancy
	   foreach ( $schema->get_views	) {
	       my $name	= $_->name();
	       $output .= "\n\n";
	       $output .= "--\n-- View:	$name\n--\n\n" unless $no_comments;
	       my $text	= $_->sql();
	       $text =~	s/\r//g;
	       $output .= "$text\nGO\n";
	   }

	   # Text of procedure already has the 'create procedure' stuff
	   # so	there is no need to do anything	fancy. However,	we should
	   # think about doing fancy stuff with	granting permissions and
	   # so	on.
	   foreach ( $schema->get_procedures ) {
	       my $name	= $_->name();
	       $output .= "\n\n";
	       $output .= "--\n-- Procedure: $name\n--\n\n" unless $no_comments;
	       my $text	= $_->sql();
	     $text =~ s/\r//g;
	       $output .= "$text\nGO\n";
	   }

SEE ALSO
       SQL::Translator

AUTHORS
       See the included	AUTHORS	file:
       <http://search.cpan.org/dist/SQL-Translator/AUTHORS>

COPYRIGHT
       Copyright (c) 2012 the SQL::Translator "AUTHORS"	as listed above.

LICENSE
       This code is free software and may be distributed under the same	terms
       as Perl itself.

perl v5.32.0			  2020-SQL::Translator::Producer::SQLServer(3)

NAME | SYNOPSIS | DESCRIPTION | Extra Attributes | TODO | SEE ALSO | AUTHORS | COPYRIGHT | LICENSE

Want to link to this manual page? Use this URL:
<https://www.freebsd.org/cgi/man.cgi?query=SQL::Translator::Producer::SQLServer&sektion=3&manpath=FreeBSD+12.2-RELEASE+and+Ports>

home | help