If I'm understanding you correctly (you want to know for a particular
field in your table whether or not every single row is a numeric value or
if one or more of the rows has text in it), the answer is "no", there's no
function or property built into Access.
However, the following function should give you what you want:
Function DIsNumeric(FieldName As String, TableName As String) As Boolean
Dim rsCurr As DAO.Recordset
Dim booNumeric As Boolean
Dim strSQL As String
booNumeric = True
strSQL = "SELECT [" & FieldName & "] FROM [" & TableName & "]"
Set rsCurr = CurrentDb.OpenRecordset(strSQL)
Do While rsCurr.EOF = False
If IsNumeric(rsCurr.Fields(0)) = False Then
booNumeric = False
Exit Do
End If
rsCurr.MoveNext
Loop
rsCurr.Close
Set rsCurr = Nothing
DIsNumeric = booNumeric
End Function
(Note, though, that the IsNumeric function may give results you consider
to be incorrect: it will call strings like "10D4" or "2356E6" numeric)
--
Doug Steele, Microsoft Access MVP
(no e-mails, please!)
a said:
Hi
I have column in query or in a table
Ok
I want to know if this column (all data (rows) value) = text
Or
I want to know if this column (all data (rows) value) = Number
Is there any function or properties in access 2003 can do that
Data already in the data base table or query