On Wednesday, October 01, 2003 11:38 AM Itsna wrote:

>
> Saya pemula di Delphi, mau nanya bagaimana cara mencari tahu typedata dan
> size field pada suatu tabel.
>

tahu mah adanya di pasar...  :-))

tapi kalau mencari tau tipe data suatu tabel bisa dilakukan dengan
memanfaatkan TField.DataType (TFieldType), lihat helpnya untuk keterangan
tentang TFieldType, TField.DataType, contoh implementasinya begini
kira-kira:

var
    i : integer;
begin
    MyQuery.Active := False;
    MyQuery.SQL.Text := 'select * from employee where ''aa'' = ''zz''; ';
    MyQuery.Open;
    if MyQuery.FieldCount > 0 then
        for i := 0 to MyQuery.FieldCount -1 then
        begin
            if (MyQuery.Fields[i].DataType = ftString) then
                ShowMessage('Field '+Fields[i].FieldName + ' is a string');
        end;
end;

Salam,

-Jaimy
--
...Maybe you should think about how much time other people spend
on developing components to make you idiots which wouldn't even
be able to make a simple window showing up, possible to call
yourselves "PROGRAMMERS"...
      -- James (20-09-2003 21:36)


------------------------ Yahoo! Groups Sponsor ---------------------~-->
Upgrade to 128-Bit SSL Security!
http://us.click.yahoo.com/p7cEmB/s7qGAA/yigFAA/i7folB/TM
---------------------------------------------------------------------~->

Berlangganan: [EMAIL PROTECTED]
Stop Berlangganan: [EMAIL PROTECTED]
Keluhan Milis(Unbouncing,spam,dll): [EMAIL PROTECTED] 

Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/ 


Kirim email ke