On 09/11/2012 07:56 PM, Derek W wrote:
> I'm trying to create a Catalyst project connecting to an existing MS
> SQL Server database. I got the correct connection string and it's
> authenticating, but it's not finding any tables. Anyone have an idea
> of what I might be missing?
> I substituted the real ip address, database name, username, and
> password but you get the idea.
> This is the command I run:
> script\qa_utility_create.pl model DB DBIC::Schema QA_Utility::Schema
> create=static "db_schema=DatabaseName" "dbi:ODBC:Driver={sql
> server};Server=,1433;Database=DatabaseName" username password
> When I run this, I get the below error:
> exists "C:\strawberry\perl\site\bin\QA_Utility\lib\QA_Utility\Model"
> exists "C:\strawberry\perl\site\bin\QA_Utility\t"
> Dumping manual schema for QA_Utility::Schema to directory
> C:\strawberry\perl\site\bin\QA_Utility\lib ...
> Schema dump completed.
> WARNING: No tables found, did you forget to specify db_schema?
> exists "C:\strawberry\perl\site\bin\QA_Utility\lib\QA_Utility\Model\DB.pm"
> I wanted to quickly get a simple CRUD web app for our existing
> database using perl but I'm starting to think this is not going to
> happen with SQL server?


I think this is more a DBIx::Class issue than a Catalyst issue. I am not
really sure about what I am going write next, but give it a try. Maybe
it helps:

If I understand the docs right, specifying a db_schema is only required
if you want to load more than one schema. See

Since you specified a database in your dsn, did you try to omit the
db_schema option?

I never worked with ODBC, and I am not working on windows. But:
If I try to do the same as you on Unix, using dbi:mysql, I get the same
error as you. If I omit the quotes around "db_schema=..." everything
works fine. I get my schema files created correctly, even if I do not
specify the databasename within the dsn.

So, try to use
instead of

As I stated before, this answer is more guessing than knowledge. If it
doesn't help, you will have to wait for a more "professional" answer.

If nobody can help you here, you might try asking the DBIC list, or via
irc in #dbix-class.

I hope I could help. And if my answer is rubbish, just ignore me :)

Cheers, lukast

List: Catalyst@lists.scsys.co.uk
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/
Dev site: http://dev.catalyst.perl.org/

Reply via email to