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 bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Field of an unknown type error

Status
Not open for further replies.

pingLeeQuan

Programmer
Jul 3, 2002
45
US
I am stuck in trying to update/insert a record in to the table.

I have 4 visual components on my form
Tquery, tUpdateQuery, Ttable, and tDataSet.

The "DataSet" in the property option of the DataSet is set to the query's name

The "UpdateObject" of the query is set to the tUpdateSql

The Tquery is "Select * from table1"
The TUpdateSQL has an insert statement similar to the following one

Insert into tInternalHeader
(
TenantID,
PaymentDate,
AmountPaid,
UnitID,
ProjectID,
InternalHeaderID_FK,
BatchNumber,
ProcessDateTime,
ExportedDateTime,
ExportedUserID_FK,
ProcessUserID_FK,
RecordIndicator
)
values
(
:cusID,
:paymentDate,
:AmountPaid,
:UnitID,
:projectID,
:InternalHeaderID_FK,
:BatchNumber,
:NOW(),
:ExportedUserID_FK,
:processedUserID_FK,
:'D'
)


And when I do the following in my main form:

qryExternalHeader->Open();
qryExternalHeader->FieldByName("UserName")->AsString = "zozozozozozo";;
qryExternalHeader->Post();


I get
"Field UserName is of an unknown type. Process stopped".

I tried to substitute other fields but I still get the same message.

I checked the fields on MYSQL and on BDE. They all exist and of type VARCHAR, and BINARYVARCHAR....



Can anyone please help me with this one?

Thanks lots in advance...
--quan
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top