New attribute for DBD::File
In the git branch f_dir-ref (a wrong name now, as we changed some things in the development process), you can find a new extension DBD::File now understands a new attribute f_dir_search: f_dir_search This optional attribute can be set to pass a list of folders to also find existing tables. It will not be used to create new files. f_dir_search = [ /data/bar/csv, /dump/blargh/data ], A real-world example might explain this in more detail using DBD::CSV my $dbh = DBI-connect (dbi:CSV:, undef, undef, { f_schema = undef, f_dir= tmp, f_dir_search = [ sandbox, /tmp ], f_ext= .csv/r, f_lock = 2, f_encoding = utf8, RaiseError = 1, PrintError = 1, FetchHashKeyName = NAME_lc, }) or die $DBI::errstr\n; This will set the default folder for CSV files to be located in the folder tmp. This folder will also be used for creating tables. When opening a handle to an already existing table, and that table's file(s) cannot be found in the folder indicated by f_dir, the folders in the f_dirsearch (if present) will be searched for the files needed to open the table. my $sth = $dbh-prepare (select * from foo); will, using the above example, search for tmp/foo.csv sandbox/foo.csv /tmp/foo.csv The DBI test suite tests this option in t/51dbm_file.t If people have feedback, it would be appreciated. Both possitive and negative. If no objections exist, I'd like to merge this branch into master and request a new release, so we can release DBD::CSV shortly after -- H.Merijn Brand http://tux.nl Perl Monger http://amsterdam.pm.org/ using perl5.00307 .. 5.19 porting perl5 on HP-UX, AIX, and openSUSE http://mirrors.develooper.com/hpux/http://www.test-smoke.org/ http://qa.perl.org http://www.goldmark.org/jeff/stupid-disclaimers/
Re: New attribute for DBD::File
On 24/06/13 16:01, H.Merijn Brand wrote: In the git branch f_dir-ref (a wrong name now, as we changed some things in the development process), you can find a new extension DBD::File now understands a new attribute f_dir_search: f_dir_search This optional attribute can be set to pass a list of folders to also find existing tables. It will not be used to create new files. That does not make sense to me. Does it really mean: This optional attribute can be set to a list of folders which will be searched for existing tables and is not used when creating new tables. BTW, I presume you normally use the word folder (bit of a Windows thing) rather than directory (f_dir_search also suggests directory not folder). f_dir_search = [ /data/bar/csv, /dump/blargh/data ], A real-world example might explain this in more detail using DBD::CSV my $dbh = DBI-connect (dbi:CSV:, undef, undef, { f_schema = undef, f_dir= tmp, f_dir_search = [ sandbox, /tmp ], f_ext= .csv/r, f_lock = 2, f_encoding = utf8, RaiseError = 1, PrintError = 1, FetchHashKeyName = NAME_lc, }) or die $DBI::errstr\n; This will set the default folder for CSV files to be located in the folder tmp. This folder will also be used for creating tables. When opening a handle to an already existing table, and that table's file(s) cannot be found in the folder indicated by f_dir, the folders in the f_dirsearch (if present) will be searched for the files needed to open the table. my $sth = $dbh-prepare (select * from foo); will, using the above example, search for tmp/foo.csv sandbox/foo.csv /tmp/foo.csv The DBI test suite tests this option in t/51dbm_file.t If people have feedback, it would be appreciated. Both possitive and negative. If no objections exist, I'd like to merge this branch into master and request a new release, so we can release DBD::CSV shortly after Martin
Re: New attribute for DBD::File
On Mon, 24 Jun 2013 16:34:30 +0100, Martin J. Evans boh...@ntlworld.com wrote: On 24/06/13 16:01, H.Merijn Brand wrote: In the git branch f_dir-ref (a wrong name now, as we changed some things in the development process), you can find a new extension DBD::File now understands a new attribute f_dir_search: f_dir_search This optional attribute can be set to pass a list of folders to also find existing tables. It will not be used to create new files. That does not make sense to me. Does it really mean: This optional attribute can be set to a list of folders which will be searched for existing tables and is not used when creating new tables. I read exactly the same. I have no objection to this other phrasing if that makes thing clearer. BTW, I presume you normally use the word folder (bit of a Windows thing) rather than directory (f_dir_search also suggests directory not folder). Funny. I started of using f_dir_ext as in extending the dir tree for using tables, but Jens insisted on f_dir_search for Windows users iirc. Folders and directories are the same to me. f_dir_search = [ /data/bar/csv, /dump/blargh/data ], A real-world example might explain this in more detail using DBD::CSV my $dbh = DBI-connect (dbi:CSV:, undef, undef, { f_schema = undef, f_dir= tmp, f_dir_search = [ sandbox, /tmp ], f_ext= .csv/r, f_lock = 2, f_encoding = utf8, RaiseError = 1, PrintError = 1, FetchHashKeyName = NAME_lc, }) or die $DBI::errstr\n; This will set the default folder for CSV files to be located in the folder tmp. This folder will also be used for creating tables. When opening a handle to an already existing table, and that table's file(s) cannot be found in the folder indicated by f_dir, the folders in the f_dirsearch (if present) will be searched for the files needed to open the table. my $sth = $dbh-prepare (select * from foo); will, using the above example, search for tmp/foo.csv sandbox/foo.csv /tmp/foo.csv The DBI test suite tests this option in t/51dbm_file.t If people have feedback, it would be appreciated. Both possitive and negative. If no objections exist, I'd like to merge this branch into master and request a new release, so we can release DBD::CSV shortly after Martin -- H.Merijn Brand http://tux.nl Perl Monger http://amsterdam.pm.org/ using perl5.00307 .. 5.19 porting perl5 on HP-UX, AIX, and openSUSE http://mirrors.develooper.com/hpux/http://www.test-smoke.org/ http://qa.perl.org http://www.goldmark.org/jeff/stupid-disclaimers/
[perl5-dbi/DBI-Test] 36895c: Updates to DESIGN.md
Branch: refs/heads/master Home: https://github.com/perl5-dbi/DBI-Test Commit: 36895c2da2f357de357937013b1a195169bb8312 https://github.com/perl5-dbi/DBI-Test/commit/36895c2da2f357de357937013b1a195169bb8312 Author: Tim Bunce tim.bu...@pobox.com Date: 2013-06-24 (Mon, 24 Jun 2013) Changed paths: M DESIGN.md Log Message: --- Updates to DESIGN.md
[perl5-dbi/dbi] b80a2f: stop confusing duplicate defining @tbl ...
Branch: refs/heads/f_dir-ref Home: https://github.com/perl5-dbi/dbi Commit: b80a2f5c34f4e1befd53537bc6a0eeda4507fd97 https://github.com/perl5-dbi/dbi/commit/b80a2f5c34f4e1befd53537bc6a0eeda4507fd97 Author: Jens Rehsack s...@netbsd.org Date: 2013-06-24 (Mon, 24 Jun 2013) Changed paths: M t/51dbm_file.t Log Message: --- stop confusing duplicate defining @tbl ...
[perl5-dbi/dbi] dd4e5d: Tests for f_dir_search
Branch: refs/heads/f_dir-ref Home: https://github.com/perl5-dbi/dbi Commit: dd4e5dc84fc8b6d168deff5d4bc7540a9bcb6f09 https://github.com/perl5-dbi/dbi/commit/dd4e5dc84fc8b6d168deff5d4bc7540a9bcb6f09 Author: H.Merijn Brand - Tux h.m.br...@xs4all.nl Date: 2013-06-24 (Mon, 24 Jun 2013) Changed paths: M t/51dbm_file.t Log Message: --- Tests for f_dir_search
[perl5-dbi/dbi] 149bb7: revert empty string handling in Nano (f2a2df0)
Branch: refs/heads/master Home: https://github.com/perl5-dbi/dbi Commit: 149bb752910f2541198d4b20a61e079eedaaa3d5 https://github.com/perl5-dbi/dbi/commit/149bb752910f2541198d4b20a61e079eedaaa3d5 Author: Tim Bunce tim.bu...@pobox.com Date: 2013-06-24 (Mon, 24 Jun 2013) Changed paths: M Changes M lib/DBI/SQL/Nano.pm Log Message: --- revert empty string handling in Nano (f2a2df0)
[perl5-dbi/dbi] b11f83: Clarify bind_col TYPE attribute is sticky
Branch: refs/heads/f_dir-ref Home: https://github.com/perl5-dbi/dbi Commit: b11f837cef600fe6206a1423439ff27b83bf4a35 https://github.com/perl5-dbi/dbi/commit/b11f837cef600fe6206a1423439ff27b83bf4a35 Author: martin martin@smtp.easysoft.local Date: 2013-06-24 (Mon, 24 Jun 2013) Changed paths: M Changes M DBI.pm Log Message: --- Clarify bind_col TYPE attribute is sticky Commit: 07cf2f247bdbfd3d59627136e80b213016ab9117 https://github.com/perl5-dbi/dbi/commit/07cf2f247bdbfd3d59627136e80b213016ab9117 Author: Ville Skyttä ville.sky...@iki.fi Date: 2013-06-24 (Mon, 24 Jun 2013) Changed paths: M Changes M DBI.xs M DBIXS.h M INSTALL M Old/TODO_gofer.txt M dbiproxy.PL M devel/README M lib/DBD/DBM.pm M lib/DBD/File.pm M lib/DBD/Gofer.pm M lib/DBD/Gofer/Transport/Base.pm M lib/DBD/Multiplex.pm M lib/DBD/NullP.pm M lib/DBD/Proxy.pm M lib/DBI/DBD.pm M lib/DBI/DBD/SqlEngine.pm M lib/DBI/FAQ.pm M lib/DBI/Gofer/Execute.pm M lib/DBI/ProxyServer.pm M t/01basics.t M t/03handle.t M t/06attrs.t M t/30subclass.t M t/85gofer.t M t/lib.pl Log Message: --- Spelling fixes. Signed-off-by: H.Merijn Brand - Tux h.m.br...@xs4all.nl Commit: 196df56912145879e791e7c10ca087ae788c7587 https://github.com/perl5-dbi/dbi/commit/196df56912145879e791e7c10ca087ae788c7587 Author: H.Merijn Brand - Tux h.m.br...@xs4all.nl Date: 2013-06-24 (Mon, 24 Jun 2013) Changed paths: M Changes Log Message: --- Give Ville the credits for his patch As I used git-am, I could not include this change in the previous commit, unless I modified the patch to include this change :) Commit: 9bfd87b78a62d39165d3e1b7d7d8fa9115229156 https://github.com/perl5-dbi/dbi/commit/9bfd87b78a62d39165d3e1b7d7d8fa9115229156 Author: H.Merijn Brand - Tux h.m.br...@xs4all.nl Date: 2013-06-24 (Mon, 24 Jun 2013) Changed paths: M DBI.pm Log Message: --- one more typo Commit: 481a197712ea22a76ec4060addc59849264fcf49 https://github.com/perl5-dbi/dbi/commit/481a197712ea22a76ec4060addc59849264fcf49 Author: Jens Rehsack s...@netbsd.org Date: 2013-06-24 (Mon, 24 Jun 2013) Changed paths: M Changes M lib/DBI/SQL/Nano.pm Log Message: --- Fix handling 0 different from Handle strings evaluating to a false value correct when simply expecting data in DBI::SQL::Nano_::Statement part approval Commit: 98c69490d552bfb8c48fc323ca1c4c82082b5d9b https://github.com/perl5-dbi/dbi/commit/98c69490d552bfb8c48fc323ca1c4c82082b5d9b Author: H.Merijn Brand - Tux h.m.br...@xs4all.nl Date: 2013-06-24 (Mon, 24 Jun 2013) Changed paths: M Changes Log Message: --- Support multiple folders in DBD::File's f_dir attribute No tests yet and a few locations where things still will go wrong when the catdir () is involved Commit: bfb12060741352c2d72a91aed0a06082a04273a4 https://github.com/perl5-dbi/dbi/commit/bfb12060741352c2d72a91aed0a06082a04273a4 Author: H.Merijn Brand - Tux h.m.br...@xs4all.nl Date: 2013-06-24 (Mon, 24 Jun 2013) Changed paths: M Changes Log Message: --- Jens really prefers f_dir_search over f_dir_ext Compare: https://github.com/perl5-dbi/dbi/compare/b80a2f5c34f4...bfb120607413
[perl5-dbi/dbi] 6c74b2: Fix string prove in Nano (0 is not always false)
Branch: refs/heads/master Home: https://github.com/perl5-dbi/dbi Commit: 6c74b24f661c288e2bcffceee1e5ef505e2a6e6e https://github.com/perl5-dbi/dbi/commit/6c74b24f661c288e2bcffceee1e5ef505e2a6e6e Author: Jens Rehsack s...@netbsd.org Date: 2013-06-24 (Mon, 24 Jun 2013) Changed paths: M Changes M lib/DBI/SQL/Nano.pm Log Message: --- Fix string prove in Nano (0 is not always false) Handle strings evaluating to a false value correct when simply expecting data in DBI::SQL::Nano_::Statement part approval
[perl5-dbi/dbi] 6a5ada: Support multiple folders in DBD::File's f_dir attr...
Branch: refs/heads/master Home: https://github.com/perl5-dbi/dbi Commit: 6a5ada7b9e36edc32be5d34a39854660a4bf70b7 https://github.com/perl5-dbi/dbi/commit/6a5ada7b9e36edc32be5d34a39854660a4bf70b7 Author: H.Merijn Brand - Tux h.m.br...@xs4all.nl Date: 2013-06-11 (Tue, 11 Jun 2013) Changed paths: M Changes M lib/DBD/File.pm Log Message: --- Support multiple folders in DBD::File's f_dir attribute No tests yet and a few locations where things still will go wrong when the catdir () is involved Commit: f69132e9fc2b732892906bd91e6a1697aaec0e7d https://github.com/perl5-dbi/dbi/commit/f69132e9fc2b732892906bd91e6a1697aaec0e7d Author: H.Merijn Brand - Tux h.m.br...@xs4all.nl Date: 2013-06-11 (Tue, 11 Jun 2013) Changed paths: M lib/DBD/File.pm Log Message: --- Use a new attribute: f_dir_ext Extended dir search now more explicit. One of the reasons not to use a ref in f_dir is that the current definition is (very) clear and we should not break that. What e.g. would we use to write new files? If a table is opened from folder 2, then deleted and recreated, does that mean we should re-use folder 2? If f_dir working as before this problem disappears Commit: be61af1533b582da2397cc33194bd43122717f83 https://github.com/perl5-dbi/dbi/commit/be61af1533b582da2397cc33194bd43122717f83 Author: H.Merijn Brand - Tux h.m.br...@xs4all.nl Date: 2013-06-11 (Tue, 11 Jun 2013) Changed paths: M Changes M lib/DBD/File.pm Log Message: --- Jens really prefers f_dir_search over f_dir_ext Commit: 7b973933e1ed41866c9a85d0dbb970d0f2ad34b0 https://github.com/perl5-dbi/dbi/commit/7b973933e1ed41866c9a85d0dbb970d0f2ad34b0 Author: H.Merijn Brand - Tux h.m.br...@xs4all.nl Date: 2013-06-11 (Tue, 11 Jun 2013) Changed paths: M lib/DBD/File.pm Log Message: --- Make deep searches work. Tested with DBD::CSV, now all we need is sanity checks and agreement on this new feature Commit: dd4e5dc84fc8b6d168deff5d4bc7540a9bcb6f09 https://github.com/perl5-dbi/dbi/commit/dd4e5dc84fc8b6d168deff5d4bc7540a9bcb6f09 Author: H.Merijn Brand - Tux h.m.br...@xs4all.nl Date: 2013-06-24 (Mon, 24 Jun 2013) Changed paths: M t/51dbm_file.t Log Message: --- Tests for f_dir_search Commit: b80a2f5c34f4e1befd53537bc6a0eeda4507fd97 https://github.com/perl5-dbi/dbi/commit/b80a2f5c34f4e1befd53537bc6a0eeda4507fd97 Author: Jens Rehsack s...@netbsd.org Date: 2013-06-24 (Mon, 24 Jun 2013) Changed paths: M t/51dbm_file.t Log Message: --- stop confusing duplicate defining @tbl ... Commit: b11f837cef600fe6206a1423439ff27b83bf4a35 https://github.com/perl5-dbi/dbi/commit/b11f837cef600fe6206a1423439ff27b83bf4a35 Author: martin martin@smtp.easysoft.local Date: 2013-06-24 (Mon, 24 Jun 2013) Changed paths: M Changes M DBI.pm Log Message: --- Clarify bind_col TYPE attribute is sticky Commit: 07cf2f247bdbfd3d59627136e80b213016ab9117 https://github.com/perl5-dbi/dbi/commit/07cf2f247bdbfd3d59627136e80b213016ab9117 Author: Ville Skyttä ville.sky...@iki.fi Date: 2013-06-24 (Mon, 24 Jun 2013) Changed paths: M Changes M DBI.xs M DBIXS.h M INSTALL M Old/TODO_gofer.txt M dbiproxy.PL M devel/README M lib/DBD/DBM.pm M lib/DBD/File.pm M lib/DBD/Gofer.pm M lib/DBD/Gofer/Transport/Base.pm M lib/DBD/Multiplex.pm M lib/DBD/NullP.pm M lib/DBD/Proxy.pm M lib/DBI/DBD.pm M lib/DBI/DBD/SqlEngine.pm M lib/DBI/FAQ.pm M lib/DBI/Gofer/Execute.pm M lib/DBI/ProxyServer.pm M t/01basics.t M t/03handle.t M t/06attrs.t M t/30subclass.t M t/85gofer.t M t/lib.pl Log Message: --- Spelling fixes. Signed-off-by: H.Merijn Brand - Tux h.m.br...@xs4all.nl Commit: 196df56912145879e791e7c10ca087ae788c7587 https://github.com/perl5-dbi/dbi/commit/196df56912145879e791e7c10ca087ae788c7587 Author: H.Merijn Brand - Tux h.m.br...@xs4all.nl Date: 2013-06-24 (Mon, 24 Jun 2013) Changed paths: M Changes Log Message: --- Give Ville the credits for his patch As I used git-am, I could not include this change in the previous commit, unless I modified the patch to include this change :) Commit: 9bfd87b78a62d39165d3e1b7d7d8fa9115229156 https://github.com/perl5-dbi/dbi/commit/9bfd87b78a62d39165d3e1b7d7d8fa9115229156 Author: H.Merijn Brand - Tux h.m.br...@xs4all.nl Date: 2013-06-24 (Mon, 24 Jun 2013) Changed paths: M DBI.pm Log Message: --- one more typo Commit: 481a197712ea22a76ec4060addc59849264fcf49 https://github.com/perl5-dbi/dbi/commit/481a197712ea22a76ec4060addc59849264fcf49 Author: Jens Rehsack s...@netbsd.org Date: 2013-06-24 (Mon, 24 Jun 2013) Changed paths: M Changes M lib/DBI/SQL/Nano.pm Log Message: --- Fix
[perl5-dbi/dbi] d31c83: Tweak Changes description of DBI::SQL::Nano_::Stat...
Branch: refs/heads/master Home: https://github.com/perl5-dbi/dbi Commit: d31c839373eb3137b51f8d481f94c2a3232c9515 https://github.com/perl5-dbi/dbi/commit/d31c839373eb3137b51f8d481f94c2a3232c9515 Author: Tim Bunce tim.bu...@pobox.com Date: 2013-06-24 (Mon, 24 Jun 2013) Changed paths: M Changes Log Message: --- Tweak Changes description of DBI::SQL::Nano_::Statement fix
[perl5-dbi/dbi] f2a2df: Fix handling 0 different from
Branch: refs/heads/master Home: https://github.com/perl5-dbi/dbi Commit: f2a2df0d62405a7e5d58d9a83edacd5acaef82e0 https://github.com/perl5-dbi/dbi/commit/f2a2df0d62405a7e5d58d9a83edacd5acaef82e0 Author: Jens Rehsack s...@netbsd.org Date: 2013-06-24 (Mon, 24 Jun 2013) Changed paths: M Changes M lib/DBI/SQL/Nano.pm Log Message: --- Fix handling 0 different from Handle strings evaluating to a false value correct when simply expecting data in DBI::SQL::Nano_::Statement part approval
[perl5-dbi/dbi] 39ec18: Fixed reference to $sth in selectall_arrayref docs...
Branch: refs/heads/master Home: https://github.com/perl5-dbi/dbi Commit: 39ec181582c4e613df041a723a2db7df8023d6b3 https://github.com/perl5-dbi/dbi/commit/39ec181582c4e613df041a723a2db7df8023d6b3 Author: Tim Bunce tim.bu...@pobox.com Date: 2013-06-24 (Mon, 24 Jun 2013) Changed paths: M Changes M DBI.pm Log Message: --- Fixed reference to $sth in selectall_arrayref docs RT#84873
[perl5-dbi/DBI-Test] cf02ee: add .travis.yml
Branch: refs/heads/master Home: https://github.com/perl5-dbi/DBI-Test Commit: cf02ee2832a1ad800e4a135e36e1b5bb67d2 https://github.com/perl5-dbi/DBI-Test/commit/cf02ee2832a1ad800e4a135e36e1b5bb67d2 Author: Tim Bunce tim.bu...@pobox.com Date: 2013-06-23 (Sun, 23 Jun 2013) Changed paths: A .travis.yml Log Message: --- add .travis.yml
[perl5-dbi/DBI-Test] fcf834: add travis status image and link to README
Branch: refs/heads/master Home: https://github.com/perl5-dbi/DBI-Test Commit: fcf8343a0e9f291da7ea6c5d0d8527adb6b8137f https://github.com/perl5-dbi/DBI-Test/commit/fcf8343a0e9f291da7ea6c5d0d8527adb6b8137f Author: Tim Bunce tim.bu...@pobox.com Date: 2013-06-23 (Sun, 23 Jun 2013) Changed paths: M README.md Log Message: --- add travis status image and link to README