[Bast-commits] r8379 - in
DBIx-Class/0.08/branches/multiple_version_upgrade: . lib/DBIx
lib/DBIx/Class lib/DBIx/Class/Manual
lib/DBIx/Class/Relationship lib/DBIx/Class/Schema
lib/DBIx/Class/Storage/DBI lib/DBIx/Class/Storage/DBI/Oracle
lib/DBIx/Class/Storage/DBI/Replicated
lib/SQL/Translator/Parser/DBIx t t/inflate t/lib t/prefetch
t/relationship t/resultset t/search
ribasushi at dev.catalyst.perl.org
ribasushi at dev.catalyst.perl.org
Tue Jan 19 12:47:48 GMT 2010
Author: ribasushi
Date: 2010-01-19 12:47:48 +0000 (Tue, 19 Jan 2010)
New Revision: 8379
Added:
DBIx-Class/0.08/branches/multiple_version_upgrade/t/resultset/nulls_only.t
Modified:
DBIx-Class/0.08/branches/multiple_version_upgrade/
DBIx-Class/0.08/branches/multiple_version_upgrade/Changes
DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class.pm
DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Manual/Troubleshooting.pod
DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Relationship/ManyToMany.pm
DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/ResultSet.pm
DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/ResultSourceProxy.pm
DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Row.pm
DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Schema/Versioned.pm
DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Storage/DBI/AmbiguousGlob.pm
DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Storage/DBI/Oracle/Generic.pm
DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Storage/DBI/Replicated.pm
DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Storage/DBI/Replicated/Pool.pm
DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Storage/DBI/mysql.pm
DBIx-Class/0.08/branches/multiple_version_upgrade/lib/SQL/Translator/Parser/DBIx/Class.pm
DBIx-Class/0.08/branches/multiple_version_upgrade/t/71mysql.t
DBIx-Class/0.08/branches/multiple_version_upgrade/t/86sqlt.t
DBIx-Class/0.08/branches/multiple_version_upgrade/t/94versioning.t
DBIx-Class/0.08/branches/multiple_version_upgrade/t/99dbic_sqlt_parser.t
DBIx-Class/0.08/branches/multiple_version_upgrade/t/inflate/hri.t
DBIx-Class/0.08/branches/multiple_version_upgrade/t/lib/DBICTest.pm
DBIx-Class/0.08/branches/multiple_version_upgrade/t/lib/sqlite.sql
DBIx-Class/0.08/branches/multiple_version_upgrade/t/prefetch/double_prefetch.t
DBIx-Class/0.08/branches/multiple_version_upgrade/t/relationship/core.t
DBIx-Class/0.08/branches/multiple_version_upgrade/t/search/related_strip_prefetch.t
Log:
r8307 at Thesaurus (orig r8295): abraxxa | 2010-01-13 17:28:05 +0100
added the sources parser arg to the example code
r8327 at Thesaurus (orig r8315): ribasushi | 2010-01-15 01:25:39 +0100
r8167 at Thesaurus (orig r8155): ribasushi | 2009-12-19 12:50:13 +0100
New branch for null-only-result fix
r8168 at Thesaurus (orig r8156): ribasushi | 2009-12-19 12:51:21 +0100
Failing test
r8322 at Thesaurus (orig r8310): ribasushi | 2010-01-15 00:48:09 +0100
Correct test order
r8323 at Thesaurus (orig r8311): ribasushi | 2010-01-15 01:15:33 +0100
Generalize the to-node inner-join-er to apply to all related_resultset calls, not just counts
r8324 at Thesaurus (orig r8312): ribasushi | 2010-01-15 01:16:05 +0100
Adjust sql-emitter tests
r8326 at Thesaurus (orig r8314): ribasushi | 2010-01-15 01:25:10 +0100
One more sql-test fix and changes
r8328 at Thesaurus (orig r8316): ribasushi | 2010-01-15 01:31:58 +0100
Strict mysql bugfix
r8329 at Thesaurus (orig r8317): ribasushi | 2010-01-15 01:38:53 +0100
Better description of mysql strict option
r8331 at Thesaurus (orig r8319): ribasushi | 2010-01-15 03:12:13 +0100
Update troubleshooting doc
r8337 at Thesaurus (orig r8325): ribasushi | 2010-01-15 17:13:28 +0100
RT52674
r8346 at Thesaurus (orig r8334): ribasushi | 2010-01-17 09:41:49 +0100
No method aliasing in OO code, *ever*
r8373 at Thesaurus (orig r8360): ribasushi | 2010-01-18 11:54:51 +0100
Adjust my email
r8387 at Thesaurus (orig r8374): ribasushi | 2010-01-19 13:07:07 +0100
r8340 at Thesaurus (orig r8328): abraxxa | 2010-01-15 19:21:20 +0100
added branch no_duplicate_indexes_for_pk_cols with test and fix
r8343 at Thesaurus (orig r8331): abraxxa | 2010-01-15 19:32:16 +0100
don't use eq_set in test
r8344 at Thesaurus (orig r8332): abraxxa | 2010-01-15 19:44:04 +0100
don't sort the primary columns because order matters for indexes
r8345 at Thesaurus (orig r8333): abraxxa | 2010-01-15 19:56:46 +0100
don't sort the key columns because the order of columns is important for indexes
r8372 at Thesaurus (orig r8359): abraxxa | 2010-01-18 10:22:09 +0100
don't sort the columns in the tests either
r8378 at Thesaurus (orig r8365): abraxxa | 2010-01-18 15:39:28 +0100
added pod section for parser args
r8379 at Thesaurus (orig r8366): abraxxa | 2010-01-18 15:53:08 +0100
better pod thanks to ribasushi
r8380 at Thesaurus (orig r8367): abraxxa | 2010-01-18 16:04:34 +0100
test and pod fixes
r8383 at Thesaurus (orig r8370): abraxxa | 2010-01-19 12:38:44 +0100
fixed Authors section
added License section
fixed t/86sqlt.t tests
r8384 at Thesaurus (orig r8371): ribasushi | 2010-01-19 12:59:52 +0100
Regenaretd under new parser
r8385 at Thesaurus (orig r8372): ribasushi | 2010-01-19 13:03:51 +0100
Minor style change and white space trim
r8386 at Thesaurus (orig r8373): ribasushi | 2010-01-19 13:06:54 +0100
Changes abraxxa++
r8390 at Thesaurus (orig r8377): ribasushi | 2010-01-19 13:41:03 +0100
Some minor test refactor and tab cleanups
Property changes on: DBIx-Class/0.08/branches/multiple_version_upgrade
___________________________________________________________________
Name: svk:merge
- 168d5346-440b-0410-b799-f706be625ff1:/DBIx-Class-current:2207
462d4d0c-b505-0410-bf8e-ce8f877b3390:/local/bast/DBIx-Class:3159
4d5fae46-8e6a-4e08-abee-817e9fb894a2:/local/bast/DBIx-Class/0.08/branches/cookbook_fixes:7657
4d5fae46-8e6a-4e08-abee-817e9fb894a2:/local/bast/DBIx-Class/0.08/branches/prefetch_bug-unqualified_column_in_search_related_cond:7959
4d5fae46-8e6a-4e08-abee-817e9fb894a2:/local/bast/DBIx-Class/0.08/branches/resultsetcolumn_custom_columns:5160
4d5fae46-8e6a-4e08-abee-817e9fb894a2:/local/bast/DBIx-Class/0.08/branches/sqla_1.50_compat:5414
4d5fae46-8e6a-4e08-abee-817e9fb894a2:/local/bast/DBIx-Class/0.08/branches/void_populate_resultset_cond:7935
4d5fae46-8e6a-4e08-abee-817e9fb894a2:/local/bast/DBIx-Class/0.08/trunk:7982
9c88509d-e914-0410-b01c-b9530614cbfe:/local/DBIx-Class:32260
9c88509d-e914-0410-b01c-b9530614cbfe:/local/DBIx-Class-CDBICompat:54993
9c88509d-e914-0410-b01c-b9530614cbfe:/vendor/DBIx-Class:31122
ab17426e-7cd3-4704-a2a2-80b7c0a611bb:/local/dbic_column_attr:10946
ab17426e-7cd3-4704-a2a2-80b7c0a611bb:/local/dbic_trunk:11788
bd5ac9a7-f185-4d95-9186-dbb8b392a572:/local/os/bast/DBIx-Class/0.08/trunk:2798
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/_abandoned_but_possibly_useful/table_name_ref:7266
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/ado_mssql:7886
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/autocast:7418
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/belongs_to_null_col_fix:5244
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/cdbicompat_integration:4160
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/column_attr:5074
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/complex_join_rels:4589
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/connect_info_hash:7435
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/connected_schema_leak:8264
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/cookbook_fixes:7479
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/count_distinct:6218
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/count_rs:6741
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/create_scalarref_rt51559:8027
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/diamond_relationships:6310
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/discard_changes_replication_fix:7252
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/file_column:3920
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/fix-update-and-delete-as_query:6162
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/get_inflated_columns_rt46953:7964
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/grouped_has_many_join:7382
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/grouped_prefetch:6885
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/is_resultset_paginated:7769
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/joined_count:6323
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mc_fixes:6645
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mssql_limit_regression:8278
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mssql_money_type:7096
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mssql_rno_pagination:8054
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mssql_storage_minor_refactor:7210
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mssql_top_fixes:6971
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/multi_stuff:5565
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/multicreate_fixes:7275
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mysql_ansi:7175
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mystery_join:6589
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/new_replication_transaction_fixup:7058
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/normalize_connect_info:8274
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/on_connect_call:6854
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/on_disconnect_do:3694
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/oracle-tweaks:6222
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/oracle_sequence:4173
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/oracle_shorten_aliases:8234
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/order_by_refactor:6475
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/parser_fk_index:4485
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/pg_unqualified_schema:7842
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/prefetch:5699
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/prefetch-group_by:7917
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/prefetch_bug-unqualified_column_in_search_related_cond:7900
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/prefetch_limit:6724
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/prefetch_redux:7206
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/reduce_pings:7261
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/replication_dedux:4600
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/rsrc_in_storage:6577
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/rt_bug_41083:5437
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/savepoints:4223
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/search_related_prefetch:6818
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sqla_1.50_compat:5321
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sqlt_parser_view:8145
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/storage-ms-access:4142
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/storage-tweaks:6262
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/subclassed_rsset:5930
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/subquery:5617
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/syb_connected:6919
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sybase:7682
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sybase_bulk_insert:7679
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sybase_bulkinsert_support:7796
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sybase_mssql:6125
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sybase_refactor:7940
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sybase_support:7797
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/table_name_ref:7132
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/top_limit_altfix:6429
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/type_aware_update:6619
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/unresolvable_prefetch:6949
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/versioned_enhancements:4125
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/versioning:4578
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/view_rels:7908
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/views:5585
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/void_populate_resultset_cond:7944
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/tags/0.08108_prerelease_please_do_not_pull_into_it:7008
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/tags/pre_0.08109_please_do_not_merge:7336
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class-C3:318
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class-current:2222
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class-joins:173
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class-resultset:570
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/datetime:1716
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/find_compat:1855
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/find_unique_query_fixes:2142
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/inflate:1988
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/many_to_many:2025
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/re_refactor_bugfix:1944
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/reorganize_tests:1827
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/resultset-new-refactor:1766
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/resultset_2_electric_boogaloo:2175
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/resultset_cleanup:2102
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/sqlt_tests_refactor:2043
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/trunk/DBIx-Class:3606
fe160bb6-dc1c-0410-9f2b-d64a711b54a5:/local/DBIC-trunk-0.08:10510
+ 168d5346-440b-0410-b799-f706be625ff1:/DBIx-Class-current:2207
462d4d0c-b505-0410-bf8e-ce8f877b3390:/local/bast/DBIx-Class:3159
4d5fae46-8e6a-4e08-abee-817e9fb894a2:/local/bast/DBIx-Class/0.08/branches/cookbook_fixes:7657
4d5fae46-8e6a-4e08-abee-817e9fb894a2:/local/bast/DBIx-Class/0.08/branches/prefetch_bug-unqualified_column_in_search_related_cond:7959
4d5fae46-8e6a-4e08-abee-817e9fb894a2:/local/bast/DBIx-Class/0.08/branches/resultsetcolumn_custom_columns:5160
4d5fae46-8e6a-4e08-abee-817e9fb894a2:/local/bast/DBIx-Class/0.08/branches/sqla_1.50_compat:5414
4d5fae46-8e6a-4e08-abee-817e9fb894a2:/local/bast/DBIx-Class/0.08/branches/void_populate_resultset_cond:7935
4d5fae46-8e6a-4e08-abee-817e9fb894a2:/local/bast/DBIx-Class/0.08/trunk:7982
9c88509d-e914-0410-b01c-b9530614cbfe:/local/DBIx-Class:32260
9c88509d-e914-0410-b01c-b9530614cbfe:/local/DBIx-Class-CDBICompat:54993
9c88509d-e914-0410-b01c-b9530614cbfe:/vendor/DBIx-Class:31122
ab17426e-7cd3-4704-a2a2-80b7c0a611bb:/local/dbic_column_attr:10946
ab17426e-7cd3-4704-a2a2-80b7c0a611bb:/local/dbic_trunk:11788
bd5ac9a7-f185-4d95-9186-dbb8b392a572:/local/os/bast/DBIx-Class/0.08/trunk:2798
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/_abandoned_but_possibly_useful/table_name_ref:7266
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/ado_mssql:7886
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/autocast:7418
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/belongs_to_null_col_fix:5244
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/cdbicompat_integration:4160
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/column_attr:5074
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/complex_join_rels:4589
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/connect_info_hash:7435
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/connected_schema_leak:8264
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/cookbook_fixes:7479
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/count_distinct:6218
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/count_rs:6741
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/create_scalarref_rt51559:8027
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/diamond_relationships:6310
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/discard_changes_replication_fix:7252
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/file_column:3920
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/fix-update-and-delete-as_query:6162
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/get_inflated_columns_rt46953:7964
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/grouped_has_many_join:7382
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/grouped_prefetch:6885
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/is_resultset_paginated:7769
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/joined_count:6323
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mc_fixes:6645
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mssql_limit_regression:8278
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mssql_money_type:7096
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mssql_rno_pagination:8054
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mssql_storage_minor_refactor:7210
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mssql_top_fixes:6971
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/multi_stuff:5565
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/multicreate_fixes:7275
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mysql_ansi:7175
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mystery_join:6589
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/new_replication_transaction_fixup:7058
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/no_duplicate_indexes_for_pk_cols:8373
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/normalize_connect_info:8274
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/null_column_regression:8314
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/on_connect_call:6854
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/on_disconnect_do:3694
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/oracle-tweaks:6222
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/oracle_sequence:4173
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/oracle_shorten_aliases:8234
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/order_by_refactor:6475
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/parser_fk_index:4485
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/pg_unqualified_schema:7842
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/prefetch:5699
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/prefetch-group_by:7917
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/prefetch_bug-unqualified_column_in_search_related_cond:7900
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/prefetch_limit:6724
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/prefetch_redux:7206
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/reduce_pings:7261
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/replication_dedux:4600
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/rsrc_in_storage:6577
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/rt_bug_41083:5437
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/savepoints:4223
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/search_related_prefetch:6818
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sqla_1.50_compat:5321
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sqlt_parser_view:8145
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/storage-ms-access:4142
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/storage-tweaks:6262
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/subclassed_rsset:5930
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/subquery:5617
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/syb_connected:6919
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sybase:7682
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sybase_bulk_insert:7679
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sybase_bulkinsert_support:7796
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sybase_mssql:6125
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sybase_refactor:7940
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sybase_support:7797
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/table_name_ref:7132
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/top_limit_altfix:6429
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/type_aware_update:6619
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/unresolvable_prefetch:6949
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/versioned_enhancements:4125
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/versioning:4578
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/view_rels:7908
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/views:5585
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/void_populate_resultset_cond:7944
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/tags/0.08108_prerelease_please_do_not_pull_into_it:7008
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/tags/pre_0.08109_please_do_not_merge:7336
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/trunk:8377
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class-C3:318
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class-current:2222
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class-joins:173
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class-resultset:570
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/datetime:1716
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/find_compat:1855
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/find_unique_query_fixes:2142
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/inflate:1988
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/many_to_many:2025
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/re_refactor_bugfix:1944
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/reorganize_tests:1827
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/resultset-new-refactor:1766
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/resultset_2_electric_boogaloo:2175
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/resultset_cleanup:2102
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/sqlt_tests_refactor:2043
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/trunk/DBIx-Class:3606
fe160bb6-dc1c-0410-9f2b-d64a711b54a5:/local/DBIC-trunk-0.08:10510
Modified: DBIx-Class/0.08/branches/multiple_version_upgrade/Changes
===================================================================
--- DBIx-Class/0.08/branches/multiple_version_upgrade/Changes 2010-01-19 12:41:19 UTC (rev 8378)
+++ DBIx-Class/0.08/branches/multiple_version_upgrade/Changes 2010-01-19 12:47:48 UTC (rev 8379)
@@ -9,10 +9,16 @@
- Cookbook POD fix for add_drop_table instead of add_drop_tables
- Views without a view_definition will throw an exception when
parsed by SQL::Translator::Parser::DBIx::Class
+ - Stop the SQLT parser from auto-adding indexes identical to the
+ Primary Key
- Schema POD improvement for dclone
- Fix regression in context sensitiveness of deployment_statements
- Fix regression resulting in overcomplicated query on
search_related from prefetching resultsets
+ - Fix regression on all-null returning searches (properly switch
+ LEFT JOIN to JOIN in order to distinguish between both cases)
+ - Fix regression in groupedresultset count() used on strict-mode
+ MySQL connections
- Better isolation of RNO-limited queries from the rest of a
prefetching resultset
- New MSSQL specific resultset attribute to allow hacky ordered
Modified: DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Manual/Troubleshooting.pod
===================================================================
--- DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Manual/Troubleshooting.pod 2010-01-19 12:41:19 UTC (rev 8378)
+++ DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Manual/Troubleshooting.pod 2010-01-19 12:47:48 UTC (rev 8379)
@@ -100,29 +100,21 @@
L<DBIx::Class::Manual::Cookbook/Setting_quoting_for_the_generated_SQL> for
details.
-Note that quoting may lead to problems with C<order_by> clauses, see
-L<... column "foo DESC" does not exist ...> for info on avoiding those.
-
=head2 column "foo DESC" does not exist ...
-This can happen if you've turned on quoting and then done something like
-this:
+This can happen if you are still using the obsolete order hack, and also
+happen to turn on sql-quoting.
$rs->search( {}, { order_by => [ 'name DESC' ] } );
-This results in SQL like this:
+Since L<DBIx::Class> >= 0.08100 and L<SQL::Abstract> >= 1.50 the above
+should be written as:
- ... ORDER BY "name DESC"
+ $rs->search( {}, { order_by => { -desc => 'name' } } );
-The solution is to pass your order_by items as scalar references to avoid
-quoting:
+For more ways to express order clauses refer to
+L<SQL::Abstract/ORDER_BY_CLAUSES>
- $rs->search( {}, { order_by => [ \'name DESC' ] } );
-
-Now you'll get SQL like this:
-
- ... ORDER BY name DESC
-
=head2 Perl Performance Issues on Red Hat Systems
There is a problem with slow performance of certain DBIx::Class
Modified: DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Relationship/ManyToMany.pm
===================================================================
--- DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Relationship/ManyToMany.pm 2010-01-19 12:41:19 UTC (rev 8378)
+++ DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Relationship/ManyToMany.pm 2010-01-19 12:47:48 UTC (rev 8379)
@@ -64,15 +64,15 @@
my $rs = $self->search_related($rel)->search_related(
$f_rel, @_ > 0 ? @_ : undef, { %{$rel_attrs||{}}, %$attrs }
);
- return $rs;
+ return $rs;
};
my $meth_name = join '::', $class, $meth;
*$meth_name = Sub::Name::subname $meth_name, sub {
- my $self = shift;
- my $rs = $self->$rs_meth( @_ );
- return (wantarray ? $rs->all : $rs);
- };
+ my $self = shift;
+ my $rs = $self->$rs_meth( @_ );
+ return (wantarray ? $rs->all : $rs);
+ };
my $add_meth_name = join '::', $class, $add_meth;
*$add_meth_name = Sub::Name::subname $add_meth_name, sub {
@@ -102,7 +102,7 @@
my $link = $self->search_related($rel)->new_result($link_vals);
$link->set_from_related($f_rel, $obj);
$link->insert();
- return $obj;
+ return $obj;
};
my $set_meth_name = join '::', $class, $set_meth;
Modified: DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/ResultSet.pm
===================================================================
--- DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/ResultSet.pm 2010-01-19 12:41:19 UTC (rev 8378)
+++ DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/ResultSet.pm 2010-01-19 12:47:48 UTC (rev 8379)
@@ -974,19 +974,6 @@
sub _collapse_result {
my ($self, $as_proto, $row) = @_;
- # if the first row that ever came in is totally empty - this means we got
- # hit by a smooth^Wempty left-joined resultset. Just noop in that case
- # instead of producing a {}
- #
- my $has_def;
- for (@$row) {
- if (defined $_) {
- $has_def++;
- last;
- }
- }
- return undef unless $has_def;
-
my @copy = @$row;
# 'foo' => [ undef, 'foo' ]
@@ -1247,11 +1234,6 @@
$tmp_attrs->{select} = $rsrc->storage->_count_select ($rsrc, $tmp_attrs);
$tmp_attrs->{as} = 'count';
- # read the comment on top of the actual function to see what this does
- $tmp_attrs->{from} = $self->result_source->schema->storage->_straight_join_to_node (
- $tmp_attrs->{from}, $tmp_attrs->{alias}
- );
-
my $tmp_rs = $rsrc->resultset_class->new($rsrc, $tmp_attrs)->get_column ('count');
return $tmp_rs;
@@ -1279,11 +1261,6 @@
$sub_attrs->{select} = $rsrc->storage->_subq_count_select ($rsrc, $sub_attrs);
- # read the comment on top of the actual function to see what this does
- $sub_attrs->{from} = $self->result_source->schema->storage->_straight_join_to_node (
- $sub_attrs->{from}, $sub_attrs->{alias}
- );
-
# this is so that the query can be simplified e.g.
# * non-limiting joins can be pruned
# * ordering can be thrown away in things like Top limit
@@ -2510,10 +2487,11 @@
$self->{related_resultsets} ||= {};
return $self->{related_resultsets}{$rel} ||= do {
- my $rel_info = $self->result_source->relationship_info($rel);
+ my $rsrc = $self->result_source;
+ my $rel_info = $rsrc->relationship_info($rel);
$self->throw_exception(
- "search_related: result source '" . $self->result_source->source_name .
+ "search_related: result source '" . $rsrc->source_name .
"' has no such relationship $rel")
unless $rel_info;
@@ -2524,6 +2502,13 @@
my $alias = $self->result_source->storage
->relname_to_table_alias($rel, $join_count);
+ # since this is search_related, and we already slid the select window inwards
+ # (the select/as attrs were deleted in the beginning), we need to flip all
+ # left joins to inner, so we get the expected results
+ # read the comment on top of the actual function to see what this does
+ $attrs->{from} = $rsrc->schema->storage->_straight_join_to_node ($attrs->{from}, $alias);
+
+
#XXX - temp fix for result_class bug. There likely is a more elegant fix -groditi
delete @{$attrs}{qw(result_class alias)};
@@ -2536,7 +2521,7 @@
}
}
- my $rel_source = $self->result_source->related_source($rel);
+ my $rel_source = $rsrc->related_source($rel);
my $new = do {
@@ -2687,7 +2672,6 @@
# the join in question so we could tell it *is* the search_related)
my $already_joined;
-
# we consider the last one thus reverse
for my $j (reverse @requested_joins) {
if ($rel eq $j->[0]{-join_path}[-1]) {
@@ -2696,7 +2680,6 @@
last;
}
}
-
# alternative way to scan the entire chain - not backwards compatible
# for my $j (reverse @$from) {
# next unless ref $j eq 'ARRAY';
Modified: DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/ResultSourceProxy.pm
===================================================================
--- DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/ResultSourceProxy.pm 2010-01-19 12:41:19 UTC (rev 8378)
+++ DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/ResultSourceProxy.pm 2010-01-19 12:47:48 UTC (rev 8379)
@@ -41,7 +41,9 @@
}
}
-*add_column = \&add_columns;
+sub add_column {
+ shift->add_columns(@_);
+}
sub has_column {
shift->result_source_instance->has_column(@_);
Modified: DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Row.pm
===================================================================
--- DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Row.pm 2010-01-19 12:41:19 UTC (rev 8378)
+++ DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Row.pm 2010-01-19 12:47:48 UTC (rev 8379)
@@ -527,7 +527,9 @@
this behaviour off, pass C<< cascade_delete => 0 >> in the C<$attr>
hashref of the relationship, see L<DBIx::Class::Relationship>. Any
database-level cascade or restrict will take precedence over a
-DBIx-Class-based cascading delete.
+DBIx-Class-based cascading delete, since DBIx-Class B<deletes the
+main row first> and only then attempts to delete any remaining related
+rows.
If you delete an object within a txn_do() (see L<DBIx::Class::Storage/txn_do>)
and the transaction subsequently fails, the row object will remain marked as
Modified: DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Schema/Versioned.pm
===================================================================
--- DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Schema/Versioned.pm 2010-01-19 12:41:19 UTC (rev 8378)
+++ DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Schema/Versioned.pm 2010-01-19 12:47:48 UTC (rev 8379)
@@ -268,7 +268,7 @@
=cut
sub create_upgrade_path {
- ## override this method
+ ## override this method
}
=head2 ordered_schema_versions
@@ -418,7 +418,7 @@
return;
}
- carp "\nDB version ($db_version) is lower than the schema version (".$self->schema_version."). Attempting upgrade.\n";
+ carp "DB version ($db_version) is lower than the schema version (".$self->schema_version."). Attempting upgrade.\n";
# backup if necessary then apply upgrade
$self->_filedata($self->_read_sql_file($upgrade_file));
@@ -488,7 +488,7 @@
sub apply_statement {
my ($self, $statement) = @_;
- $self->storage->dbh->do($_) or carp "SQL was:\n $_";
+ $self->storage->dbh->do($_) or carp "SQL was: $_";
}
=head2 get_db_version
@@ -599,7 +599,7 @@
return 1;
}
- carp "Versions out of sync. This is " . $self->schema_version .
+ carp "Versions out of sync. This is " . $self->schema_version .
", your database contains version $pversion, please call upgrade on your Schema.\n";
}
Modified: DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Storage/DBI/AmbiguousGlob.pm
===================================================================
--- DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Storage/DBI/AmbiguousGlob.pm 2010-01-19 12:41:19 UTC (rev 8378)
+++ DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Storage/DBI/AmbiguousGlob.pm 2010-01-19 12:47:48 UTC (rev 8379)
@@ -27,6 +27,9 @@
sub _subq_count_select {
my ($self, $source, $rs_attrs) = @_;
+
+ return $rs_attrs->{group_by} if $rs_attrs->{group_by};
+
my @pcols = map { join '.', $rs_attrs->{alias}, $_ } ($source->primary_columns);
return @pcols ? \@pcols : [ 1 ];
}
Modified: DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Storage/DBI/Oracle/Generic.pm
===================================================================
--- DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Storage/DBI/Oracle/Generic.pm 2010-01-19 12:41:19 UTC (rev 8378)
+++ DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Storage/DBI/Oracle/Generic.pm 2010-01-19 12:47:48 UTC (rev 8379)
@@ -209,11 +209,15 @@
my $timestamp_tz_format = $ENV{NLS_TIMESTAMP_TZ_FORMAT} ||=
'YYYY-MM-DD HH24:MI:SS.FF TZHTZM';
- $self->_do_query("alter session set nls_date_format = '$date_format'");
$self->_do_query(
-"alter session set nls_timestamp_format = '$timestamp_format'");
+ "alter session set nls_date_format = '$date_format'"
+ );
$self->_do_query(
-"alter session set nls_timestamp_tz_format='$timestamp_tz_format'");
+ "alter session set nls_timestamp_format = '$timestamp_format'"
+ );
+ $self->_do_query(
+ "alter session set nls_timestamp_tz_format='$timestamp_tz_format'"
+ );
}
=head2 source_bind_attributes
@@ -235,35 +239,35 @@
sub source_bind_attributes
{
- require DBD::Oracle;
- my $self = shift;
- my($source) = @_;
+ require DBD::Oracle;
+ my $self = shift;
+ my($source) = @_;
- my %bind_attributes;
+ my %bind_attributes;
- foreach my $column ($source->columns) {
- my $data_type = $source->column_info($column)->{data_type} || '';
- next unless $data_type;
+ foreach my $column ($source->columns) {
+ my $data_type = $source->column_info($column)->{data_type} || '';
+ next unless $data_type;
- my %column_bind_attrs = $self->bind_attribute_by_data_type($data_type);
+ my %column_bind_attrs = $self->bind_attribute_by_data_type($data_type);
- if ($data_type =~ /^[BC]LOB$/i) {
- $column_bind_attrs{'ora_type'} = uc($data_type) eq 'CLOB' ?
- DBD::Oracle::ORA_CLOB() :
- DBD::Oracle::ORA_BLOB();
- $column_bind_attrs{'ora_field'} = $column;
- }
+ if ($data_type =~ /^[BC]LOB$/i) {
+ $column_bind_attrs{'ora_type'} = uc($data_type) eq 'CLOB'
+ ? DBD::Oracle::ORA_CLOB()
+ : DBD::Oracle::ORA_BLOB()
+ ;
+ $column_bind_attrs{'ora_field'} = $column;
+ }
- $bind_attributes{$column} = \%column_bind_attrs;
- }
+ $bind_attributes{$column} = \%column_bind_attrs;
+ }
- return \%bind_attributes;
+ return \%bind_attributes;
}
sub _svp_begin {
- my ($self, $name) = @_;
-
- $self->_get_dbh->do("SAVEPOINT $name");
+ my ($self, $name) = @_;
+ $self->_get_dbh->do("SAVEPOINT $name");
}
# Oracle automatically releases a savepoint when you start another one with the
@@ -271,9 +275,8 @@
sub _svp_release { 1 }
sub _svp_rollback {
- my ($self, $name) = @_;
-
- $self->_get_dbh->do("ROLLBACK TO SAVEPOINT $name")
+ my ($self, $name) = @_;
+ $self->_get_dbh->do("ROLLBACK TO SAVEPOINT $name")
}
=head2 relname_to_table_alias
Modified: DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Storage/DBI/Replicated/Pool.pm
===================================================================
--- DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Storage/DBI/Replicated/Pool.pm 2010-01-19 12:41:19 UTC (rev 8378)
+++ DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Storage/DBI/Replicated/Pool.pm 2010-01-19 12:47:48 UTC (rev 8379)
@@ -280,16 +280,15 @@
eval {
$code->()
- };
+ };
if ($@) {
- $replicant
- ->debugobj
- ->print(
- sprintf( "Exception trying to $name for replicant %s, error is %s",
- $replicant->_dbi_connect_info->[0], $@)
- );
- return;
+ $replicant->debugobj->print(sprintf(
+ "Exception trying to $name for replicant %s, error is %s",
+ $replicant->_dbi_connect_info->[0], $@)
+ );
+ return undef;
}
+
return 1;
}
Modified: DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Storage/DBI/Replicated.pm
===================================================================
--- DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Storage/DBI/Replicated.pm 2010-01-19 12:41:19 UTC (rev 8378)
+++ DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Storage/DBI/Replicated.pm 2010-01-19 12:47:48 UTC (rev 8379)
@@ -409,7 +409,7 @@
=cut
sub BUILDARGS {
- my ($class, $schema, $storage_type_args, @args) = @_;
+ my ($class, $schema, $storage_type_args, @args) = @_;
return {
schema=>$schema,
Modified: DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Storage/DBI/mysql.pm
===================================================================
--- DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Storage/DBI/mysql.pm 2010-01-19 12:41:19 UTC (rev 8378)
+++ DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class/Storage/DBI/mysql.pm 2010-01-19 12:47:48 UTC (rev 8379)
@@ -106,6 +106,19 @@
session variables such that MySQL behaves more predictably as far as the
SQL standard is concerned.
+=head1 STORAGE OPTIONS
+
+=head2 set_strict_mode
+
+Enables session-wide strict options upon connecting. Equivalent to:
+
+ ->connect ( ... , {
+ on_connect_do => [
+ q|SET SQL_MODE = CONCAT('ANSI,TRADITIONAL,ONLY_FULL_GROUP_BY,', @@sql_mode)|,
+ q|SET SQL_AUTO_IS_NULL = 0|,
+ ]
+ });
+
=head1 AUTHORS
See L<DBIx::Class/CONTRIBUTORS>
Modified: DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class.pm
===================================================================
--- DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class.pm 2010-01-19 12:41:19 UTC (rev 8378)
+++ DBIx-Class/0.08/branches/multiple_version_upgrade/lib/DBIx/Class.pm 2010-01-19 12:47:48 UTC (rev 8379)
@@ -319,7 +319,7 @@
rdj: Ryan D Johnson <ryan at innerfence.com>
-ribasushi: Peter Rabbitson <rabbit+dbic at rabbit.us>
+ribasushi: Peter Rabbitson <ribasushi at cpan.org>
rjbs: Ricardo Signes <rjbs at cpan.org>
Modified: DBIx-Class/0.08/branches/multiple_version_upgrade/lib/SQL/Translator/Parser/DBIx/Class.pm
===================================================================
--- DBIx-Class/0.08/branches/multiple_version_upgrade/lib/SQL/Translator/Parser/DBIx/Class.pm 2010-01-19 12:41:19 UTC (rev 8378)
+++ DBIx-Class/0.08/branches/multiple_version_upgrade/lib/SQL/Translator/Parser/DBIx/Class.pm 2010-01-19 12:47:48 UTC (rev 8379)
@@ -206,8 +206,7 @@
}
}
- if($rel_table)
- {
+ if($rel_table) {
# Constraints are added only if applicable
next unless $fk_constraint;
@@ -216,7 +215,6 @@
next if $created_FK_rels{$rel_table}->{$key_test};
if (scalar(@keys)) {
-
$created_FK_rels{$rel_table}->{$key_test} = 1;
my $is_deferrable = $rel_info->{attrs}{is_deferrable};
@@ -228,25 +226,33 @@
}
$table->add_constraint(
- type => 'foreign_key',
- name => join('_', $table_name, 'fk', @keys),
- fields => \@keys,
- reference_fields => \@refkeys,
- reference_table => $rel_table,
- on_delete => uc ($cascade->{delete} || ''),
- on_update => uc ($cascade->{update} || ''),
- (defined $is_deferrable ? ( deferrable => $is_deferrable ) : ()),
+ type => 'foreign_key',
+ name => join('_', $table_name, 'fk', @keys),
+ fields => \@keys,
+ reference_fields => \@refkeys,
+ reference_table => $rel_table,
+ on_delete => uc ($cascade->{delete} || ''),
+ on_update => uc ($cascade->{update} || ''),
+ (defined $is_deferrable ? ( deferrable => $is_deferrable ) : ()),
);
# global parser_args add_fk_index param can be overridden on the rel def
my $add_fk_index_rel = (exists $rel_info->{attrs}{add_fk_index}) ? $rel_info->{attrs}{add_fk_index} : $add_fk_index;
+ # Check that we do not create an index identical to the PK index
+ # (some RDBMS croak on this, and it generally doesn't make much sense)
+ # NOTE: we do not sort the key columns because the order of
+ # columns is important for indexes and two indexes with the
+ # same cols but different order are allowed and sometimes
+ # needed
+ next if join("\x00", @keys) eq join("\x00", @primary);
+
if ($add_fk_index_rel) {
my $index = $table->add_index(
- name => join('_', $table_name, 'idx', @keys),
- fields => \@keys,
- type => 'NORMAL',
- );
+ name => join('_', $table_name, 'idx', @keys),
+ fields => \@keys,
+ type => 'NORMAL',
+ );
}
}
}
@@ -379,7 +385,14 @@
my $schema = MyApp::Schema->connect;
my $trans = SQL::Translator->new (
parser => 'SQL::Translator::Parser::DBIx::Class',
- parser_args => { package => $schema },
+ parser_args => {
+ package => $schema,
+ add_fk_index => 0,
+ sources => [qw/
+ Artist
+ CD
+ /],
+ },
producer => 'SQLite',
) or die SQL::Translator->error;
my $out = $trans->translate() or die $trans->error;
@@ -401,14 +414,34 @@
have SQL::Translator installed. To do this see
L<DBIx::Class::Schema/create_ddl_dir>.
+=head1 PARSER OPTIONS
+
+=head2 add_fk_index
+
+Create an index for each foreign key.
+Enabled by default, as having indexed foreign key columns is normally the
+sensible thing to do.
+
+=head2 sources
+
+=over 4
+
+=item Arguments: \@class_names
+
+=back
+
+Limit the amount of parsed sources by supplying an explicit list of source names.
+
=head1 SEE ALSO
L<SQL::Translator>, L<DBIx::Class::Schema>
=head1 AUTHORS
-Jess Robinson
+See L<DBIx::Class/CONTRIBUTORS>.
-Matt S Trout
+=head1 LICENSE
-Ash Berlin
+You may distribute this code under the same terms as Perl itself.
+
+=cut
Modified: DBIx-Class/0.08/branches/multiple_version_upgrade/t/71mysql.t
===================================================================
--- DBIx-Class/0.08/branches/multiple_version_upgrade/t/71mysql.t 2010-01-19 12:41:19 UTC (rev 8378)
+++ DBIx-Class/0.08/branches/multiple_version_upgrade/t/71mysql.t 2010-01-19 12:47:48 UTC (rev 8379)
@@ -225,6 +225,23 @@
=> 'Nothing Found!';
}
+# check for proper grouped counts
+{
+ my $ansi_schema = DBICTest::Schema->connect ($dsn, $user, $pass, { on_connect_call => 'set_strict_mode' });
+ my $rs = $ansi_schema->resultset('CD');
+
+ my $years;
+ $years->{$_->year|| scalar keys %$years}++ for $rs->all; # NULL != NULL, thus the keys eval
+
+ lives_ok ( sub {
+ is (
+ $rs->search ({}, { group_by => 'year'})->count,
+ scalar keys %$years,
+ 'grouped count correct',
+ );
+ }, 'Grouped count does not throw');
+}
+
ZEROINSEARCH: {
my $cds_per_year = {
2001 => 2,
Modified: DBIx-Class/0.08/branches/multiple_version_upgrade/t/86sqlt.t
===================================================================
--- DBIx-Class/0.08/branches/multiple_version_upgrade/t/86sqlt.t 2010-01-19 12:41:19 UTC (rev 8378)
+++ DBIx-Class/0.08/branches/multiple_version_upgrade/t/86sqlt.t 2010-01-19 12:47:48 UTC (rev 8379)
@@ -269,6 +269,7 @@
'name' => 'forceforeign_fk_artist', 'index_name' => 'forceforeign_idx_artist',
'selftable' => 'forceforeign', 'foreigntable' => 'artist',
'selfcols' => ['artist'], 'foreigncols' => ['artistid'],
+ 'noindex' => 1,
on_delete => '', on_update => '', deferrable => 1,
},
],
@@ -464,21 +465,21 @@
my ($expected, $got) = @_;
my $desc = $expected->{display};
is( $got->name, $expected->{name},
- "name parameter correct for `$desc'" );
+ "name parameter correct for '$desc'" );
is( $got->on_delete, $expected->{on_delete},
- "on_delete parameter correct for `$desc'" );
+ "on_delete parameter correct for '$desc'" );
is( $got->on_update, $expected->{on_update},
- "on_update parameter correct for `$desc'" );
+ "on_update parameter correct for '$desc'" );
is( $got->deferrable, $expected->{deferrable},
- "is_deferrable parameter correct for `$desc'" );
+ "is_deferrable parameter correct for '$desc'" );
my $index = get_index( $got->table, { fields => $expected->{selfcols} } );
if ($expected->{noindex}) {
- ok( !defined $index, "index doesn't for `$desc'" );
+ ok( !defined $index, "index doesn't for '$desc'" );
} else {
- ok( defined $index, "index exists for `$desc'" );
- is( $index->name, $expected->{index_name}, "index has correct name for `$desc'" );
+ ok( defined $index, "index exists for '$desc'" );
+ is( $index->name, $expected->{index_name}, "index has correct name for '$desc'" );
}
}
@@ -486,7 +487,7 @@
my ($expected, $got) = @_;
my $desc = $expected->{display};
is( $got->name, $expected->{name},
- "name parameter correct for `$desc'" );
+ "name parameter correct for '$desc'" );
}
done_testing;
Modified: DBIx-Class/0.08/branches/multiple_version_upgrade/t/94versioning.t
===================================================================
--- DBIx-Class/0.08/branches/multiple_version_upgrade/t/94versioning.t 2010-01-19 12:41:19 UTC (rev 8378)
+++ DBIx-Class/0.08/branches/multiple_version_upgrade/t/94versioning.t 2010-01-19 12:47:48 UTC (rev 8379)
@@ -3,7 +3,10 @@
use strict;
use warnings;
use Test::More;
-use File::Spec;
+use Test::Warn;
+use Test::Exception;
+
+use Path::Class;
use File::Copy;
#warn "$dsn $user $pass";
@@ -28,13 +31,13 @@
my $version_table_name = 'dbix_class_schema_versions';
my $old_table_name = 'SchemaVersions';
-my $ddl_dir = File::Spec->catdir ('t', 'var');
+my $ddl_dir = dir ('t', 'var');
my $fn = {
- v1 => File::Spec->catfile($ddl_dir, 'DBICVersion-Schema-1.0-MySQL.sql'),
- v2 => File::Spec->catfile($ddl_dir, 'DBICVersion-Schema-2.0-MySQL.sql'),
- v3 => File::Spec->catfile($ddl_dir, 'DBICVersion-Schema-3.0-MySQL.sql'),
- trans_v12 => File::Spec->catfile($ddl_dir, 'DBICVersion-Schema-1.0-2.0-MySQL.sql'),
- trans_v23 => File::Spec->catfile($ddl_dir, 'DBICVersion-Schema-2.0-3.0-MySQL.sql'),
+ v1 => $ddl_dir->file ('DBICVersion-Schema-1.0-MySQL.sql'),
+ v2 => $ddl_dir->file ('DBICVersion-Schema-2.0-MySQL.sql'),
+ v3 => $ddl_dir->file ('DBICVersion-Schema-3.0-MySQL.sql'),
+ trans_v12 => $ddl_dir-> ('DBICVersion-Schema-1.0-2.0-MySQL.sql'),
+ trans_v23 => $ddl_dir-> ('DBICVersion-Schema-2.0-3.0-MySQL.sql'),
};
use lib qw(t/lib);
@@ -70,58 +73,46 @@
$schema_v2->create_ddl_dir('MySQL', '2.0', $ddl_dir, '1.0');
ok(-f $fn->{trans_v12}, 'Created DDL file');
- {
- my $w;
- local $SIG{__WARN__} = sub { $w = shift };
+ sleep 1; # remove this when TODO below is completed
+ warnings_like (
+ sub { $schema_v2->upgrade() },
+ qr/DB version .+? is lower than the schema version/,
+ 'Warn before upgrade',
+ );
- $schema_v2->upgrade();
- like ($w, qr/Attempting upgrade\.$/, 'Warn before upgrade');
- }
-
is($schema_v2->get_db_version(), '2.0', 'db version number upgraded');
- eval {
+ lives_ok ( sub {
$schema_v2->storage->dbh->do('select NewVersionName from TestVersion');
- };
- is($@, '', 'new column created');
+ }, 'new column created' );
- # should overwrite files and warn about it
- my @w;
- local $SIG{__WARN__} = sub {
- if ($_[0] =~ /Overwriting existing/) {
- push @w, $_[0];
- }
- else {
- warn @_;
- }
- };
- $schema_v2->create_ddl_dir('MySQL', '2.0', $ddl_dir, '1.0');
-
- is (2, @w, 'A warning generated for both the DDL and the diff');
- like ($w[0], qr/Overwriting existing DDL file - $fn->{v2}/, 'New version DDL overwrite warning');
- like ($w[1], qr/Overwriting existing diff file - $fn->{trans_v12}/, 'Upgrade diff overwrite warning');
+ warnings_exist (
+ sub { $schema_v2->create_ddl_dir('MySQL', '2.0', $ddl_dir, '1.0') },
+ [
+ qr/Overwriting existing DDL file - $fn->{v2}/,
+ qr/Overwriting existing diff file - $fn->{trans}/,
+ ],
+ 'An overwrite warning generated for both the DDL and the diff',
+ );
}
{
my $schema_version = DBICVersion::Schema->connect($dsn, $user, $pass);
- eval {
+ lives_ok (sub {
$schema_version->storage->dbh->do('select * from ' . $version_table_name);
- };
- is($@, '', 'version table exists');
+ }, 'version table exists');
- eval {
+ lives_ok (sub {
$schema_version->storage->dbh->do("DROP TABLE IF EXISTS $old_table_name");
$schema_version->storage->dbh->do("RENAME TABLE $version_table_name TO $old_table_name");
- };
- is($@, '', 'versions table renamed to old style table');
+ }, 'versions table renamed to old style table');
$schema_version = DBICVersion::Schema->connect($dsn, $user, $pass);
is($schema_version->get_db_version, '2.0', 'transition from old table name to new okay');
- eval {
+ dies_ok (sub {
$schema_version->storage->dbh->do('select * from ' . $old_table_name);
- };
- ok($@, 'old version table gone');
+ }, 'old version table gone');
}
@@ -190,28 +181,23 @@
};
- my $warn = '';
- local $SIG{__WARN__} = sub { $warn = shift };
- $schema_version = DBICVersion::Schema->connect($dsn, $user, $pass);
- like($warn, qr/Your DB is currently unversioned/, 'warning detected without env var or attr');
+ warnings_like ( sub {
+ $schema_version = DBICVersion::Schema->connect($dsn, $user, $pass);
+ }, qr/Your DB is currently unversioned/, 'warning detected without env var or attr' );
+ warnings_like ( sub {
+ $schema_version = DBICVersion::Schema->connect($dsn, $user, $pass, { ignore_version => 1 });
+ }, [], 'warning not detected with attr set');
- # should warn
- $warn = '';
- $schema_version = DBICVersion::Schema->connect($dsn, $user, $pass, { ignore_version => 1 });
- is($warn, '', 'warning not detected with attr set');
- # should not warn
local $ENV{DBIC_NO_VERSION_CHECK} = 1;
- $warn = '';
- $schema_version = DBICVersion::Schema->connect($dsn, $user, $pass);
- is($warn, '', 'warning not detected with env var set');
- # should not warn
+ warnings_like ( sub {
+ $schema_version = DBICVersion::Schema->connect($dsn, $user, $pass);
+ }, [], 'warning not detected with env var set');
- $warn = '';
- $schema_version = DBICVersion::Schema->connect($dsn, $user, $pass, { ignore_version => 0 });
- like($warn, qr/Your DB is currently unversioned/, 'warning detected without env var or attr');
- # should warn
+ warnings_like ( sub {
+ $schema_version = DBICVersion::Schema->connect($dsn, $user, $pass, { ignore_version => 0 });
+ }, qr/Your DB is currently unversioned/, 'warning detected without env var or attr');
}
# attempt a deploy/upgrade cycle within one second
Modified: DBIx-Class/0.08/branches/multiple_version_upgrade/t/99dbic_sqlt_parser.t
===================================================================
--- DBIx-Class/0.08/branches/multiple_version_upgrade/t/99dbic_sqlt_parser.t 2010-01-19 12:41:19 UTC (rev 8378)
+++ DBIx-Class/0.08/branches/multiple_version_upgrade/t/99dbic_sqlt_parser.t 2010-01-19 12:47:48 UTC (rev 8379)
@@ -35,35 +35,50 @@
$schema->sources
;
-{
+my $idx_exceptions = {
+ 'Artwork' => -1,
+ 'ForceForeign' => -1,
+ 'LinerNotes' => -1,
+ 'TwoKeys' => -1, # TwoKeys has the index turned off on the rel def
+};
+
+{
my $sqlt_schema = create_schema({ schema => $schema, args => { parser_args => { } } });
- foreach my $source (@sources) {
- my $table = get_table($sqlt_schema, $schema, $source);
+ foreach my $source_name (@sources) {
+ my $table = get_table($sqlt_schema, $schema, $source_name);
my $fk_count = scalar(grep { $_->type eq 'FOREIGN KEY' } $table->get_constraints);
+ $fk_count += $idx_exceptions->{$source_name} || 0;
my @indices = $table->get_indices;
+
my $index_count = scalar(@indices);
- $index_count++ if ($source eq 'TwoKeys'); # TwoKeys has the index turned off on the rel def
- is($index_count, $fk_count, "correct number of indices for $source with no args");
+ is($index_count, $fk_count, "correct number of indices for $source_name with no args");
+
+ for my $index (@indices) {
+ my $source = $schema->source($source_name);
+ my $pk_test = join("\x00", $source->primary_columns);
+ my $idx_test = join("\x00", $index->fields);
+ isnt ( $pk_test, $idx_test, "no additional index for the primary columns exists in $source_name");
+ }
}
}
-{
+{
my $sqlt_schema = create_schema({ schema => $schema, args => { parser_args => { add_fk_index => 1 } } });
- foreach my $source (@sources) {
- my $table = get_table($sqlt_schema, $schema, $source);
+ foreach my $source_name (@sources) {
+ my $table = get_table($sqlt_schema, $schema, $source_name);
my $fk_count = scalar(grep { $_->type eq 'FOREIGN KEY' } $table->get_constraints);
+ $fk_count += $idx_exceptions->{$source_name} || 0;
my @indices = $table->get_indices;
my $index_count = scalar(@indices);
- $index_count++ if ($source eq 'TwoKeys'); # TwoKeys has the index turned off on the rel def
- is($index_count, $fk_count, "correct number of indices for $source with add_fk_index => 1");
+ is($index_count, $fk_count, "correct number of indices for $source_name with add_fk_index => 1");
}
}
-{
+{
my $sqlt_schema = create_schema({ schema => $schema, args => { parser_args => { add_fk_index => 0 } } });
foreach my $source (@sources) {
@@ -75,7 +90,7 @@
}
}
-{
+{
{
package # hide from PAUSE
DBICTest::Schema::NoViewDefinition;
Modified: DBIx-Class/0.08/branches/multiple_version_upgrade/t/inflate/hri.t
===================================================================
--- DBIx-Class/0.08/branches/multiple_version_upgrade/t/inflate/hri.t 2010-01-19 12:41:19 UTC (rev 8378)
+++ DBIx-Class/0.08/branches/multiple_version_upgrade/t/inflate/hri.t 2010-01-19 12:47:48 UTC (rev 8379)
@@ -45,7 +45,7 @@
my @dbic_reltable = $dbic_obj->$col;
my @hashref_reltable = @{$datahashref->{$col}};
- is (scalar @hashref_reltable, scalar @dbic_reltable, 'number of related entries');
+ is (scalar @dbic_reltable, scalar @hashref_reltable, 'number of related entries');
# for my $index (0..scalar @hashref_reltable) {
for my $index (0..scalar @dbic_reltable) {
Modified: DBIx-Class/0.08/branches/multiple_version_upgrade/t/lib/DBICTest.pm
===================================================================
--- DBIx-Class/0.08/branches/multiple_version_upgrade/t/lib/DBICTest.pm 2010-01-19 12:41:19 UTC (rev 8378)
+++ DBIx-Class/0.08/branches/multiple_version_upgrade/t/lib/DBICTest.pm 2010-01-19 12:47:48 UTC (rev 8379)
@@ -32,7 +32,7 @@
no_populate=>1,
storage_type=>'::DBI::Replicated',
storage_type_args=>{
- balancer_type=>'DBIx::Class::Storage::DBI::Replicated::Balancer::Random'
+ balancer_type=>'DBIx::Class::Storage::DBI::Replicated::Balancer::Random'
},
);
@@ -48,7 +48,7 @@
=cut
sub has_custom_dsn {
- return $ENV{"DBICTEST_DSN"} ? 1:0;
+ return $ENV{"DBICTEST_DSN"} ? 1:0;
}
sub _sqlite_dbfilename {
@@ -59,7 +59,7 @@
my $self = shift;
my %args = @_;
return $self->_sqlite_dbfilename if $args{sqlite_use_file} or $ENV{"DBICTEST_SQLITE_USE_FILE"};
- return ":memory:";
+ return ":memory:";
}
sub _database {
@@ -85,7 +85,7 @@
my %args = @_;
my $schema;
-
+
if ($args{compose_connection}) {
$schema = DBICTest::Schema->compose_connection(
'DBICTest', $self->_database(%args)
@@ -94,8 +94,8 @@
$schema = DBICTest::Schema->compose_namespace('DBICTest');
}
if( $args{storage_type}) {
- $schema->storage_type($args{storage_type});
- }
+ $schema->storage_type($args{storage_type});
+ }
if ( !$args{no_connect} ) {
$schema = $schema->connect($self->_database(%args));
$schema->storage->on_connect_do(['PRAGMA synchronous = OFF'])
Modified: DBIx-Class/0.08/branches/multiple_version_upgrade/t/lib/sqlite.sql
===================================================================
--- DBIx-Class/0.08/branches/multiple_version_upgrade/t/lib/sqlite.sql 2010-01-19 12:41:19 UTC (rev 8378)
+++ DBIx-Class/0.08/branches/multiple_version_upgrade/t/lib/sqlite.sql 2010-01-19 12:47:48 UTC (rev 8379)
@@ -1,6 +1,6 @@
--
-- Created by SQL::Translator::Producer::SQLite
--- Created on Sun Nov 15 14:13:02 2009
+-- Created on Tue Jan 19 12:46:12 2010
--
@@ -262,8 +262,6 @@
cd integer NOT NULL
);
-CREATE INDEX forceforeign_idx_artist ON forceforeign (artist);
-
--
-- Table: self_ref_alias
--
@@ -346,8 +344,6 @@
cd_id INTEGER PRIMARY KEY NOT NULL
);
-CREATE INDEX cd_artwork_idx_cd_id ON cd_artwork (cd_id);
-
--
-- Table: liner_notes
--
@@ -356,8 +352,6 @@
notes varchar(100) NOT NULL
);
-CREATE INDEX liner_notes_idx_liner_id ON liner_notes (liner_id);
-
--
-- Table: lyric_versions
--
Modified: DBIx-Class/0.08/branches/multiple_version_upgrade/t/prefetch/double_prefetch.t
===================================================================
--- DBIx-Class/0.08/branches/multiple_version_upgrade/t/prefetch/double_prefetch.t 2010-01-19 12:41:19 UTC (rev 8378)
+++ DBIx-Class/0.08/branches/multiple_version_upgrade/t/prefetch/double_prefetch.t 2010-01-19 12:47:48 UTC (rev 8379)
@@ -27,7 +27,7 @@
single_track_2.trackid, single_track_2.cd, single_track_2.position, single_track_2.title, single_track_2.last_updated_on, single_track_2.last_updated_at, single_track_2.small_dt,
cd.cdid, cd.artist, cd.title, cd.year, cd.genreid, cd.single_track
FROM artist me
- LEFT JOIN cd cds ON cds.artist = me.artistid
+ JOIN cd cds ON cds.artist = me.artistid
LEFT JOIN track single_track ON single_track.trackid = cds.single_track
LEFT JOIN track single_track_2 ON single_track_2.trackid = cds.single_track
LEFT JOIN cd cd ON cd.cdid = single_track_2.cd
Modified: DBIx-Class/0.08/branches/multiple_version_upgrade/t/relationship/core.t
===================================================================
--- DBIx-Class/0.08/branches/multiple_version_upgrade/t/relationship/core.t 2010-01-19 12:41:19 UTC (rev 8378)
+++ DBIx-Class/0.08/branches/multiple_version_upgrade/t/relationship/core.t 2010-01-19 12:47:48 UTC (rev 8379)
@@ -268,7 +268,7 @@
'(
SELECT artist_undirected_maps.id1, artist_undirected_maps.id2
FROM artist me
- LEFT JOIN artist_undirected_map artist_undirected_maps
+ JOIN artist_undirected_map artist_undirected_maps
ON artist_undirected_maps.id1 = me.artistid OR artist_undirected_maps.id2 = me.artistid
WHERE ( artistid = ? )
)',
Added: DBIx-Class/0.08/branches/multiple_version_upgrade/t/resultset/nulls_only.t
===================================================================
--- DBIx-Class/0.08/branches/multiple_version_upgrade/t/resultset/nulls_only.t (rev 0)
+++ DBIx-Class/0.08/branches/multiple_version_upgrade/t/resultset/nulls_only.t 2010-01-19 12:47:48 UTC (rev 8379)
@@ -0,0 +1,29 @@
+use strict;
+use warnings;
+
+use lib qw(t/lib);
+use Test::More;
+use Test::Exception;
+use DBICTest;
+
+my $schema = DBICTest->init_schema();
+
+
+my $cd_rs = $schema->resultset('CD')->search ({ genreid => undef }, { columns => [ 'genreid' ]} );
+my $count = $cd_rs->count;
+cmp_ok ( $count, '>', 1, 'several CDs with no genre');
+
+my @objects = $cd_rs->all;
+is (scalar @objects, $count, 'Correct amount of objects without limit');
+isa_ok ($_, 'DBICTest::CD') for @objects;
+
+is_deeply (
+ [ map { values %{{$_->get_columns}} } (@objects) ],
+ [ (undef) x $count ],
+ 'All values are indeed undef'
+);
+
+
+isa_ok ($cd_rs->search ({}, { rows => 1 })->single, 'DBICTest::CD');
+
+done_testing;
Modified: DBIx-Class/0.08/branches/multiple_version_upgrade/t/search/related_strip_prefetch.t
===================================================================
--- DBIx-Class/0.08/branches/multiple_version_upgrade/t/search/related_strip_prefetch.t 2010-01-19 12:41:19 UTC (rev 8378)
+++ DBIx-Class/0.08/branches/multiple_version_upgrade/t/search/related_strip_prefetch.t 2010-01-19 12:47:48 UTC (rev 8379)
@@ -31,7 +31,7 @@
) me
JOIN artist artist ON artist.artistid = me.artist
LEFT JOIN track tracks ON tracks.cd = me.cdid
- LEFT JOIN tags tags ON tags.cd = me.cdid
+ JOIN tags tags ON tags.cd = me.cdid
WHERE ( tags.tag IS NOT NULL )
GROUP BY tags.tagid, tags.cd, tags.tag
)',
More information about the Bast-commits
mailing list