It is not a good idea to shrink the data file. The data file growth is dependent on the growth option you set on it. If you set it to say 10% and the initial size is 100G it will grow to 110G when all the 100G of space is all use up. It will then grow to 121G next and so on.
The fact that it is taking up 121G on the disc does not mean that it needs all that space presently and if you shrink it, it may go down to 111G but it will grow again shortly after to allocate more space. Performance will degrade for each growth so you should set the growth percentage to a figure that will not cause the database to grow very often.
The reason why you can shrink the log file to zero is because after transactions are committed the logs are not needed except in the case where you need to restore the database from the them. This is not the case with the data file. You cannot shrink the data beyond the actual size being used.
Varden Morris
J. Wray & Nephew Ltd. - Group I.S.
Phone: (876) - 923 - 6141 Ext. 2226
Fax: (876) - 923 - 5372
Cell: (876) - 3833566
Email: [EMAIL PROTECTED]
[EMAIL PROTECTED] wrote:
Hi,
I tried this, but the real problem is the .mdf file. this one increases from 10 Gb to 13 Gb.
the log file has 5 gb, but i have delete it.
so the other problem ist, that on normal use the db.file increases 3-4 Gb per year.
so what strategy is the best way to shrink the .mdf file?
thanks for your help
best regards
sascha
Raul Llorente Peña/OPENSOLUTIONS <[EMAIL PROTECTED]>
Gesendet von: Axapta-Knowledge-Village@yahoogroups.com25.04.2005 18:09
Bitte antworten an
Axapta-Knowledge-Village@yahoogroups.com
AnAxapta-Knowledge-Village@yahoogroups.com Kopie ThemaRe: [Axapta-Knowledge-Village] After Upgrade DB increases over 13 GB
Securely the most of increasing have been on Log file. Backup the BBDD, detach it, delete log file, and then reatach the data file. SQL will create a new, empty, very much smaller log file.
SQL have provided some shrink options, but they are often few effective.
Raúl Llorente Peña
Análisis, Desarrollo e Implementación en
Microsoft Bussiness Solutions-Axapta
OPEN SOLUTIONS
Sharing the knowledge on Axapta.
Yahoo! Groups Links
- To visit your group on the web, go to:
http://groups.yahoo.com/group/Axapta-Knowledge-Village/
- To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
- Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
Sharing the knowledge on Axapta.
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
Sharing the knowledge on Axapta.
Yahoo! Groups Links
http://groups.yahoo.com/group/Axapta-Knowledge-Village/
[EMAIL PROTECTED]