Hi
I was wondering what the best approach to my problem would be. I have two tables table1 and table2. I need to create a third table (say table3) which has fields from both table1 and table2 and also a field that is calculated based on a function. I am using VB .NET and a MS access database.
I understand that one way of doing this would be to create a query that creates a cartesian product of table1 and table2. The SQL statment I use within VB .NET is
Dim qsetCartstr = "SELECT grid.gridid, nevents.neventid, distance([glat], [glon], [nlat], [nlon]) AS ndistance, nevents.nweight FROM grid, nevents"
where distance(...) is the function that is coded within the VB .NET form.
When I execute the code, I get an error saying 'function distance not defined'. If this because the function is not defined within Access? Any help will be greatly appreciated.
Thanks,
Chetan
I was wondering what the best approach to my problem would be. I have two tables table1 and table2. I need to create a third table (say table3) which has fields from both table1 and table2 and also a field that is calculated based on a function. I am using VB .NET and a MS access database.
I understand that one way of doing this would be to create a query that creates a cartesian product of table1 and table2. The SQL statment I use within VB .NET is
Dim qsetCartstr = "SELECT grid.gridid, nevents.neventid, distance([glat], [glon], [nlat], [nlon]) AS ndistance, nevents.nweight FROM grid, nevents"
where distance(...) is the function that is coded within the VB .NET form.
When I execute the code, I get an error saying 'function distance not defined'. If this because the function is not defined within Access? Any help will be greatly appreciated.
Thanks,
Chetan