home *** CD-ROM | disk | FTP | other *** search
- QUESTION:
-
- I dropped a TOraDB and a TAOraSQL components onto a form. I set the properties,
- and TAOraSQL.SQL property to 'select * from real_actl'.
- This table has many fields and it has a field, name TBLA.
- So I tried to open the dataset. Than I got a message: 'Field 'TBLA' not found!'.
- I missed something?
-
- ANSWER:
-
- If you use TAOraSQL for SQL queries your must define all fields manually.
- If your table has two fields: TBLA(integer) and TBBB(string) your can do next:
-
- AOraSQL.SetSQL('select * from real_actl');
- AOraSQL1.AddField('TBLA',ftoInteger,0,True);
- AOraSQL1.AddField('TBBB',ftoString,50,True);
- AOraSQL.Open;
-
- The other way to call LoadFields method before Open.
-
- AOraSQL.SetSQL('select * from real_actl');
- AOraSQL.LoadFields;
- AOraSQL.Open;
-
- If you use TOraSQL no any additional action need:
-
- OraSQL.SQL.Text:='select * from real_actl';
- OraSQL.Open;
-
-