Import DDL database structure to Access database (1 Viewer)

The_Doc_Man

Immoderate Moderator
Staff member
Local time
Today, 04:10
Joined
Feb 28, 2001
Messages
26,996
Can't address the question about CONSTRAINT syntax. My "big boy" database experience is with ORACLE and a non-Access FE. Have to leave that to others more familiar with SQL Server and its variants.

However, the fact that you have the same two fields participating in two indexes might confuse Access more than just a little bit. It would probably matter considerably as to which index name you used for the relationships. Access really doesn't like it when you give it mixed signals - like, "Which index to use?" when there are two apparently identical options.

I would bet that if you switched from InvoicesCon to PrimaryKey in that little "Indexes" display, the only thing that would change would be that "Primary" would be YES for that one.

It is your database and of course you are more familiar with it - but people's names are usually very poor choices as PKs. Given you have only First name and Last name, my dad and I couldn't be in your database together. Because we have the same names except he was "Senior" and I was "Junior."
 

Minty

AWF VIP
Local time
Today, 09:10
Joined
Jul 26, 2013
Messages
10,353
I couldn't enforce referential integrity in the UI for a join of that type, which means you probably can't code it either.
 

jaryszek

Registered User.
Local time
Today, 02:10
Joined
Aug 25, 2016
Messages
756
Minty,

you mean cant code by VBA?

Jacek
 

Minty

AWF VIP
Local time
Today, 09:10
Joined
Jul 26, 2013
Messages
10,353
I couldn't make it work, but it is not something I have ever tried to do in Access.

I wonder if the amount of effort you are expending on this far outweighs any potential benefit.
 

jaryszek

Registered User.
Local time
Today, 02:10
Joined
Aug 25, 2016
Messages
756
We will see i hope it will be useful.
Maybe i will try to do this via VBA...

Jacek
 

CodeByJim

New member
Local time
Today, 03:10
Joined
Apr 18, 2015
Messages
9
You sent an example of your data in an excel spreadsheet. Why don't you simply export the data to an Access table. Edit your tables and then set up Access relationships.
 

CodeByJim

New member
Local time
Today, 03:10
Joined
Apr 18, 2015
Messages
9
If you have CSV data in a text file, you can read each string into VBA and use the Split function to create a one dimension array which can be saved into a pre-designed table. I use CSV strings a lot when handling data movement into and out of my tables.
 

Pat Hartman

Super Moderator
Staff member
Local time
Today, 05:10
Joined
Feb 19, 2002
Messages
42,970
This whole thread is a total mess and probably why the OP abandoned it. Getting a definition of the problem was impossible. We still have no idea why anyone would type DDL to import into Access rather than simply build the schema using the GUI.

I use DDL in various ways. Mostly I use it for apps that I have installed remotely where I need the local DBA to modify the schema so I send him DDL to do it but I use SQL Server to actually generate the DDL Access doesn't have a tool to generate it the way SQL Server does so I built one but it is quite rudimentary.
 

Users who are viewing this thread

Top Bottom