Merge space within database.

Hi,
Our company is moving a production database from one storage subsystem to another, more efficient. Objects within the database are highly fragmanted. The data wihin the database uses about 1TB. If somebody performed a full export and an import to another database, the same data would need less than 600GB. There is an idea to recreate and rebuild all objects during the mentioned maintenance.
Full imp/exp is not an option as it would cause a long database outage what is not acceptable. My idea is to copy the whole database to the new storage, create a new tablesace and perioically (weekly) move several objects to it (using ALTER TABLE... MOVE and ALTER INDEX REUBUILT... TABLESPACE...). When all objects are moved, drop the old tablespace and realese space. Is there any other more convenient way to merge space within database?
The database uses a lot of small, 2GB files. Wouldn't it be better to create a smaller number of bigger files? Would it influence the performance of the database?
Thank you in advance,
Tim

Thank you very much for the reply!
The version that is currently used is 10.1.0.5 (EE).
To be honest mainly indexes are fragmented. We don't suffer from table's data chaining or migration.
I have made a full database export recently (using data pump) and imported it into an other database. In the source database indexes utilize about 500GB whereas in the target only about 300GB. The indexes haven't been rebuilt for ...years. According to many publications, index defragmentation vastly improves overall system performance, especially for queries that use index scans.
As I know during checkpoint the headers of all data files are updated with current SCN. I thought that decreasing the number of data files would decrease the number of writes. That's why I asked about performance differences.
In what way do you consider ASM as the perfect tool for migration?
Regards,
Tim

Similar Messages

  • Spaces within access db field name

    I am trying to use data which was extracted to a excel file
    then imported into a access database.
    During the import access database used the first roll to be
    the field name and some names has space within.
    When I try to access those field inside CF and i will get a
    error message since the CF won's understand any field names with
    space inside the name.
    Is there a work around? Since change the field name each time
    will take lots of time beacuse the db will be exported every day.
    Thanks

    Is there a work around? Since change the field name each time
    will take
    lots of time because the db will be exported every day.
    Thanks
    Yup, two of 'em even.
    The first is in the SQL language, you can alias the columns
    with the AS
    command. This one is probably preferred by most developers.
    SELECT ['Column With Spaces'] AS NoSpaces
    FROM aTable
    Secondly you can use the array notation ability of ColdFusion
    to
    reference variables with bad names. For queries that would be
    queryName[columnName][row].
    <cfoutput query="aBadQuery">
    #aBadQuery["Column With Spaces"][currentRow]#
    </cfoutput>

  • How to merge pages within the same document?

    Can I merge pages within the same pdf document? I have two large maps, an east and west, can I put the two pages together to make one map?

    How different are the layouts?
    You can vary the left and right pages:
    +Inspector > Layout > Section > Configuration > Left and right pages are different+
    But the position of the headers, footers and margins will be the same.
    You could make different designs and capture those but each would have to be its own section. This sort of thing works better in Layout mode, where every page is a different section, but you won't get automatic text flow nor TOC, footnotes etc.
    Pages rapidly gets very clumsy when you try to do detail layout to this extent.
    Peter

  • Spaces in database column names

    Hi folks!
    Does anyone know if there is some way to reference Micosoft Access
    database columns that contain spaces using Forte and ODBC?
    I know it's like trying to use a jet plane to go down to the high street, but
    we want to extend a (large) in-house system with a good Forte front-end.
    I am aware that there are utilities available to rename entities within
    Access databases, but if there is an easy way to do this in Forte we'd
    prefer to go that way.
    Cheers,
    Duncan Kinnear,
    McCarthy and Associates, Email: [email protected]
    PO Box 764, McLean Towers, Phone: +64 6 834 3360
    Shakespeare Road, Napier, New Zealand. Fax: +64 6 834 3369
    Providing Integrated Software to the Meat Processing Industry for over 10 years
    To unsubscribe, email '[email protected]' with
    'unsubscribe forte-users' as the body of the message.
    Searchable thread archive <URL:http://pinehurst.sageit.com/listarchive/>

    Duncan,
    Just put the column in double quotes.
    Example:
    sql SELECT
    ,ipool.id
    ,asgn."Assignment Date"
    ,asgn.router
    ,asgn."Order Number"
    FROM assigned_ips addr
    ,assignments asgn
    WHERE
    addr.id = asgn.Assigned_IP
    AND asgn.master_ip = mpool.id
    AND mpool.ip_pool = ipool.id
    AND ipool.ncc = ncc.id
    ORDER BY addr.id
    on session accessDbSession
    At 09:31 AM 6/17/99 +1200, you wrote:
    Hi folks!
    Does anyone know if there is some way to reference Micosoft Access
    database columns that contain spaces using Forte and ODBC?
    I know it's like trying to use a jet plane to go down to the high street,but
    we want to extend a (large) in-house system with a good Forte front-end.
    I am aware that there are utilities available to rename entities within
    Access databases, but if there is an easy way to do this in Forte we'd
    prefer to go that way.
    Cheers,
    Duncan Kinnear,
    McCarthy and Associates, Email: [email protected]
    PO Box 764, McLean Towers, Phone: +64 6 834 3360
    Shakespeare Road, Napier, New Zealand. Fax: +64 6 834 3369
    Providing Integrated Software to the Meat Processing Industry for over 10years
    To unsubscribe, email '[email protected]' with
    'unsubscribe forte-users' as the body of the message.
    Searchable thread archive <URL:http://pinehurst.sageit.com/listarchive/>
    To unsubscribe, email '[email protected]' with
    'unsubscribe forte-users' as the body of the message.
    Searchable thread archive <URL:http://pinehurst.sageit.com/listarchive/>

  • Merge a remote database table using dblink

    We have a merge statement running in source database which is merging to a table in remote database using db link. The remote table is partitonoed (interval) table.Source db is 10g and target is 11g.
    this merge statement is failing with error saying,
    error occurred at recursive SQL level 1
    00942: table or view does not exist
    ORA-02063: preceding 2 lines from ORCL_ONL_LIVE
    If anyone have any idea about this error, please share with us

    user585870 wrote:
    We have a merge statement running in source database which is merging to a table in remote database using db link. The remote table is partitonoed (interval) table.Source db is 10g and target is 11g.
    this merge statement is failing with error saying,
    error occurred at recursive SQL level 1
    00942: table or view does not exist
    ORA-02063: preceding 2 lines from ORCL_ONL_LIVE
    If anyone have any idea about this error, please share with us
    How do you explain the ORA-00942 error first ? Are you able to select that table ? Can we see the merge statement ?
    Nicolas.

  • Error executing a stored procedure from SSIS using the MERGE statement between databases

    Good morning,
    I'm trying to execute from SSIS a stored procedure that compares the content of two tables on different databases in the same server and updates one of them. To perform this action, I've created a stored procedure in the destination database and I'm
    comparing the data between tables with the MERGE statement. When I execute the procedure on the destination database the error that I obtain is:
    "Msg 916, Level 14, State 1, Procedure RefreshDestinationTable, Line 13
    The server principal "XXXX" is not able to access the database "XXXX" under the current security context."
    Some things to take in account:
    1. I've created a temporary table on the same destination database to check if the problem was on the MERGE statement and it works fine.
    2. I've created the procedure with the option "WITH EXECUTE AS DBO".
    I've read that it can be a problem of permissions but I don't know if I'm executing the procedure from SSIS to which user/login I should give permissions and which.
    Could you give me some tip to continue investigating how to solve the problem?
    Thank you,
    Virgilio

    Read Erland's article http://www.sommarskog.se/grantperm.html
    Best Regards,Uri Dimant SQL Server MVP,
    http://sqlblog.com/blogs/uri_dimant/
    MS SQL optimization: MS SQL Development and Optimization
    MS SQL Consulting:
    Large scale of database and data cleansing
    Remote DBA Services:
    Improves MS SQL Database Performance
    SQL Server Integration Services:
    Business Intelligence

  • Calling class via an Applet, Java stored within database

    I don't know if this is the right place to post, but. I'm trying to create an Applet that references a JAVA class stored in the database. My code looks something like this:
    <applet code="Hello.class" codebase="http://www.somesite.com/pls/dad/" width="150" height="30"></applet>
    Hello.class is stored within a 10g database. The codebase is a vitural url that connects to a schema within the database. Can this be done?? and How??

    Look at HttpCallout.java in the following code sample
    http://www.oracle.com/technology/sample_code/tech/java/jsp/samples/jwcache/Readme.html
    Kuassi

  • A table "CMP3$111448" appears in DB replicating a big table and spending a lot of space in database

    We have a web application which manages digital documents,
    its main table is named "DOC_ADJUNTO", this table has a column "DOCUMENTO" of type BLOB and some other columns.
    Also there is an Oracle Text Index for the BLOB column of the table "DOC_ADJUNTO"; its definition as follow:
        CREATE INDEX IDX_DOC_ADJUNTO_DOCUMENTO ON DOC_ADJUNTO (DOCUMENTO) INDEXTYPE IS CTXSYS.CONTEXT PARAMETERS('Sync (on commit)') NOPARALLEL;
    Just a week ago, a new table "CMP3$111448" appeared in database.
    The table "CMP3$111448" replicates the structure of table "DOC_ADJUNTO" and its Oracle Text Index, so it is spending a lot of space for the tablespace and backups for whole database.
    One difference between the two tables is that "DOC_ADJUNTO" table has 136.782 rows, and "CMP3$111448" only has 107.380 rows.
    I have the following questions about this fact:
        a) Why the table "CMP3$111448" appeared?
        b) Can I just drop the table "CMP3$111448" to reclaim back the space? ¿Will not materialize a negative effect?
        c) If I drop the table "CMP3$111448", will a similar table appear again? If yes, how can I avoid it happens?
    I really would appreciate a little of feedback before I take an action to get back the space.   
    Regards   

    I've got a similar mystery table that appears structurally identical to a table with some LOB columns.  Same owner.  The shadow/copy/mystery table has far fewer rows.
    CMP3$160860 has  12193 rows, the "real" table, fatal_error_log, has  109589 rows.
    I also would like to drop this table to reclaim space ...  but I wonder if it is somehow being used by Oracle in some transient shadow kind of way.  Maybe it is left over from an incomplete shutdown/startup where this table wasn't completely flushed or something.
    We're also on 11.2.0.4 RDBMS.  Running on Sun Solaris.  Not using Toplink nor any java features (also of course Oracle is probably using some java in the db.)
    If you learn anything about it, please share!
    Thanks.

  • Image Files - Within Database, or Use FileStream?

    I have millions of photos tied to transactions.  There are several photos tied to one transaction.  My app pages and displays hundreds of transactions with the photos.  I would also like a user to be able to download all of the transaction
    information including the photo to a spreadsheet.  Currently, the images are stored within the database - is this the best way to go?
    Considerations -
    I am currently using transactional replication to replicate this SQL database to another location and the database for the images is 25GBs and will continue to grow.
    The images do not change but daily hundreds more transaction and images are added to the system.
    I know there is a newer method - FileStream.  Should I be using this method and FileTable? I know I can't use Database mirroring with this option (is that a concern) and am currently using transactional based replication.
    What backup method should I use with the recommended database deign - replication or ?

    Consider FileTable for your application.
    BOL: "The FileTable feature brings support for the Windows file namespace and compatibility with Windows applications to the file data stored in SQL Server. FileTable lets an application integrate its storage and data management components, and provides
    integrated SQL Server services - including full-text search and semantic search - over unstructured data and metadata.
    In other words, you can store files and documents in special tables in SQL Server called FileTables, but access them from Windows applications as if they were stored in the file system, without making any changes to your client applications."
    LINK: http://msdn.microsoft.com/en-us/library/ff929144.aspx
    Kalman Toth Database & OLAP Architect
    SQL Server 2014 Database Design
    New Book / Kindle: Beginner Database Design & SQL Programming Using Microsoft SQL Server 2014

  • Fragmentation/Defragmentation of space in Database

    Hi,
    Oracle DB version : 10.2.0.5.0
    OS version HP-UX B.11.31 U ia64
    DB size : 2TB
    We have the above configuration for one of our oracle database. One of our DBA acts like he is only the person on this earth who is managing the process of fragmentation removal from the tablespaces in order to improve the performance and wastage of the space. He performs that task at weekends and takes one-off day extra. I am not sure how the fragmentation removal improves the performance and deallocates the space.
    Is it compulsory to perform the rebuild process weekly in order to remove fragmented space from tablespaces?
    Do we have any other method to automatically re-organize objects occupying waste space?
    Why the reuild of indexes using separate tablespace improves performance? is there any specifi reason for it?
    Please help understand the process.
    Thanks,
    Imran Khan

    imran khan wrote:
    Hi,
    Oracle DB version : 10.2.0.5.0
    OS version HP-UX B.11.31 U ia64
    DB size : 2TB
    We have the above configuration for one of our oracle database. One of our DBA acts like he is only the person on this earth who is managing the process of fragmentation removal from the tablespaces in order to improve the performance and wastage of the space. He performs that task at weekends and takes one-off day extra. I am not sure how the fragmentation removal improves the performance and deallocates the space.
    What types of queries you run mostly on your database system is it DML of Select queries? Rebuild might or might not increase in performance for Select query.
    Is it compulsory to perform the rebuild process weekly in order to remove fragmented space from tablespaces?
    Not compulsory
    Do we have any other method to automatically re-organize objects occupying waste space? dbms_redefinition
    http://docs.oracle.com/cd/E11882_01/server.112/e25494/tables007.htm#ADMIN11668
    >
    Why the reuild of indexes using separate tablespace improves performance? is there any specifi reason for it?Its a myth but not actually proven in most cases. Request you to visit Richard Foote blog about this.
    >
    Please help understand the process.

  • Data Merge questions within CS 5.5...Please help

    Basically, we utilize this now with our calendar designs for schools which includes school events on certain days via the data merge along with building each calendar design from a 2 page spread with data merge. Now, the issue we are running into is....we send the school a proof of their calendar before we send it to print. At this time, they have an opportunity to add/delete/edit any events they want on our online portal for them in which we pull the info into our database to create the updated CSV file. Is there a way that once the first CSV file is merged to have it as a link or something similar? By this, I mean...it would be nice that when we re-generate the CSV file at proof time with the updated events that those will simply be updated in our indesign file by updating the link or something similar? We want to avoid re-building the calendar from scratch (2 page spread) at this point. Although for 70%+ rebuilding is not an issue, the other 30% are custom calendar that we have several edits to the 2 page template to start with. We dont want to have to do this custom work again or possible miss those custom changes when it is recreated. Any suggestions or help would be appreciated. Thanks!

    The good news is that you won't need to re-build anything. That said, I see 2 ways to update your file.
    Save the original as a template (before it's merged) and run the merge again once the CSV has been finalised. That way you always have the template of the first and each time you run the merge you get a new indd file.
    The other is based on the assumption that you added your merge fields into the document and not the master of the original file. If so, you can copy the document page content into the master pages, add the merge fields to the master and use this as a template. When you merge the document this time the CSV becomes a linked file in the resultant file.
    The differences between 1 and 2 is that the link to the CSV file is kept in the merged file in 2. Either way, it's a very easy update for you but you will have to re-apply your custom changes. This should just involve a straight copy/paste though.

  • To know free space in database files

    Hi all,
    how to know free space and used space in individual database files by sql quer or command not from oracle enterprise manager.please can any body tell me query.quick response will higly appreciated.thanks a lot in advance.

    Hi;
    column file_name format a42
    column tablespace_name format a15
    column status format a3 trunc
    column t format 999,999.000 heading "Total MB"
    column a format a4 heading "Aext"
    column p format 990.00 heading "% Free"
    SELECT df.file_name,
    df.tablespace_name,
    df. status,
    (df.bytes/1024000) t,
    (fs.s/df.bytes*100) p,
    decode (ae.y,1,'YES','NO') a
    FROM dba_data_files df,
    (SELECT file_id,SUM(bytes) s
    FROM dba_free_space
    GROUP BY file_id) fs,
    (SELECT file#, 1 y
    FROM sys.filext$
    GROUP BY file#) ae
    WHERE df.file_id = fs.file_id
    AND ae.file#(+) = df.file_id
    ORDER BY df.tablespace_name, df.file_id;
    column file_name clear
    column tablespace_name clear
    column status clear
    column t clear
    column a clear
    column p clear
    ttitle off
    Sample Output:
    FILE_NAME TABLESPACE_NAME STA Total MB % Free Aext
    /usr/ORACLE/u02/data/example01.dbf EXAMPLE AVA 153.600 49.13 YES
    Edited by: emre baransel on Sep 30, 2009 10:11 AM

  • Tsql for database , size , free space or used space in database

    hi,
     i want to know how to find out database size

    use master
    declare @PageSize varchar(10)
    select @PageSize=v.low/1024.0
    from master..spt_values v
    where v.number=1 and v.type='E'
    select name as DatabaseName, convert(float,null) as Size
    into #tem
    From sysdatabases where dbid>4
    declare @SQL varchar (8000)
    set @SQL=''
    while exists (select * from #tem where size is null)
    begin
    select @SQL='update #tem set size=(select round(sum(size)*'+@PageSize+'/1024,0) From '+quotename(databasename)+'.dbo.sysfiles) where databasename='''+databasename+''''
    from #tem
    where size is null
    exec (@SQL)
    end
    select * from #tem order by DatabaseName
    drop table #tem
    The first select statement is to get how many kilobytes a data page has. SQL Server allocates disk space in the unit of data page. Currently each SQL server data page contains 8k bytes. The number of data pages allocated to each database file is recorded
    in the sysfiles system table. With this information on hand the script creates a temporary table #tem and update the temporary table with size information which is gathered by querying the sysfiles table.
    thx benedikt

  • Mail Merge From Within Professional 8

    Hi,
      Is there any function in Professional 8 similar to Word's Mail Merge?  I work for a company that has a need to "stamp" unique copy numbers on certain documents.  Here's what we presently do:
    We have a Word file of a testing procedure (we have a number of different testing procedures), and we receive a request for x number of controlled copies so that the analysts in the labs can conduct testing. An example of the number for the first controlled copy for this year would be: TD125-09-0001 (TD=Testing Document, 125=the main document number (which never changes, we have about 130 of these documents), 09=the year, and 0001=unique controlled copy number.  So we would issue TD125-09-0001, TD125-09-0002, TD125-09-0003, TD125-09-0004 and so on depending on a given request.
    Now the problem:  We are going to be switching to an Electronic Document Management System (EDMS) in which the documents, when printed from within the EDMS system will print with the EDMS Headers and Footers, and therefore cannot be brought outside of the system.
    My workaround was to print out the Testing Document from within EDMS, therefore it will print with all the appropriate Headers and Footers that the system generates upon printing...then scan the document as a PDF to use as a template, and apply the controlled copy numbers to the PDF version.  The only problem is that Acrobat doesn't seem to have functionality similar to Word's Mail Merge....the beauty of which is you choose which "recipients" you would like to merge, and regardless of the length of the document, it will imprint the same number on every page, print another copy with the next sequential number, etc.  I've looked around in the Professional 8 application and the closest I've come is forms, but then you have no functionality to generate sequential copy numbers except to do each one manually.
    Does anyone know of a plug-in or scripting that will mimic the functionality of Mail Merge but from within Adobe?
    Much Appreciation In Advance!,
    Paul

    Hi Rick
    To explain in brief, the main master table (OCRD) is replicated in fields in the audit trail table (ACRD). A few additional fields are available in the ACRD such as Instance which is a numeric incremental number for each update to a master. Instance 1 is of course the Add action when it is created. Therefore you can pull the information of the BP straight from the ACRD table without having to join and using the MAX number of Instance to get the latest "snapshot" of the master. Then there are fields such as update date and time which can be used to determine if any records have been updated in say the last 5 minutes for example.
    Another suggestion would be to add an activity to the BP rather for each letter that must be created, as this will give you history of each letter that was sent. What can work quite nicely will be to change the layout of the activity to be some letter format and then possibly save this to PDF or print to a Document generator printer as a TIFF file and then attach these back to the activity. From the activity you could also fax, email or print the letter.
    The above scenarios are just a suggestion, and I guess a way of trying to impress on you that SAP Business One is still a good choice, despite a few shortcomings. The important thing to remember with SAP Business One is it's flexibility in terms of User Defined Fields, Formatted Searches, SDK, UDO's, DI API, etc. which can in many cases overcome functional gaps. The best advise is to consider how big the gap is and what it will cost to fill it in terms of project time line and cost.
    Hope this helps
    Kind regards
    Peter Juby

  • Is it possible to configure transaction and merge replication one database as a publisher?

    Hi All,
    We have a requirement to configure replication between the servers and its plan is as fallows:
    A------>B -- One way transactional replication ---  Already Configured
    A------> C --Merge Replication (Both ways)--- This is in plan
    1) Our requirement to configure Merge replication is to allow multiple users to access both publisher and subscriber databases. Configuring Merge replication with a combination of Transactional replication is correct or do we end up facing issues?
    2) A to B transactional replication is already configured so if we configure merge replication between A to C will effect existing replication?
    Please let us know if you need any details on this. Thank You.
    Grateful to your time and support. Regards, Shiva

    Hi Sir,
    Thanks for the information. But I have small doubt, "best to use merge all the way" is that mean you recommend to use Merge replication for all the servers.
    A------>B --
    Merge Replication (Both ways) 
    A------> C --Merge Replication (Both ways)
    Please correct me if I am wrong
    Grateful to your time and support. Regards, Shiva

Maybe you are looking for

  • Unknown Publisher

    I have been trying to download itunes and it comes up with an unknown publisher message that will not let me use the program...i have turned off all firewalls and virus protection and it wont do anything...it is really frustraiting for the fact that

  • Set_item_property Internal Code

    Hi Does any one know where is the basic internal programmes written for these standard reusable syntaxs....... like set_item_property Thanks S

  • [ANNOUNCE] JSF RI 1.2_05 RC2 has been released!

    Please see this announcement -> https://javaserverfaces.dev.java.net/servlets/NewsItemView?newsItemID=5363

  • Viewing a file in JEditorPane

    hi, I am new to JEditorPane component. I am using RedHat Linux. I am having a text file which I want to display it in JEditorPane for 'preview' purposes. Is it possible. Or it can display only HTML files. Please make it clear. thanks in advance. bhuv

  • Please give a comment on this program.

    This program is to find a product, size and color. It is abstract program. abstract class Pants{ protected string pro_code; protected int size=0; protected string color; boolean sizeIs(string s) boolean colorIs(string c) boolean buttonFront(string b)