Tou can say myTable.FieldByName('field1').DataType or
myTable.Fields[0].DataType
if you need to perform a certain action according to the data type, you
can use a case statement and do your job
Hope this helps
Vahan Yoghoudjian
"ridwan haris" <[EMAIL PROTECTED]>
Sent by: [email protected]
05/09/2006 11:06 AM
Please respond to delphi-en
To: [email protected]
cc:
Subject: [delphi-en] get column data types from a sql server database
Hai..
Sorry if this was a crossposting, i'ts very urgent..
any idea how to get column data types from a sql server database?
i've found an article on
BDN http://bdn.borland.com/article/0,1410,29708,00.html<http://bdn.borland.com/article/0,1410,29708,00.html%29it>
it seems that
article answer my questions,but that is are delphi.net article and i
dont use it.
To get column name from a table i use this routine:
DM.ADOConnection.GetFieldNames(TablesTree.Selected.Text,ListTables);
but how about to get field data types(string,integer,datetime,varchar
etc)?any idea?
Best regards,
[Non-text portions of this message have been removed]
-----------------------------------------------------
Home page: http://groups.yahoo.com/group/delphi-en/
To unsubscribe: [EMAIL PROTECTED]
Yahoo! Groups Links
______________________________________________________________________
This email has been scanned by the MessageLabs Email Security System.
This is a service contracted by Schneider Electric to avoid Spam.
______________________________________________________________________
[Non-text portions of this message have been removed]
-----------------------------------------------------
Home page: http://groups.yahoo.com/group/delphi-en/
To unsubscribe: [EMAIL PROTECTED]
SPONSORED LINKS
| C programming language | Computer programming languages | Java programming language |
| The c programming language | C programming language | Concept of programming language |
YAHOO! GROUPS LINKS
- Visit your group "delphi-en" on the web.
- To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
- Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.

