Skip to content

Instantly share code, notes, and snippets.

@edipretoro
Created June 6, 2012 12:06
Show Gist options
  • Save edipretoro/2881502 to your computer and use it in GitHub Desktop.
Save edipretoro/2881502 to your computer and use it in GitHub Desktop.
#!/usr/bin/env perl
use strict;
use warnings;
use feature 'say';
use Data::Dump;
use FindBin;
use lib "$FindBin::Bin/../lib";
use LawDB::Schema;
my $database = shift;
my $schema = LawDB::Schema->connect( 'dbi:SQLite:dbname=' . $database );
my @result = $schema->resultset('ArticleIdx')->search( { content => { match => 'secteur' } } );
foreach my $result (@result) {
say $result->numid->lawid->title;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment