From 4b2d9113db9e1bb2edc1e5af9179ad49fe7d6afc Mon Sep 17 00:00:00 2001 From: David Steinbrunner Date: Fri, 13 Sep 2013 07:18:33 -0400 Subject: [PATCH 01/28] typo fix --- lib/Test/SQL/Translator.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/Test/SQL/Translator.pm b/lib/Test/SQL/Translator.pm index a2b0bcf6b..6caef9841 100644 --- a/lib/Test/SQL/Translator.pm +++ b/lib/Test/SQL/Translator.pm @@ -600,7 +600,7 @@ does field_ok run? Can then use these to set up the test plan easily. =item Test skipping -As the test subs wrap up lots of tests in one call you can't skip idividual +As the test subs wrap up lots of tests in one call you can't skip individual tests only whole sets e.g. a whole table or field. We could add skip_* items to the test hashes to allow per test skips. e.g. From 98f9d3268d06a3a03b24cc5ebf282d2e828b2382 Mon Sep 17 00:00:00 2001 From: David Steinbrunner Date: Fri, 13 Sep 2013 07:21:00 -0400 Subject: [PATCH 02/28] typo fix --- script/sqlt-diagram | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/script/sqlt-diagram b/script/sqlt-diagram index 61c3ff35d..da1a6dbe0 100755 --- a/script/sqlt-diagram +++ b/script/sqlt-diagram @@ -63,7 +63,7 @@ This can prove too permissive, however, as you probably don't want a field called "name" to be considered a foreign key, so you could include it in the "skip" option, and all fields called "name" will be excluded from natural joins. A more efficient method, however, might -be to simply deduce the foriegn keys from primary keys to other fields +be to simply deduce the foreign keys from primary keys to other fields named the same in other tables. Use the "natural-join-pk" option to achieve this. From 266c228a5394187b69c252a5262eec9462add3f7 Mon Sep 17 00:00:00 2001 From: David Steinbrunner Date: Fri, 13 Sep 2013 07:21:55 -0400 Subject: [PATCH 03/28] typo fix --- script/sqlt-graph | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/script/sqlt-graph b/script/sqlt-graph index d4a50036c..324ccb30f 100755 --- a/script/sqlt-graph +++ b/script/sqlt-graph @@ -81,9 +81,9 @@ This can prove too permissive, however, as you probably don't want a field called "name" to be considered a foreign key, so you could include it in the "skip" option, and all fields called "name" will be excluded from natural joins. A more efficient method, however, might -be to simply deduce the foriegn keys from primary keys to other fields +be to simply deduce the foreign keys from primary keys to other fields named the same in other tables. Use the "natural-join-pk" option -to acheive this. +to achieve this. If the schema defines foreign keys, then the graph produced will be directed showing the direction of the relationship. If the foreign From 935e80244d78ab455cf26b3cb5e5816be79d326f Mon Sep 17 00:00:00 2001 From: David Steinbrunner Date: Fri, 13 Sep 2013 07:23:05 -0400 Subject: [PATCH 04/28] typo fix --- lib/SQL/Translator.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/SQL/Translator.pm b/lib/SQL/Translator.pm index 916f80b23..3847b5a43 100644 --- a/lib/SQL/Translator.pm +++ b/lib/SQL/Translator.pm @@ -959,7 +959,7 @@ analogously to C and C =head2 filters -Set or retreive the filters to run over the schema during the +Set or retrieve the filters to run over the schema during the translation, before the producer creates its output. Filters are sub routines called, in order, with the schema object to filter as the 1st arg and a hash of options (passed as a list) for the rest of the args. From 5a5166538e51ef69e29cdcb24c8135c4e8c6c96c Mon Sep 17 00:00:00 2001 From: David Steinbrunner Date: Fri, 13 Sep 2013 07:27:23 -0400 Subject: [PATCH 05/28] typo fixes --- lib/SQL/Translator/Diff.pm | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/SQL/Translator/Diff.pm b/lib/SQL/Translator/Diff.pm index c291ce47d..d8d6503f0 100644 --- a/lib/SQL/Translator/Diff.pm +++ b/lib/SQL/Translator/Diff.pm @@ -381,7 +381,7 @@ sub diff_table_constraints { sub diff_table_fields { my ($self, $src_table, $tar_table) = @_; - # List of ones ew've renamed from so we dont drop them + # List of ones we've renamed from so we don't drop them my %renamed_source_fields; for my $tar_table_field ( $tar_table->get_fields ) { @@ -442,7 +442,7 @@ sub diff_table_options { my ($a_name, undef, $b_name, undef) = ( %$a, %$b ); $a_name cmp $b_name; }; - # Need to sort the options so we dont get supruious diffs. + # Need to sort the options so we don't get spurious diffs. my (@src_opts, @tar_opts); @src_opts = sort $cmp $src_table->options; @tar_opts = sort $cmp $tar_table->options; @@ -471,7 +471,7 @@ SQL::Translator::Diff - determine differences between two schemas =head1 DESCRIPTION Takes two input SQL::Translator::Schemas (or SQL files) and produces ALTER -statments to make them the same +statements to make them the same =head1 SNYOPSIS @@ -572,7 +572,7 @@ I.e. the hash might look something like the following: C is called by the Diff code to allow the producer to normalize any data it needs to first. For example, the MySQL producer uses -this method to ensure that FK contraint names are unique. +this method to ensure that FK constraint names are unique. Basicaly any changes that need to be made to produce the SQL file for the schema should be done here, so that a diff between a parsed SQL file and (say) From 07473b9d9f3145484c2f2130a6c9cf7af0e8b991 Mon Sep 17 00:00:00 2001 From: David Steinbrunner Date: Fri, 13 Sep 2013 07:28:26 -0400 Subject: [PATCH 06/28] typo fix --- lib/SQL/Translator/Filter/Globals.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/SQL/Translator/Filter/Globals.pm b/lib/SQL/Translator/Filter/Globals.pm index d4dbfda63..497e40f57 100644 --- a/lib/SQL/Translator/Filter/Globals.pm +++ b/lib/SQL/Translator/Filter/Globals.pm @@ -104,7 +104,7 @@ sub filter { $schema->drop_table($gtbl); } - # Add globalis to tables + # Add globals to tables foreach my $tbl ( $schema->get_tables ) { foreach my $new_fld ( @global_fields ) { From 08abffc0efbebc2be5efe94481e3c880075ef4b1 Mon Sep 17 00:00:00 2001 From: David Steinbrunner Date: Fri, 13 Sep 2013 07:30:38 -0400 Subject: [PATCH 07/28] typo fixes --- lib/SQL/Translator/Manual.pod | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/SQL/Translator/Manual.pod b/lib/SQL/Translator/Manual.pod index d9e03813a..4be28b903 100644 --- a/lib/SQL/Translator/Manual.pod +++ b/lib/SQL/Translator/Manual.pod @@ -129,7 +129,7 @@ comma-separated file to an SQLite database, do the following: $ sqlt -f xSV --fs ',' -t SQLite foo.csv > foo-sqlite.sql -Additionally, there is a non-SQL represenation of relational schemas namely +Additionally, there is a non-SQL representation of relational schemas namely XML. Additionally, the only XML supported is our own version; however, it would be fairly easy to add an XML parser for something like the TorqueDB (http://db.apache.org/torque/) project. The actual parsing of XML should be @@ -148,7 +148,7 @@ operation performed by SQLFairy, so it may behoove you to serialize a parsed schema if you need to perform repeated conversions. For example, as part of a build process the author converts a MySQL schema first to YAML, then to PostgreSQL, Oracle, SQLite and Sybase. -Additionally, a variety of documention in HTML and images is produced. +Additionally, a variety of documentation in HTML and images is produced. This can be accomplished like so: $ sqlt -f MySQL -t YAML schema-mysql.sql > schema.yaml From 63678b28fd6b9931576eea33e0c114b32e9be11c Mon Sep 17 00:00:00 2001 From: David Steinbrunner Date: Fri, 13 Sep 2013 07:35:34 -0400 Subject: [PATCH 08/28] typo fix --- lib/SQL/Translator/Producer/ClassDBI.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/SQL/Translator/Producer/ClassDBI.pm b/lib/SQL/Translator/Producer/ClassDBI.pm index f7994c991..4d26ee47b 100644 --- a/lib/SQL/Translator/Producer/ClassDBI.pm +++ b/lib/SQL/Translator/Producer/ClassDBI.pm @@ -106,7 +106,7 @@ sub produce { }; # - # Primary key may have a differenct accessor method name + # Primary key may have a different accessor method name # # if ( my $constraint = $table->primary_key ) { # my $field = ( $constraint->fields )[0]; From a0ee29e3c7490e317bdb7ca80c01cd27ff61291e Mon Sep 17 00:00:00 2001 From: David Steinbrunner Date: Fri, 13 Sep 2013 07:36:39 -0400 Subject: [PATCH 09/28] typo fixes --- lib/SQL/Translator/Producer/DiaUml.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/SQL/Translator/Producer/DiaUml.pm b/lib/SQL/Translator/Producer/DiaUml.pm index 9c7fa9650..187bd611c 100644 --- a/lib/SQL/Translator/Producer/DiaUml.pm +++ b/lib/SQL/Translator/Producer/DiaUml.pm @@ -22,7 +22,7 @@ SQL::Translator::Producer::DiaUml - Currently you will get one class (with the a table stereotype) generated per table in the schema. The fields are added as attributes of the classes and their datatypes set. It doesn't currently set any -of the relationships. It doesn't do any layout, all the classses are in one big +of the relationships. It doesn't do any layout, all the classes are in one big stack. However it is still useful as you can use the layout tools in Dia to automatically arrange them horizontally or vertically. @@ -64,7 +64,7 @@ Mark Addison Egrommit@users.sourceforge.netE. =head1 TODO -* Add the foriegn keys from the schema as UML relations. +* Add the foreign keys from the schema as UML relations. * Layout the classes. From b8d523a05e98bffae15da0722d5b8789a5d318eb Mon Sep 17 00:00:00 2001 From: David Steinbrunner Date: Fri, 13 Sep 2013 07:37:17 -0400 Subject: [PATCH 10/28] typo fix --- lib/SQL/Translator/Producer/GraphViz.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/SQL/Translator/Producer/GraphViz.pm b/lib/SQL/Translator/Producer/GraphViz.pm index c6c9c4de8..59529f0f5 100644 --- a/lib/SQL/Translator/Producer/GraphViz.pm +++ b/lib/SQL/Translator/Producer/GraphViz.pm @@ -113,7 +113,7 @@ constraints) =item * show_fields (DEFAULT: true) -If set to a true value, the names of the colums in a table will +If set to a true value, the names of the columns in a table will be displayed in each table's node =item * show_fk_only From 0fe51e8e82840d47bb9b4f78e5dc5b6b812bf44f Mon Sep 17 00:00:00 2001 From: David Steinbrunner Date: Fri, 13 Sep 2013 07:37:48 -0400 Subject: [PATCH 11/28] typo fix --- lib/SQL/Translator/Producer/Latex.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/SQL/Translator/Producer/Latex.pm b/lib/SQL/Translator/Producer/Latex.pm index f196ecd01..87369c253 100644 --- a/lib/SQL/Translator/Producer/Latex.pm +++ b/lib/SQL/Translator/Producer/Latex.pm @@ -22,7 +22,7 @@ SQL::Translator::Producer::Latex - Currently you will get one class (with the a table stereotype) generated per table in the schema. The fields are added as attributes of the classes and their datatypes set. It doesn't currently set any -of the relationships. It doesn't do any layout, all the classses are in one big +of the relationships. It doesn't do any layout, all the classes are in one big stack. However it is still useful as you can use the layout tools in Dia to automatically arrange them horizontally or vertically. From 10d7ce8ba7b4a692ef01bdd762b0a787a618b9fa Mon Sep 17 00:00:00 2001 From: David Steinbrunner Date: Fri, 13 Sep 2013 07:38:48 -0400 Subject: [PATCH 12/28] typo fix --- lib/SQL/Translator/Producer/PostgreSQL.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/SQL/Translator/Producer/PostgreSQL.pm b/lib/SQL/Translator/Producer/PostgreSQL.pm index bcfcb6f0d..5f898acec 100644 --- a/lib/SQL/Translator/Producer/PostgreSQL.pm +++ b/lib/SQL/Translator/Producer/PostgreSQL.pm @@ -831,7 +831,7 @@ sub alter_field $to_field->name) if ( !defined $new_default && defined $old_default ); - # add geometry column and contraints + # add geometry column and constraints push @out, add_geometry_column($to_field) if is_geometry($to_field); push @out, add_geometry_constraints($to_field) if is_geometry($to_field); From 5db972d2f2c69f7af9bd1775725bbdf15049aa72 Mon Sep 17 00:00:00 2001 From: David Steinbrunner Date: Fri, 13 Sep 2013 07:39:31 -0400 Subject: [PATCH 13/28] typo fix --- lib/SQL/Translator/Producer/SQLite.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/SQL/Translator/Producer/SQLite.pm b/lib/SQL/Translator/Producer/SQLite.pm index 2cccce22a..103c2deb6 100644 --- a/lib/SQL/Translator/Producer/SQLite.pm +++ b/lib/SQL/Translator/Producer/SQLite.pm @@ -464,7 +464,7 @@ sub batch_alter_table { my %temp_table_fields; do { local $table->{name} = $table_name . '_temp_alter'; - # We only want the table - dont care about indexes on tmp table + # We only want the table - don't care about indexes on tmp table my ($table_sql) = create_table($table, {no_comments => 1, temporary_table => 1}); push @sql,$table_sql; From 8c5efe6b6319dcd90d152f612cf9e10b3ae810f9 Mon Sep 17 00:00:00 2001 From: David Steinbrunner Date: Fri, 13 Sep 2013 07:40:09 -0400 Subject: [PATCH 14/28] typo fix --- lib/SQL/Translator/Producer/XML.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/SQL/Translator/Producer/XML.pm b/lib/SQL/Translator/Producer/XML.pm index ff7151b5d..584690f4d 100644 --- a/lib/SQL/Translator/Producer/XML.pm +++ b/lib/SQL/Translator/Producer/XML.pm @@ -10,7 +10,7 @@ SQL::Translator::Producer::XML - Alias to XML::SQLFairy producer Previous versions of SQL::Translator included an XML producer, but the namespace has since been further subdivided. Therefore, this module is -now just just an alias to the XML::SQLFairy producer. +now just an alias to the XML::SQLFairy producer. =head1 SEE ALSO From 9c2ad077ba383470f32a51f6b87c5adceb5c9065 Mon Sep 17 00:00:00 2001 From: David Steinbrunner Date: Fri, 13 Sep 2013 07:40:53 -0400 Subject: [PATCH 15/28] typo fix --- lib/SQL/Translator/Schema/Constraint.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/SQL/Translator/Schema/Constraint.pm b/lib/SQL/Translator/Schema/Constraint.pm index d726aa50e..79c1e73b8 100644 --- a/lib/SQL/Translator/Schema/Constraint.pm +++ b/lib/SQL/Translator/Schema/Constraint.pm @@ -80,7 +80,7 @@ around BUILDARGS => sub { Get or set whether the constraint is deferrable. If not defined, then returns "1." The argument is evaluated by Perl for True or -False, so the following are eqivalent: +False, so the following are equivalent: $deferrable = $field->deferrable(0); $deferrable = $field->deferrable(''); From e757697c6609eed553753e37307e7328824d68da Mon Sep 17 00:00:00 2001 From: David Steinbrunner Date: Fri, 13 Sep 2013 07:41:49 -0400 Subject: [PATCH 16/28] typo fix --- lib/SQL/Translator/Schema/Role/Extra.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/SQL/Translator/Schema/Role/Extra.pm b/lib/SQL/Translator/Schema/Role/Extra.pm index 1dfd7a106..ff46785dd 100644 --- a/lib/SQL/Translator/Schema/Role/Extra.pm +++ b/lib/SQL/Translator/Schema/Role/Extra.pm @@ -25,7 +25,7 @@ use Sub::Quote qw(quote_sub); =head2 extra -Get or set the objects "extra" attibutes (e.g., "ZEROFILL" for MySQL fields). +Get or set the objects "extra" attributes (e.g., "ZEROFILL" for MySQL fields). Call with no args to get all the extra data. Call with a single name arg to get the value of the named extra attribute, returned as a scalar. Call with a hash or hashref to set extra attributes. From 7e95adcb9ce2c7f58fc27fbcf58dc430b37d28c6 Mon Sep 17 00:00:00 2001 From: David Steinbrunner Date: Fri, 13 Sep 2013 07:42:37 -0400 Subject: [PATCH 17/28] typo fix --- lib/SQL/Translator/Schema/Table.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/SQL/Translator/Schema/Table.pm b/lib/SQL/Translator/Schema/Table.pm index 5e69f86dd..789b9a160 100644 --- a/lib/SQL/Translator/Schema/Table.pm +++ b/lib/SQL/Translator/Schema/Table.pm @@ -741,7 +741,7 @@ add to the fields of an existing PK (and will unique the field names). Returns the C object representing the primary key. -These are eqivalent: +These are equivalent: $table->primary_key('id'); $table->primary_key(['name']); From 92638f3246feb6a2ce7f61b68086453755918b62 Mon Sep 17 00:00:00 2001 From: David Steinbrunner Date: Fri, 13 Sep 2013 07:43:23 -0400 Subject: [PATCH 18/28] typo fixes --- lib/SQL/Translator/Types.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/SQL/Translator/Types.pm b/lib/SQL/Translator/Types.pm index 208139ea8..f2cdb03fb 100644 --- a/lib/SQL/Translator/Types.pm +++ b/lib/SQL/Translator/Types.pm @@ -17,7 +17,7 @@ SQL::Translator::Types - Type checking functions =head1 DESCRIPTIONS -This module exports fuctions that return coderefs suitable for L +This module exports functions that return coderefs suitable for L C type checks. Errors are reported using L. From 2fbdce23bc6e50c097b695c72561760d8428f66d Mon Sep 17 00:00:00 2001 From: David Steinbrunner Date: Fri, 13 Sep 2013 07:45:28 -0400 Subject: [PATCH 19/28] typo fix --- lib/SQL/Translator/Schema.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/SQL/Translator/Schema.pm b/lib/SQL/Translator/Schema.pm index 100690457..efa5bda02 100644 --- a/lib/SQL/Translator/Schema.pm +++ b/lib/SQL/Translator/Schema.pm @@ -655,14 +655,14 @@ sub make_natural_joins { =head2 make_natural_joins -Creates foriegn key relationships among like-named fields in different +Creates foreign key relationships among like-named fields in different tables. Accepts the following arguments: =over 4 =item * join_pk_only -A True or False argument which determins whether or not to perform +A True or False argument which determines whether or not to perform the joins from primary keys to fields of the same name in other tables =item * skip_fields From 3a69e56167e2989432afe14287ca08d600daded2 Mon Sep 17 00:00:00 2001 From: David Steinbrunner Date: Fri, 13 Sep 2013 07:47:46 -0400 Subject: [PATCH 20/28] typo fixes --- lib/SQL/Translator/Schema/Field.pm | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/SQL/Translator/Schema/Field.pm b/lib/SQL/Translator/Schema/Field.pm index d8680cb72..c918b54ea 100644 --- a/lib/SQL/Translator/Schema/Field.pm +++ b/lib/SQL/Translator/Schema/Field.pm @@ -43,13 +43,13 @@ use overload use DBI qw(:sql_types); -# Mapping from string to sql contstant +# Mapping from string to sql constant our %type_mapping = ( integer => SQL_INTEGER, int => SQL_INTEGER, smallint => SQL_SMALLINT, - bigint => 9999, # DBI doesn't export a constatn for this. Le suck + bigint => 9999, # DBI doesn't export a constant for this. Le suck double => SQL_DOUBLE, @@ -154,7 +154,7 @@ has default_value => ( is => 'rw' ); =head2 extra -Get or set the field's "extra" attibutes (e.g., "ZEROFILL" for MySQL). +Get or set the field's "extra" attributes (e.g., "ZEROFILL" for MySQL). Accepts a hash(ref) of name/value pairs to store; returns a hash. $field->extra( qualifier => 'ZEROFILL' ); @@ -258,7 +258,7 @@ sub _build_is_foreign_key { Get or set whether the field can be null. If not defined, then returns "1" (assumes the field can be null). The argument is evaluated -by Perl for True or False, so the following are eqivalent: +by Perl for True or False, so the following are equivalent: $is_nullable = $field->is_nullable(0); $is_nullable = $field->is_nullable(''); From caa85421c3ea902d96c64219645f45cdf08b582a Mon Sep 17 00:00:00 2001 From: David Steinbrunner Date: Fri, 13 Sep 2013 07:49:23 -0400 Subject: [PATCH 21/28] typo fix --- lib/SQL/Translator/Producer/TTSchema.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/SQL/Translator/Producer/TTSchema.pm b/lib/SQL/Translator/Producer/TTSchema.pm index 45bbd6d30..3b0114790 100644 --- a/lib/SQL/Translator/Producer/TTSchema.pm +++ b/lib/SQL/Translator/Producer/TTSchema.pm @@ -57,7 +57,7 @@ See F for a more complete example. The template will also get the set of extra variables given as a hashref via the C producer arg. -You can set any of the options used to initiallize the Template object by +You can set any of the options used to initialize the Template object by adding a tt_conf producer_arg. See Template Toolkit docs for details of the options. (Note that the old style of passing this config directly in the producer args From 85ad00ea98e48c62e2faea48e06f0a1586430b3f Mon Sep 17 00:00:00 2001 From: David Steinbrunner Date: Fri, 13 Sep 2013 07:52:49 -0400 Subject: [PATCH 22/28] typo fix --- lib/SQL/Translator/Parser/SQLite.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/SQL/Translator/Parser/SQLite.pm b/lib/SQL/Translator/Parser/SQLite.pm index 459f20384..ddc9ea438 100644 --- a/lib/SQL/Translator/Parser/SQLite.pm +++ b/lib/SQL/Translator/Parser/SQLite.pm @@ -737,7 +737,7 @@ sub parse { 1; # ------------------------------------------------------------------- -# All wholsome food is caught without a net or a trap. +# All wholesome food is caught without a net or a trap. # William Blake # ------------------------------------------------------------------- From a0e61cf67588b6d2f2c5bd002cc905bc4d9f1ef0 Mon Sep 17 00:00:00 2001 From: David Steinbrunner Date: Fri, 13 Sep 2013 07:54:37 -0400 Subject: [PATCH 23/28] typo fixes --- lib/SQL/Translator/Parser/XML/SQLFairy.pm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/SQL/Translator/Parser/XML/SQLFairy.pm b/lib/SQL/Translator/Parser/XML/SQLFairy.pm index 5cc37d144..7f54f3959 100644 --- a/lib/SQL/Translator/Parser/XML/SQLFairy.pm +++ b/lib/SQL/Translator/Parser/XML/SQLFairy.pm @@ -44,7 +44,7 @@ tags then the order the tags appear in the XML will be used. =head2 default_value Leave the attribute out all together to use the default in L. -Use empty quotes or 'EMPTY_STRING' for a zero lenth string. 'NULL' for an +Use empty quotes or 'EMPTY_STRING' for a zero length string. 'NULL' for an explicit null (currently sets default_value to undef in the Schema::Field obj). @@ -58,14 +58,14 @@ Doesn't take any extra parser args at the moment. =head1 LEGACY FORMAT -The previous version of the SQLFairy XML allowed the attributes of the the +The previous version of the SQLFairy XML allowed the attributes of the schema objects to be written as either xml attributes or as data elements, in any combination. While this allows for lots of flexibility in writing the XML the result is a great many possible XML formats, not so good for DTD writing, XPathing etc! So we have moved to a fixed version described in L. -This version of the parser will still parse the old formats and emmit warnings +This version of the parser will still parse the old formats and emit warnings when it sees them being used but they should be considered B. From c94428d87dee9c550c50b2c374a859cb5bd152f3 Mon Sep 17 00:00:00 2001 From: David Steinbrunner Date: Fri, 13 Sep 2013 07:59:47 -0400 Subject: [PATCH 24/28] typo fixes --- lib/SQL/Translator/Producer/MySQL.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/SQL/Translator/Producer/MySQL.pm b/lib/SQL/Translator/Producer/MySQL.pm index 1f8c541d6..268416edd 100644 --- a/lib/SQL/Translator/Producer/MySQL.pm +++ b/lib/SQL/Translator/Producer/MySQL.pm @@ -69,11 +69,11 @@ compatibility. =item B, B -Set the tables default charater set and collation order. +Set the tables default character set and collation order. =item B, B -Set the fields charater set and collation order. +Set the fields character set and collation order. =back From 09e3a2a67d4773007707553a11b64ca72b58078a Mon Sep 17 00:00:00 2001 From: David Steinbrunner Date: Fri, 13 Sep 2013 08:01:37 -0400 Subject: [PATCH 25/28] more typo fixes --- lib/SQL/Translator/Producer/MySQL.pm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/SQL/Translator/Producer/MySQL.pm b/lib/SQL/Translator/Producer/MySQL.pm index 268416edd..6c06caa1d 100644 --- a/lib/SQL/Translator/Producer/MySQL.pm +++ b/lib/SQL/Translator/Producer/MySQL.pm @@ -129,7 +129,7 @@ my %translate = ( ); # -# Column types that do not support lenth attribute +# Column types that do not support length attribute # my @no_length_attr = qw/ date time timestamp datetime year @@ -213,7 +213,7 @@ sub preprocess_schema { # Normalize constraint names here. my $c_name = $c->name; - # Give the constraint a name if it doesn't have one, so it doens't feel + # Give the constraint a name if it doesn't have one, so it doesn't feel # left out $c_name = $table->name . '_fk' unless length $c_name; @@ -876,7 +876,7 @@ sub batch_alter_table { my ($table, $diff_hash, $options) = @_; # InnoDB has an issue with dropping and re-adding a FK constraint under the - # name in a single alter statment, see: http://bugs.mysql.com/bug.php?id=13741 + # name in a single alter statement, see: http://bugs.mysql.com/bug.php?id=13741 # # We have to work round this. From a37acd3a937cb798d3b0811c995bec3c9fb0a334 Mon Sep 17 00:00:00 2001 From: David Steinbrunner Date: Fri, 13 Sep 2013 08:03:44 -0400 Subject: [PATCH 26/28] typo fixes --- lib/SQL/Translator/Producer/XML/SQLFairy.pm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/SQL/Translator/Producer/XML/SQLFairy.pm b/lib/SQL/Translator/Producer/XML/SQLFairy.pm index 132d9c371..446b60e0e 100644 --- a/lib/SQL/Translator/Producer/XML/SQLFairy.pm +++ b/lib/SQL/Translator/Producer/XML/SQLFairy.pm @@ -126,7 +126,7 @@ Default is 2, set to 0 to turn off indenting. =head1 LEGACY FORMAT -The previous version of the SQLFairy XML allowed the attributes of the the +The previous version of the SQLFairy XML allowed the attributes of the schema objects to be written as either xml attributes or as data elements, in any combination. The old producer could produce attribute only or data element only versions. While this allowed for lots of flexibility in writing the XML @@ -330,7 +330,7 @@ sub xml_obj_children { # # Takes an XML::Writer, Schema::* object and list of method names -# and writes the obect out as XML. All methods values are written as attributes +# and writes the object out as XML. All methods values are written as attributes # except for the methods listed in @MAP_AS_ELEMENTS which get written as child # data elements. # @@ -350,7 +350,7 @@ sub xml_obj { my @meths = @{ $args{'methods'} }; my $empty_tag = 0; - # Use array to ensure consistant (ie not hash) ordering of attribs + # Use array to ensure consistent (ie not hash) ordering of attribs # The order comes from the meths list passed in. my @tags; my @attr; From c5b10b48fbea7af163720d4bf45c1a86572a0835 Mon Sep 17 00:00:00 2001 From: David Steinbrunner Date: Fri, 13 Sep 2013 08:07:02 -0400 Subject: [PATCH 27/28] typo fixes --- lib/SQL/Translator/Producer/TT/Table.pm | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/lib/SQL/Translator/Producer/TT/Table.pm b/lib/SQL/Translator/Producer/TT/Table.pm index 9b952da97..1b9ec6800 100644 --- a/lib/SQL/Translator/Producer/TT/Table.pm +++ b/lib/SQL/Translator/Producer/TT/Table.pm @@ -65,7 +65,7 @@ Here's a brief example of what the template could look like: See F for a more complete example. -You can also set any of the options used to initiallize the Template +You can also set any of the options used to initialize the Template object by adding them to your producer_args. See Template Toolkit docs for details of the options. @@ -82,7 +82,7 @@ If you set C and its additional options the producer will write a separate file for each table in the schema. This is useful for producing things like HTML documentation where every table gets its own page (you could also use TTSchema producer to add an index page). -Its also particulary good for code generation where you want to +Its also particularly good for code generation where you want to produce a class file per table. =head1 OPTIONS @@ -123,12 +123,12 @@ where we want to write our output. One of "skip", "die", "replace", B - Over-write the existing file with the new one, clobbering anything already there. -B - Leave the origional file as it was and don't write the new +B - Leave the original file as it was and don't write the new version anywhere. B - Die with an existing file error. -B - Insert the generated output into the file bewteen a set of +B - Insert the generated output into the file between a set of special comments (defined by the following options.) Any code between the comments will be overwritten (ie the results from a previous produce) but the rest of the file is left alone (your custom code). @@ -246,7 +246,7 @@ sub write_file { } } - my ($dir) = $file =~ m!^(.*)/!; # Want greedy, eveything before the last / + my ($dir) = $file =~ m!^(.*)/!; # Want greedy, everything before the last / if ( $dir and not -d $dir and $pargs->{mk_file_dir} ) { mkpath($dir); } debug "Writing to $file\n"; @@ -263,7 +263,7 @@ sub insert_code { my $cstart = $pargs->{insert_comment_start} || "SQLF_INSERT_START"; my $cend = $pargs->{insert_comment_end} || "SQLF_INSERT_END"; - # Slurp in the origional file + # Slurp in the original file open ( FILE, "<", "$file") or die "Error opening file $file : $!\n"; local $/ = undef; my $orig = ; @@ -290,7 +290,7 @@ Mark Addison Egrommit@users.sourceforge.netE. =head1 TODO - Some tests for the various on exists options (they have been tested -implicitley through use in a project but need some proper tests). +implicitly through use in a project but need some proper tests). - More docs on code generation strategies. From 7ce70c582c2cfdca0dcdd89cf4907d53a1c7a700 Mon Sep 17 00:00:00 2001 From: David Steinbrunner Date: Fri, 13 Sep 2013 08:09:25 -0400 Subject: [PATCH 28/28] typo fixes --- lib/SQL/Translator/Producer/TT/Base.pm | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/SQL/Translator/Producer/TT/Base.pm b/lib/SQL/Translator/Producer/TT/Base.pm index 9c86f86e5..8155ff55f 100644 --- a/lib/SQL/Translator/Producer/TT/Base.pm +++ b/lib/SQL/Translator/Producer/TT/Base.pm @@ -205,7 +205,7 @@ The template to use, return a file name or a scalar ref of TT source, or an L. See L