GIS Database

Thanks. I will hover over that again.
When i read down your post, it seems that u tried to post the p079.apr Ranches theme and the JohnWayneDatabase, but its not attached.
Any how i will follow the explanation and get post back any progress.
 
Hi there SKEA - I haven't attached the p079.apr as it really wouldn't necessarily be relevant it has several other themes that wouldn't reference correctly on your machine...

As for the ranches and JohnWayneDatabase - examples that don't exist!!!

Closest I've been to being a cowboy was going camping and eating beans from a can with a knife
 
Last edited:
Lightwave. i am missing something here. I have a shapefile with a table with fields(Ad_id,Division, Ward_Name). So i create a table in an access db with fields(Ad_id,Division,ward_Name),insert some data and do the ODBC link , then try to join. What happens is that it appends the fields of the access table with the contents to the right of the dbf or rather the theme table!! I need it to Update the fields having the related ID with the data.
 
Right this is a step forward...

The shape file does not need to have the fields Division and ward in it as the ODBC link does not populate these fields ... what the ODBC link simply does is add/appends the access table fields that you have connected onto the table of the theme to one side of the theme attribute information...

Perfectly reasonable to expect the ODBC to populate these fields but doesn't work like that it appends one table to the other based on the key field

Important points are
The table within ArcView which you are linking the SQL connection to is the table of Ad_ids attributes

To join two tables - open both tables within ArcView table view highlight the two columns you wish to join and then go to join. One table will be joined to the other based on the one to one relationship which in your case should be Ad_Id(theme table) to Ad_ID (ODBC SQL connect)

an example

In the datbase you have a table with 3 records
each record has the following Ad_ID / Division and Ward
1 , Division1, Ward1
2 , Division2, Ward2
3 , Division3, Ward3

Your polygon theme shape file has four records in it with the following attribute field Ad_ID
1
2
3
4

Now when you join them together you should get a table that has
Ad_ID (theme), Ad_ID (ODBC), Division, Ward
1,1,Division1,Ward1
2,2,Division2,Ward2
3,3,Division3,Ward3
4

Note how the 4 has no information after it - this is because there is no information in the database. If you wanted to update the information for this record in your theme you would need to in put information to the database

eg
4,Final Division, Final Ward

The next time you go into your theme you should see that the ODBC pulls in the information and if you were to interrogate the joined attribute table you should now see

Ad_ID (theme), Ad_ID (ODBC), Division, Ward
1,1,Division1,Ward1
2,2,Division2,Ward2
3,3,Division3,Ward3
4,4,Final Division, Final Ward

Now if there were many more polygons than Dbase information let's say 10

and your ID field within the database showed records with say 2 6 8 and 10 in it then you might end up with
1
2,2,Division1,Ward1,
3
4
5
6,6,Division2,Ward2
7
8,8,Division3,Ward3
9
10,10,Division4,Ward4

when you viewed the Joined attribute table.

If you are desperate you can move the attribute information from the database to a shape file - by doing create shape file on the selected joined table the new shape file will be the classic shape file with information embedded within the shape file.
The problem with this you will no longer be able to access that information from a database...

Hence by creating an ODBC link and joining two tables every time you open access it will import information from access and update all the information and link to the polygons as you have defined within the joined attribute table...
 
Last edited:
Thanks a million, i got you. So the themes table doesnt need to have fields that are in the access table except the unique field.
Good but Damnit! what if i get a shapefile from someone and definately has dbf with many field attributes/records, how can i be able to copy all that and the fields in an access table without swearing!
 
Ok. I think the best is to export it as a text or dbf which one can open with excel then import it into access.

Thanks a Trillion. cant wait to get into the Hood. I will try to do it in .NET
 
Last edited:
No worries SKEA would be very interested in the .NET code if you get it working that way will save us doing exactly the same thing!!!
 

Users who are viewing this thread

Back
Top Bottom