view release on metacpan or search on metacpan
/*
* TT_DEFAULT_BIND_TYPE_VALUE is now set to 0, which means that
* DBD::TimesTen will call SQLDescribeParam to find out what type of
* binding should be set. If SQLDescribeParam fails, then the bind type
* will be set to SQL_VARCHAR as a backup.
*
*/
#define TT_DEFAULT_BIND_TYPE_VALUE 0
/* BLOB's are not supported in TimesTen, do not enable this. */
view all matches for this distribution
view release on metacpan or search on metacpan
av_top_index|5.017009|5.003007|p
av_top_index_skip_len_mg|5.025010||Viu
av_undef|5.003007|5.003007|
av_unshift|5.003007|5.003007|
ax|5.003007|5.003007|
backup_one_GCB|5.025003||Viu
backup_one_LB|5.023007||Viu
backup_one_SB|5.021009||Viu
backup_one_WB|5.021009||Viu
bad_type_gv|5.019002||Viu
bad_type_pv|5.016000||Viu
BADVERSION|5.011004||Viu
BASEOP|5.003007||Viu
BhkDISABLE|5.013003||xV
view all matches for this distribution
view release on metacpan or search on metacpan
MANIFEST.SKIP view on Meta::CPAN
\bBuild.bat$
\bBuild.COM$
\bBUILD.COM$
\bbuild.com$
# Avoid temp and backup files.
~$
\.old$
\#$
\b\.#
\.bak$
view all matches for this distribution
view release on metacpan or search on metacpan
cci-src/config/ltmain.sh view on Meta::CPAN
if test "$thread_safe" = yes && test -n "$thread_safe_flag_spec"; then
eval flag=\"$thread_safe_flag_spec\"
linker_flags="$linker_flags $flag"
fi
# Make a backup of the uninstalled library when relinking
if test "$mode" = relink; then
$run eval '(cd $output_objdir && $rm ${realname}U && $mv $realname ${realname}U)' || exit $?
fi
# Do each of the archive commands.
view all matches for this distribution
view release on metacpan or search on metacpan
{
my ($macenv, $macenvval) = split('=',$ARGV[0]);;
$ENV{$macenv} = $macenvval;
shift @ARGV;
}
open(OLDSTDERR, ">&STDERR") || die "Failed to backup STDERR: $!";
open(FILE, ">myld.stderr") || die "Failed to create myld.stderr: $!";
open(STDERR, ">&FILE") || die "Failed to redirect STDERR: $!";
my $retval = system(@ARGV);
open(STDERR, ">&OLDSTDERR");
view all matches for this distribution
view release on metacpan or search on metacpan
{
my ($macenv, $macenvval) = split('=',$ARGV[0]);;
$ENV{$macenv} = $macenvval;
shift @ARGV;
}
open(OLDSTDERR, ">&STDERR") || die "Failed to backup STDERR: $!";
open(FILE, ">myld.stderr") || die "Failed to create myld.stderr: $!";
open(STDERR, ">&FILE") || die "Failed to redirect STDERR: $!";
my $retval = system(@ARGV);
open(STDERR, ">&OLDSTDERR");
view all matches for this distribution
view release on metacpan or search on metacpan
lib/DBI/DBD.pm view on Meta::CPAN
Of special importance for B<DBI> drivers is the I<postamble> method from
the L<ExtUtils::MM_Unix> man page.
For Emacs users, I recommend the I<libscan> method, which removes
Emacs backup files (file names which end with a tilde '~') from lists of
files.
Now an example, I use the word C<Driver> wherever you should insert
your driver's name:
view all matches for this distribution
view release on metacpan or search on metacpan
examples/backup-db.pl view on Meta::CPAN
#!/usr/bin/perl
#
# Name:
# backup-db.pl.
use strict;
use warnings;
use DBI;
use DBIx::Admin::BackupRestore;
# -----------------------------------------------
my($file_name) = shift || die("Usage: perl backup-db.pl backup-db.xml");
my($driver) = ($^O eq 'MSWin32') ? 'mysql' : 'Pg';
my($dsn) = ($driver eq 'mysql') ? 'dbi:mysql:db_name' : 'dbi:Pg:dbname=db_name';
my($username) = ($driver eq 'mysql') ? 'root' : 'postgres';
my($password) = ($driver eq 'mysql') ? 'pass' : '';
my($dbh) = DBI -> connect
examples/backup-db.pl view on Meta::CPAN
skip_tables =>
[ # For exporting from MS Access only.
qw/msysaces msysaccessobjects msyscolumns msysimexcolumns msysimexspecs msysindexes msysmacros msysmodules2 msysmodules msysobjects msysqueries msysrelationships/
],
verbose => 1,
) -> backup('db_name');
close OUT;
view all matches for this distribution
view release on metacpan or search on metacpan
MANIFEST.SKIP view on Meta::CPAN
\bBuild.bat$
# Avoid Devel::Cover generated files
\bcover_db
# Avoid temp and backup files.
~$
\#$
\.#
\.bak$
\.old$
view all matches for this distribution
view release on metacpan or search on metacpan
MANIFEST.SKIP view on Meta::CPAN
\bBuild.bat$
# Avoid Devel::Cover generated files
\bcover_db
# Avoid temp and backup files.
~$
\#$
\.#
\.bak$
\.old$
view all matches for this distribution
view release on metacpan or search on metacpan
MANIFEST.SKIP view on Meta::CPAN
\bBuild.bat$
# Avoid Devel::Cover generated files
\bcover_db
# Avoid temp and backup files.
~$
\#$
\.#
\.bak$
\.old$
view all matches for this distribution
view release on metacpan or search on metacpan
doc/bk_faq.html view on Meta::CPAN
<p>
2. When a translation set is incomplete the missing
language descriptions will be filled in with the
'native' language. English may be a good choice for
the 'native' backup display language because many people
can understand it.
<p>
<div align="right">
view all matches for this distribution
view release on metacpan or search on metacpan
t/DBIx-Brev.t view on Meta::CPAN
my $mswin = $^O eq 'MSWin32';
my $fd = $mswin?q{\\}:q{/};
my ($home) = grep defined && -d, map $ENV{$_}, $mswin? qw(USERPROFILE HOME):'HOME';
skip "was not able to find HOME directory", 1 unless defined($home);
my $home_config = $home.$fd.q{dbi.conf};
my $backup = -f $home_config?grep(!-f,map $home_config.substr(rand(),1),1..10):();
my %config2;
skip "was not able to create/replace $home_config",1 unless eval {
move($home_config,$backup) if $backup;
move($config_file,$home_config);
%config2 = DBIx::Brev::load_config();
unlink $home_config;
move($backup,$home_config) if $backup;
1;
};
is_deeply(\%config2,\%config,q{load config from HOME directory});
};
unlink $config_file;
view all matches for this distribution
view release on metacpan or search on metacpan
- initial release to CPAN
0.05 2016-09-01T10:02:43Z
- removed to specific backup method
0.04 2016-09-01T09:47:35Z
- removed warnings
- deployment handler args fixed
- deployment handler args per new()
0.02 2016-09-01T09:04:28Z
- mysqldump backup WIP
0.01 2016-09-01T08:55:07Z
- original version
view all matches for this distribution
view release on metacpan or search on metacpan
lib/DBIx/Class/DeploymentHandler/Dad.pm view on Meta::CPAN
has schema => (
is => 'ro',
required => 1,
);
has backup_directory => (
isa => 'Str',
is => 'ro',
predicate => 'has_backup_directory',
);
has to_version => (
is => 'ro',
isa => 'Str',
lib/DBIx/Class/DeploymentHandler/Dad.pm view on Meta::CPAN
}
});
log_warn { 'no version to run downgrade' } unless $ran_once;
}
sub backup {
my $self = shift;
log_info { 'backing up' };
$self->schema->storage->backup($self->backup_directory)
}
__PACKAGE__->meta->make_immutable;
1;
lib/DBIx/Class/DeploymentHandler/Dad.pm view on Meta::CPAN
=head2 schema_version
The version that the schema is currently at. Defaults to
C<< $self->schema->schema_version >>.
=head2 backup_directory
The directory where backups are stored
=head2 to_version
The version (defaults to schema's version) to migrate the database to
lib/DBIx/Class/DeploymentHandler/Dad.pm view on Meta::CPAN
Downgrades the database one step at a time till L</previous_version_set>
returns C<undef>. Each downgrade step will delete a C<version> from the
version storage.
=head2 backup
$dh->backup
Simply calls backup on the C<< $schema->storage >>, passing in
C<< $self->backup_directory >> as an argument. Please test yourself before
assuming it will work.
=head1 AUTHOR
Arthur Axel "fREW" Schmidt <frioux+cpan@gmail.com>
view all matches for this distribution
view release on metacpan or search on metacpan
lib/DBIx/Class/Fixtures.pm view on Meta::CPAN
=head2 external
In some cases your database information might be keys to values in some sort of
external storage. The classic example is you are using L<DBIx::Class::InflateColumn::FS>
to store blob information on the filesystem. In this case you may wish the ability
to backup your external storage in the same way your database data. The L</external>
attribute lets you specify a handler for this type of issue. For example:
{
"sets": [{
"class": "Photo",
lib/DBIx/Class/Fixtures.pm view on Meta::CPAN
}]
}
This would use L<DBIx::Class::Fixtures::External::File> to read from a directory
where the path to a file is specified by the C<file> field of the C<Photo> source.
We use the uninflated value of the field so you need to completely handle backup
and restore. For the common case we provide L<DBIx::Class::Fixtures::External::File>
and you can create your own custom handlers by placing a '+' in the namespace:
"class": "+MyApp::Schema::SomeExternalStorage",
lib/DBIx/Class/Fixtures.pm view on Meta::CPAN
$class = "DBIx::Class::Fixtures::External::$class" unless $plus;
eval "use $class";
$ds{external}->{$field} =
encode_base64( $class
->backup($key => $args),'');
}
}
# mess with dates if specified
if ($set->{datetime_relative}) {
view all matches for this distribution
view release on metacpan or search on metacpan
MANIFEST.SKIP view on Meta::CPAN
\bBuild$
\b_build
Build.PL
Build.bat
# Avoid temp and backup files.
~$
\.gz$
\.old$
\.bak$
\.swp$
view all matches for this distribution
view release on metacpan or search on metacpan
MANIFEST.SKIP view on Meta::CPAN
# Avoid Module::Build generated and utility files.
\bBuild$
\b_build/
# Avoid temp and backup files.
~$
\.old$
\#$
\b\.#
\.bak$
view all matches for this distribution
view release on metacpan or search on metacpan
lib/DBIx/Class/Migration.pm view on Meta::CPAN
Run down files to bring the database down to the previous version from what is
installed to the database
=head2 drop_tables
Drops all the tables in the connected database with no backup or recovery. For
real! (Make sure you are not connected to Prod, for example).
=head2 delete_table_rows
Does a C<delete> on each table in the database, which clears out all your data
view all matches for this distribution
view release on metacpan or search on metacpan
lib/DBIx/Class/Storage/DBI/mysql/backup.pm view on Meta::CPAN
=encoding utf8
=head1 NAME
DBIx::Class::Storage::DBI::mysql::backup
=head1 SYNOPSIS
package MyApp::Schema;
use base qw/DBIx::Class::Schema/;
lib/DBIx/Class/Storage/DBI/mysql/backup.pm view on Meta::CPAN
our $VERSION = 0.001;
__PACKAGE__->load_classes(qw/CD Book DVD/);
__PACKAGE__->load_components(qw/
Schema::Versioned
Storage::DBI::mysql::backup
/);
=head1 DESCRIPTION
Adds C<backup> method to L<DBIx::Class::Storage::DBI::mysql>.
This plugin enables L<DBIx::Class::Schema::Versioned/backup> when using MySQL.
=head1 FUNCTIONS
=cut
package DBIx::Class::Storage::DBI::mysql::backup;
use strict;
use warnings;
use DBIx::Class::Storage::DBI;
lib/DBIx/Class/Storage/DBI/mysql/backup.pm view on Meta::CPAN
use vars qw( $VERSION );
$VERSION = '0.04';
=head2 backup ( $to_dir )
writes SQL file as L</backup_filename> to $to_dir. returns SQL filename.
=cut
sub _backup {
my ( $self, $dir ) = @_;
mkpath([$dir]) unless -d $dir;
my $filename = $self->backup_filename;
my $fh = Symbol::gensym();
open $fh, ">$dir/$filename";
print $fh $self->dump;
close $fh;
$filename
}
=head2 backup_filename
returns filename of backup I<$DB_NAME-YYYYMMDD-hhmmss.sql>
=cut
sub _backup_filename {
my $self = shift;
my $dsn = $self->_dbi_connect_info->[0];
my $dbname = $1 if($dsn =~ /^dbi:mysql:database=([^;]+)/i);
unless($dbname) {
$dbname = $1 if($dsn =~ /^dbi:mysql:dbname=([^;]+)/i);
lib/DBIx/Class/Storage/DBI/mysql/backup.pm view on Meta::CPAN
=cut
sub _dump {
my $self = shift;
my $mb = MySQL::Backup->new_from_DBH( $self->dbh ,{'USE_REPLACE' => 1, 'SHOW_TABLE_NAMES' => 1});
$mb->create_structure() . $mb->data_backup()
}
*DBIx::Class::Storage::DBI::dump = \&_dump;
*DBIx::Class::Storage::DBI::backup = \&_backup;
*DBIx::Class::Storage::DBI::backup_filename = \&_backup_filename;
1;
__END__
view all matches for this distribution
view release on metacpan or search on metacpan
MANIFEST.SKIP view on Meta::CPAN
\bBuild$
\b_build
Build.PL
Build.bat
# Avoid temp and backup files.
~$
\.gz$
\.old$
\.bak$
\.swp$
view all matches for this distribution
view release on metacpan or search on metacpan
lib/DBIx/Class/Schema/Versioned.pm view on Meta::CPAN
use Scalar::Util 'weaken';
use namespace::clean;
__PACKAGE__->mk_classdata('_filedata');
__PACKAGE__->mk_classdata('upgrade_directory');
__PACKAGE__->mk_classdata('backup_directory');
__PACKAGE__->mk_classdata('do_backup');
__PACKAGE__->mk_classdata('do_diff_on_init');
=head1 METHODS
=head2 upgrade_directory
Use this to set the directory your upgrade files are stored in.
=head2 backup_directory
Use this to set the directory you want your backups stored in (note that backups
are disabled by default).
=cut
=head2 install
lib/DBIx/Class/Schema/Versioned.pm view on Meta::CPAN
return;
}
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));
$self->backup() if($self->do_backup);
$self->txn_do(sub { $self->do_upgrade() });
# set row in dbix_class_schema_versions table
$self->_set_db_version({version => $target_version});
}
lib/DBIx/Class/Schema/Versioned.pm view on Meta::CPAN
Returns the current schema class' $VERSION
=cut
=head2 backup
This is an overwritable method which is called just before the upgrade, to
allow you to make a backup of the database. Per default this method attempts
to call C<< $self->storage->backup >>, to run the standard backup on each
database type.
This method should return the name of the backup file, if appropriate..
This method is disabled by default. Set $schema->do_backup(1) to enable it.
=cut
sub backup
{
my ($self) = @_;
## Make each ::DBI::Foo do this
$self->storage->backup($self->backup_directory());
}
=head2 connection
Overloaded method. This checks the DBIC schema version against the DB version and
view all matches for this distribution
view release on metacpan or search on metacpan
t/common-sqlserver.t view on Meta::CPAN
|assembly_files
|assembly_modules
|assembly_references
|assembly_types
|asymmetric_keys
|backup_devices
|certificates
|change_tracking_databases
|change_tracking_tables
|check_constraints
|column_type_usages
t/common-sqlserver.t view on Meta::CPAN
|dm_fts_index_population
|dm_fts_memory_buffers
|dm_fts_memory_pools
|dm_fts_outstanding_batches
|dm_fts_population_ranges
|dm_io_backup_tapes
|dm_io_cluster_shared_drives
|dm_io_pending_io_requests
|dm_os_buffer_descriptors
|dm_os_child_instances
|dm_os_cluster_nodes
view all matches for this distribution
view release on metacpan or search on metacpan
MANIFEST.SKIP view on Meta::CPAN
tags
CVS
mkmanifest
MANIFEST.SKIP
RELEASE_CHECKLIST
.*\.bak # backup files
.*\.gz # tarballs
\..* # dotfiles
view all matches for this distribution
view release on metacpan or search on metacpan
lib/DBIx/HA.pm view on Meta::CPAN
allow the passing of a reference to any configuration hash to I<initialize>.
See a sample %DATABASE::conf in the SYNOPSIS section. That section creates
an entry for the 'test' HA database handle, which is comprised of 3 physical
database handles (prod1, prod2, prod3). 'prod1' is the main handle, while the
other 2 are backup handles.
Add other HA database handles by creating more entries in I<%DATABASE::conf>.
=item connect ( $dbname )
lib/DBIx/HA.pm view on Meta::CPAN
=item load-balancing across read-only servers
It is very simple to load-balance across read-only database servers.
Simply randomize or reorder the 'db_stack' entry in your database
configuration on a per-process basis. This will make each process have
its own set of primary and backup servers.
Obviously you should never do that on a read-write environment with hot
spares as you will be writing to the hot spares without writing to the
primary server. Consider C<DBD::Multiplex> for such an application.
=item manually setting the active datasource without downtime
view all matches for this distribution
view release on metacpan or search on metacpan
MANIFEST.SKIP view on Meta::CPAN
\bBuild.bat$
# Avoid Devel::Cover generated files
\bcover_db
# Avoid temp and backup files.
~$
\#$
\.#
\.bak$
\.old$
view all matches for this distribution
view release on metacpan or search on metacpan
MANIFEST.SKIP view on Meta::CPAN
\bBuild.bat$
# Avoid Devel::Cover generated files
\bcover_db
# Avoid temp and backup files.
~$
\#$
\.#
\.bak$
\.old$
view all matches for this distribution
view release on metacpan or search on metacpan
MANIFEST.SKIP view on Meta::CPAN
\bBuild.bat$
# Avoid Devel::Cover generated files
\bcover_db
# Avoid temp and backup files.
~$
\#$
\.#
\.bak$
\.old$
view all matches for this distribution
view release on metacpan or search on metacpan
MANIFEST.SKIP view on Meta::CPAN
\bBuild.bat$
# Avoid Devel::Cover generated files
\bcover_db
# Avoid temp and backup files.
~$
\#$
\.#
\.bak$
\.old$
view all matches for this distribution
view release on metacpan or search on metacpan
MANIFEST.SKIP view on Meta::CPAN
CPAN.SKIP
t/000_standard__*
Debian_CPANTS.txt
nytprof.out
# Temp, old, emacs, vim, backup files.
~$
\.old$
\.swp$
\.tar$
\.tar\.gz$
view all matches for this distribution