Need to change the 2 to a 4 if you have 4K pages!
-------------------------------------------------------------------------
Cheryl Kendricks
Internet:cherylk@prod1.jcdc.doleta.gov OR cherylk@gwysmtp.jcdc.doleta.gov
DTSI, Inc. Voice: 1-800-598-5008 Fax: 512-393-7296
Database Administrator - DOL Job Corps San Marcos, Texas
------------------------------------------------------------------------
On Wed, 12 Jun 1996, Guy Bradet wrote:
} Guerry A. Semones wrote:
} >
} > I am looking for the SQL statement that would tell
} > me how full an Informix database is (that is, approaching
} > capacity).
} >
} > I know how to do this in Oracle, but, of course, that
} > does not translate.
} >
} > Much thanks in advance.
} >
} > Guerry
} > gsemones@mo.net
}
} You didn't mention which version of Informix you're using but
} the following query should work assuming you have Online 6.0
} or higher.
}
} SELECT sp.name dbspace,
} sum (chk.nfree) * 2 free_kbytes,
} sum (chk.chksize) * 2 total_kbytes
} FROM sysmaster:sysdbspaces sp,
} sysmaster:syschunks chk
} WHERE chk.dbsnum = sp.dbsnum
} GROUP BY 1;
}
} It'll give the amount of free Kbytes per db/blob space.
}
} Of course, you could use "onstat -d" but that's not
} an SQL statement.
}
} Guy
}