W
Wes from Scottsdale
I'm working with SQL Server in an Access project. My query needs to retrieve
the details of a contract. My query runs fine but none of the foreign key
value are populated.
My query is:
strSQL = "SELECT [AuthFormDate], [ApprovedDate], [ExecutionDate],
[CouncilDate]" _
& ", [ExpirationDate], [ClosedDate], [ContractAmt], [Notes],
[ContractID], " _
& "[FirmID], [RenewalID], [InHouseCounsel], [DepartmentPayingID], " _
& "[ClientDepartmentID], [MatterID], [OriginalOnFile],
[AuthFormOnFile], " _
& "[SelectionMemoOnFile], [ConType], [OrigDoc], [AuthFormDoc],
[SelMemoDoc]" _
& " FROM [tContract] WHERE [ContractID] = '" & lstSearch.Column(0) & "'"
The foreign key values are FirmID, InHouseCounsel, DepartmentPayingID,
ClientDepartmentID and MatterID. They are all Not Null of Int data type.
Again, the row is retrieving everything except for the Foriegn Key values,
which are brought back blank. I've also tried the query using an * instead
of column names, with the same result. If I run the same query in SQL Server
Manager, all data exists so the problem only comes up in Access.
Any ideas?
the details of a contract. My query runs fine but none of the foreign key
value are populated.
My query is:
strSQL = "SELECT [AuthFormDate], [ApprovedDate], [ExecutionDate],
[CouncilDate]" _
& ", [ExpirationDate], [ClosedDate], [ContractAmt], [Notes],
[ContractID], " _
& "[FirmID], [RenewalID], [InHouseCounsel], [DepartmentPayingID], " _
& "[ClientDepartmentID], [MatterID], [OriginalOnFile],
[AuthFormOnFile], " _
& "[SelectionMemoOnFile], [ConType], [OrigDoc], [AuthFormDoc],
[SelMemoDoc]" _
& " FROM [tContract] WHERE [ContractID] = '" & lstSearch.Column(0) & "'"
The foreign key values are FirmID, InHouseCounsel, DepartmentPayingID,
ClientDepartmentID and MatterID. They are all Not Null of Int data type.
Again, the row is retrieving everything except for the Foriegn Key values,
which are brought back blank. I've also tried the query using an * instead
of column names, with the same result. If I run the same query in SQL Server
Manager, all data exists so the problem only comes up in Access.
Any ideas?