Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much
 
PerlMonks  

Re: Create a MS Access database programmatically in perl

by jsprat (Curate)
on Jul 07, 2003 at 18:20 UTC ( [id://272059]=note: print w/replies, xml ) Need Help??


in reply to Create a MS Access database programmatically in perl

First of all, create an account! If you post regularly, you'll find all kinds of benefits. Most of all, it's fun.

As for your question, you aren't importing the constants from the ADOX library - ADO doesn't know what you mean by 'adVarWChar'. Use the object browser (ships with ActiveState, usually installed at \Perl\html\OLE-Browser\Browser.html) to find out which version of ADOX is installed, and add it to the use Win32::OLE::Const line. It should look something like this:

use Win32::OLE::Const 'Microsoft ADO Ext. 2.5 for DDL and Security';

Also, check the Win32::OLE docs for Win32::OLE->LastError() and the warn option (specifically Win32::OLE->Option(warn => 2); #or 3 or 4). This should help your debugging.

By the way, once the database is created, it would probably be much more straightforward to use the DBI to create your tables. Good luck...

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://272059]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (5)
As of 2024-04-19 10:15 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found