/[Frey]/branches/mojo/lib/A3C/Schema.pm
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Contents of /branches/mojo/lib/A3C/Schema.pm

Parent Directory Parent Directory | Revision Log Revision Log


Revision 234 - (show annotations)
Sat Nov 1 15:26:48 2008 UTC (15 years, 5 months ago) by dpavlin
File size: 352 byte(s)
 r3087@llin (orig r233):  dpavlin | 2008-11-01 16:20:43 +0100
 fix encoding

1 package A3C::Schema;
2
3 use Fey::ORM::Schema;
4 use Frey::Schema;
5
6 my $dsn = 'dbi:Pg:dbname=a3c';
7 #$dsn = 'dbi:SQLite:dbname=./var/a3c.sqlite';
8
9 my ( $schema, $source ) = Frey::Schema->schema_source( $dsn );
10
11 has_schema $schema;
12
13 __PACKAGE__->DBIManager()->add_source($source);
14
15 $source->dbh->do( qq{ set client_encoding = 'utf-8' } ) if $dsn =~ /Pg/;
16
17 1;

  ViewVC Help
Powered by ViewVC 1.1.26