how can I accomplish:
select * from table where column_value is int
I know I can probably inner join to the system tables and type tables b
Here if you want to implement your custom function
CREATE Function dbo.IsInteger(@Value VARCHAR(18))
RETURNS BIT
AS
BEGIN
RETURN ISNULL(
(SELECT CASE WHEN CHARINDEX('.', @Value) > 0 THEN
CASE WHEN CONVERT(int, PARSENAME(@Value, 1)) <> 0 THEN 0 ELSE 1 END
ELSE 1
END
WHERE ISNUMERIC(@Value + 'e0') = 1), 0)
END
ISNUMERIC returns 1 when the input expression evaluates to a valid integer, floating point number, money or decimal type; otherwise it returns 0. A return value of 1 guarantees that expression can be converted to one of these numeric types.