|
sql
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
List all files and autogrowth optionCan I get a list of all files a database comprise of and whether the
autogrowth option for the file is turned on or off Output should be DbName FileName Autogrowth_on_off ABC c:\abc.mdf on ABC d:\abc1.ndf off ABC d:\abc2.ndf on ABC e:\abc_log.ldf on EXEC sp_helpfile
or SELECT * FROM master.dbo.sysaltfiles -- David Portas SQL Server MVP -- Hi,
Execute the below stored procedure. sp_helpdb <DBNAME> Thanks Hari SQL Server MVP Show quoteHide quote "Hassan" <fatima***@hotmail.com> wrote in message news:OUO3JoTZFHA.2996@TK2MSFTNGP10.phx.gbl... > Can I get a list of all files a database comprise of and whether the > autogrowth option for the file is turned on or off > > Output should be > > DbName FileName Autogrowth_on_off > ABC c:\abc.mdf on > ABC d:\abc1.ndf off > ABC d:\abc2.ndf on > ABC e:\abc_log.ldf on > > > > Guys, none of those options tell me if autogrowth is on or off
Show quoteHide quote "Hari Prasad" <hari_prasa***@hotmail.com> wrote in message news:%23MXBnFUZFHA.2884@tk2msftngp13.phx.gbl... > Hi, > > Execute the below stored procedure. > > sp_helpdb <DBNAME> > > > Thanks > Hari > SQL Server MVP > > "Hassan" <fatima***@hotmail.com> wrote in message > news:OUO3JoTZFHA.2996@TK2MSFTNGP10.phx.gbl... > > Can I get a list of all files a database comprise of and whether the > > autogrowth option for the file is turned on or off > > > > Output should be > > > > DbName FileName Autogrowth_on_off > > ABC c:\abc.mdf on > > ABC d:\abc1.ndf off > > ABC d:\abc2.ndf on > > ABC e:\abc_log.ldf on > > > > > > > > > > I believe the MAXSIZE columnin the sysaltfiles that David pointed you to
determines if Autogrow is on or not. Another function you might be interested in for various pieces of information related to the db is DATABASEPROPERTYEX. -- Show quoteHide quoteAndrew J. Kelly SQL MVP "Hassan" <fatima***@hotmail.com> wrote in message news:ehW9vlYaFHA.3144@TK2MSFTNGP14.phx.gbl... > Guys, none of those options tell me if autogrowth is on or off > > > "Hari Prasad" <hari_prasa***@hotmail.com> wrote in message > news:%23MXBnFUZFHA.2884@tk2msftngp13.phx.gbl... >> Hi, >> >> Execute the below stored procedure. >> >> sp_helpdb <DBNAME> >> >> >> Thanks >> Hari >> SQL Server MVP >> >> "Hassan" <fatima***@hotmail.com> wrote in message >> news:OUO3JoTZFHA.2996@TK2MSFTNGP10.phx.gbl... >> > Can I get a list of all files a database comprise of and whether the >> > autogrowth option for the file is turned on or off >> > >> > Output should be >> > >> > DbName FileName Autogrowth_on_off >> > ABC c:\abc.mdf on >> > ABC d:\abc1.ndf off >> > ABC d:\abc2.ndf on >> > ABC e:\abc_log.ldf on >> > >> > >> > >> > >> >> > > its the growth column in sysaltfiles. A zero indicates no autogrowth. I
could not find any databasepropertyex property to find this out for me Show quoteHide quote "Andrew J. Kelly" <sqlmvpnooospam@shadhawk.com> wrote in message news:OcOOJMdaFHA.2884@tk2msftngp13.phx.gbl... > I believe the MAXSIZE columnin the sysaltfiles that David pointed you to > determines if Autogrow is on or not. Another function you might be > interested in for various pieces of information related to the db is > DATABASEPROPERTYEX. > > -- > Andrew J. Kelly SQL MVP > > > "Hassan" <fatima***@hotmail.com> wrote in message > news:ehW9vlYaFHA.3144@TK2MSFTNGP14.phx.gbl... > > Guys, none of those options tell me if autogrowth is on or off > > > > > > "Hari Prasad" <hari_prasa***@hotmail.com> wrote in message > > news:%23MXBnFUZFHA.2884@tk2msftngp13.phx.gbl... > >> Hi, > >> > >> Execute the below stored procedure. > >> > >> sp_helpdb <DBNAME> > >> > >> > >> Thanks > >> Hari > >> SQL Server MVP > >> > >> "Hassan" <fatima***@hotmail.com> wrote in message > >> news:OUO3JoTZFHA.2996@TK2MSFTNGP10.phx.gbl... > >> > Can I get a list of all files a database comprise of and whether the > >> > autogrowth option for the file is turned on or off > >> > > >> > Output should be > >> > > >> > DbName FileName Autogrowth_on_off > >> > ABC c:\abc.mdf on > >> > ABC d:\abc1.ndf off > >> > ABC d:\abc2.ndf on > >> > ABC e:\abc_log.ldf on > >> > > >> > > >> > > >> > > >> > >> > > > > > > The DatabaseEx properties was for future references.
-- Show quoteHide quoteAndrew J. Kelly SQL MVP "Hassan" <fatima***@hotmail.com> wrote in message news:eCkMZglaFHA.3132@TK2MSFTNGP09.phx.gbl... > its the growth column in sysaltfiles. A zero indicates no autogrowth. I > could not find any databasepropertyex property to find this out for me > > "Andrew J. Kelly" <sqlmvpnooospam@shadhawk.com> wrote in message > news:OcOOJMdaFHA.2884@tk2msftngp13.phx.gbl... >> I believe the MAXSIZE columnin the sysaltfiles that David pointed you to >> determines if Autogrow is on or not. Another function you might be >> interested in for various pieces of information related to the db is >> DATABASEPROPERTYEX. >> >> -- >> Andrew J. Kelly SQL MVP >> >> >> "Hassan" <fatima***@hotmail.com> wrote in message >> news:ehW9vlYaFHA.3144@TK2MSFTNGP14.phx.gbl... >> > Guys, none of those options tell me if autogrowth is on or off >> > >> > >> > "Hari Prasad" <hari_prasa***@hotmail.com> wrote in message >> > news:%23MXBnFUZFHA.2884@tk2msftngp13.phx.gbl... >> >> Hi, >> >> >> >> Execute the below stored procedure. >> >> >> >> sp_helpdb <DBNAME> >> >> >> >> >> >> Thanks >> >> Hari >> >> SQL Server MVP >> >> >> >> "Hassan" <fatima***@hotmail.com> wrote in message >> >> news:OUO3JoTZFHA.2996@TK2MSFTNGP10.phx.gbl... >> >> > Can I get a list of all files a database comprise of and whether the >> >> > autogrowth option for the file is turned on or off >> >> > >> >> > Output should be >> >> > >> >> > DbName FileName Autogrowth_on_off >> >> > ABC c:\abc.mdf on >> >> > ABC d:\abc1.ndf off >> >> > ABC d:\abc2.ndf on >> >> > ABC e:\abc_log.ldf on >> >> > >> >> > >> >> > >> >> > >> >> >> >> >> > >> > >> >> > >
Database market share 2004
sql data corruption Format Files - Bcp Images and PDF's in the same DB or in another DB? Problem with different version of SQL Server validate data of target database against source database structure..How? Application respond slowly Error 22042: xp_setsqlsecurity() raises error -2147024893 LINKED SERVER Problems Time out error |
|||||||||||||||||||||||