Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Mapping fields programmatically?

Status
Not open for further replies.

BernieBeattie

Programmer
Nov 29, 2002
22
0
0
GB
We have 2 different datasources for our reports - SQL Server and VFP8. Dates on the SQL server side are datetime and on the VFP side they are dates. For business reasons for the moment we cannot change the VFP structures to datetimes.
My question is this, when we open a Crystal report based on SQL data and change the data source to point to VFP via ODBC, a prompt comes up asking us to map the datetime fields to the date fields. Once that is done the report carries on happily. Can that be done programmatically to avoid getting the prompts? We are already changing the datasource programmatically but no prompt to map fields appears and the dates all show as blank at the moment.

Thanks for any help,
Bernie
 
I don't think so.

Consider creating a query or cursor in VFP to base the report on and create a datetime in the query so that the structures are the same as the SQL Server database.

Once you get the VFP tables sorted out, you can then point directly at the table if you prefer.

-k
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top