database size in MB in V5
Posted in 2009
Topics: General Discussion
Hi Can anybody tell me how to find out the database size informix v5. the sysmaster query is not working. Regards Deba --001517574662e9b241046bf9c9b7
There is no sysmaster in OnLine 5.xx. What do you mean by 'database size'? Art Art S. Kagel Oninit (www.oninit.com) IIUG Board of Directors (art@iiug.org) Disclaimer: Please keep in mind that my own opinions are my own opinions and do not reflect on my employer, Oninit, the IIUG, nor any other organization with which I am associated either explicitly or implicitly. Neither do those opinions reflect those of other individuals affiliated with any entity with which I am affiliated nor those of the entities themselves. On Wed, Jun 10, 2009 at 3:54 AM, debadatta <mishra.dd@gmail.com> wrote: > Hi > Can anybody tell me how to find out the database size informix v5. > > the sysmaster query is not working. > > Regards > Deba > > --001517574662e9b241046bf9c9b7 > > > > ******************************************************************************* > Forum Note: Use "Reply" to post a response in the discussion forum. > > --001636c5b356e7253a046bfb66e1
Hi
Yes , actually i should have said there is no sysmaster.
I got a query from web
DATABASE sysmaster;
SELECT stn.dbsname db_name,
SUM
( sti.ti_npused *
(
select sh_pagesize from sysshmvals
)/1024/1024
) mb_used,
SUM
(
sti.ti_nptotal *
(
select sh_pagesize from sysshmvals
)/1024/1024
) mb_total
FROM systabnames stn, systabinfo sti, sysdatabases sdb
WHERE stn.partnum = sti.ti_partnum
AND stn.dbsname = sdb.name
GROUP BY 1
ORDER BY 1;
what would be similar query in V5.
I can get the total pages and free pages from onstat -d. But would it
be database size. When i export the data for migration what size
would closer.
Thanks & regards
Deba
On Wed, Jun 10, 2009 at 3:20 PM, Art Kagel <art.kagel@gmail.com> wrote:
> There is no sysmaster in OnLine 5.xx. What do you mean by 'database size'?
>
> Art
>
> Art S. Kagel
> Oninit (www.oninit.com)
> IIUG Board of Directors (art@iiug.org)
>
> Disclaimer: Please keep in mind that my own opinions are my own opinions
> and
> do not reflect on my employer, Oninit, the IIUG, nor any other organization
> with which I am associated either explicitly or implicitly. Neither do
> those opinions reflect those of other individuals affiliated with any
> entity
> with which I am affiliated nor those of the entities themselves.
>
> On Wed, Jun 10, 2009 at 3:54 AM, debadatta <mishra.dd@gmail.com> wrote:
>
> > Hi
> > Can anybody tell me how to find out the database size informix v5.
> >
> > the sysmaster query is not working.
> >
> > Regards
> > Deba
> >
> > --001517574662e9b241046bf9c9b7
> >
> >
> >
> >
>
>
*******************************************************************************
> > Forum Note: Use "Reply" to post a response in the discussion forum.
> >
> >
>
> --001636c5b356e7253a046bfb66e1
>
>
>
>
*******************************************************************************
> Forum Note: Use "Reply" to post a response in the discussion forum.
>
>
--001e680f114403079e046bfd3ed4
The best you can do is to run UPDATE STATISTICS at the database level or on
every table individually to update the system catalog tables then query the
number of pages used from the systables catalog table. The pagesize will be
2K unless you are running on AIX or Windows where the pagesize is 4K.
So the query will be something like:
select tabname, (npused * 2) kb_used
from systables
into temp sizes;
select sum(kb_used) total_kb
from sizes;
Art
Art S. Kagel
Oninit (www.oninit.com)
IIUG Board of Directors (art@iiug.org)
Disclaimer: Please keep in mind that my own opinions are my own opinions and
do not reflect on my employer, Oninit, the IIUG, nor any other organization
with which I am associated either explicitly or implicitly. Neither do
those opinions reflect those of other individuals affiliated with any entity
with which I am affiliated nor those of the entities themselves.
On Wed, Jun 10, 2009 at 8:02 AM, debadatta <mishra.dd@gmail.com> wrote:
> Hi
> Yes , actually i should have said there is no sysmaster.
> I got a query from web
>
> DATABASE sysmaster;>
> SELECT stn.dbsname db_name,
>
> SUM
>
> ( sti.ti_npused *
>
> (
>
> select sh_pagesize from sysshmvals>
> )/1024/1024
>
> ) mb_used,
>
> SUM
>
> (
>
> sti.ti_nptotal *
>
> (
>
> select sh_pagesize from sysshmvals>
> )/1024/1024
>
> ) mb_total
>
> FROM systabnames stn, systabinfo sti, sysdatabases sdb
>
> WHERE stn.partnum = sti.ti_partnum
>
> AND stn.dbsname = sdb.name
>
> GROUP BY 1
>
> ORDER BY 1;
>
> what would be similar query in V5.
>
> I can get the total pages and free pages from onstat -d. But would it
> be database size. When i export the data for migration what size
> would closer.
>
> Thanks & regards
>
> Deba
>
> On Wed, Jun 10, 2009 at 3:20 PM, Art Kagel <art.kagel@gmail.com> wrote:
>
> > There is no sysmaster in OnLine 5.xx. What do you mean by 'database
> size'?
> >
> > Art
> >
> > Art S. Kagel
> > Oninit (www.oninit.com)
> > IIUG Board of Directors (art@iiug.org)
> >
> > Disclaimer: Please keep in mind that my own opinions are my own opinions
> > and
> > do not reflect on my employer, Oninit, the IIUG, nor any other
> organization
> > with which I am associated either explicitly or implicitly. Neither do
> > those opinions reflect those of other individuals affiliated with any
> > entity
> > with which I am affiliated nor those of the entities themselves.
> >
> > On Wed, Jun 10, 2009 at 3:54 AM, debadatta <mishra.dd@gmail.com> wrote:
> >
> > > Hi
> > > Can anybody tell me how to find out the database size informix v5.
> > >
> > > the sysmaster query is not working.
> > >
> > > Regards
> > > Deba
> > >
> > > --001517574662e9b241046bf9c9b7
> > >
> > >
> > >
> > >
> >
> >
>
>
*******************************************************************************
> > > Forum Note: Use "Reply" to post a response in the discussion forum.
> > >
> > >
> >
> > --001636c5b356e7253a046bfb66e1
> >
> >
> >
> >
>
>
*******************************************************************************
> > Forum Note: Use "Reply" to post a response in the discussion forum.
> >
> >
>
> --001e680f114403079e046bfd3ed4
>
>
>
>
*******************************************************************************
> Forum Note: Use "Reply" to post a response in the discussion forum.
>
>
--001636c5a57b1345ff046bfea1a5