Is it better to store the image in the database or to use BFile

Hi all,
I've a doubt regarding the handling of the image. For example i've the images of the persons amounting to 50,000(the number will be increased in future). So i just want to know which is the better menthod. is it better to store all the images in the database or to store in local OS and use Bfile concept. I'm using Forms 6i and Forms 10g(10.1.2.0.2). OS: Windows XP
Regards,
Alok Dubey
Edited by: Alok Dubey on Nov 14, 2008 5:43 PM

But the total number (i.e.., 50,000) is scaring me to use the BlobI don't think the database will cause problem just due to the amount of data stored in blobs. Of coure you would have to check which parameters to set for the blobs to make storage efficient. If
You didn't mention your db-version, in 11G you could also think of using compression and deduplication to deal with the data amount.
In general i agree with Francois, the best way depends, but in terms of data consistency and easy backup/restore there might be some advantages in using the blob-version.
hope this helps.

Similar Messages

  • Which is better datatype for storing Images in 11gr2 Database ?

    Can anyone tell me which datatype should be maintained for storing images in database in terms of
    1. Space
    2. Speed.
    And, Is there another way for storing images instead of database ?
    Thanks/Regards in advacne.

    982164 wrote:
    Which one have better speed, database system or file system ?Database is better all around. It is not just a question of speed. It is a question of storage, security, flexibility, scalability, robustness and so on.
    If you use ASM and raw devices from a storage array or SAN, how do you get o/s files onto that? (requires a file system on the SAN/array LUNs)
    If it is inside the database, database security, concurrency and consistency apply to the image. Outside the database? How do you control who has access? Prevent someone with slippery fingers from accidentally deleting/renaming/moving images files? How do you backup up the image data with the image attribute data in the database?
    Having all this inside the database, part of the database, managed by the database, provides you with more flexibility, robustness, and security. After all a RDBMS is a data management system - it is designed for managing data. And that includes managing binary data.
    As for speed. Reading a 24MB image is reading 24MB worth of data. Whether that data is read by process A from disk1, or process B from disk2 - the amount of data is the same. So if you want faster I/O, then use faster disks. If disk1 is faster, process A will perform better reading the image than process B. If disk2 is faster, the roles are reversed.
    So I/O speed is not a direct function of process A or process B. It is a direct function of the I/O storage and fabric layer. Yes, a process's method of I/O can make a difference (e.g. using block reads not aligned with the physical blocks on disk). But this is more a configuration issue than process doing badly designed I/O calls.
    So the speed question is a bit loaded as it has more to do with the architecture and design of the I/O system - and less to do with the process doing that I/O. You can have a highly optimised I/O process doing poorly using an old and slow I/O layer, and poorly written I/O process doing pretty well on a SSD I/O layer.
    Databases like Oracle is designed for dealing with data - and thus effectively dealing with I/O. Lots of it. For lots of data. So I/O process design is not a consideration. The database processes will use the I/O layer as optimally as possible and as configured.

  • Error - Exclusive access could not be obtained because the database is in use

    I am actually trying to make a script (in Sql Server 2008) to restore one database from one backup file. I made the following code and I am getting an error -
    Msg 3101, Level 16, State 1, Line 3
    Exclusive access could not be obtained because
    the database is in use.
    Msg 3013, Level 16, State 1, Line 3
    RESTORE DATABASE is terminating abnormally.
    How do I fix this problem ?
    IF DB_ID('AdventureWorksDW') IS NOT NULL
    BEGIN
    RESTORE DATABASE [AdventureWorksDW]
    FILE = N'AdventureWorksDW_Data'
    FROM
    DISK = N'C:\Program Files\Microsoft SQL Server\
    MSSQL10_50.SS2008\MSSQL\Backup\AdventureWorksDW.bak'
    WITH FILE = 1,
    MOVE N'AdventureWorksDW_Data'
    TO N'C:\Program Files\Microsoft SQL Server\
    MSSQL10_50.SS2008\MSSQL\DATA\AdventureWorksDW.mdf',
    MOVE N'AdventureWorksDW_Log'
    TO N'C:\Program Files\Microsoft SQL Server\
    MSSQL10_50.SS2008\MSSQL\DATA\AdventureWorksDW_0.LDF',
    NOUNLOAD, STATS = 10
    END

    Check, if there are existing connections to the database you are restoring by following command
    select spid from sys.sysprocesses where dbid = db_id('AdventureWorksDW')
    if you see any existing connections then kill them by issuing KILL command Syntax for kill is
    KILL <SPID>
    once you see there are no more connections then 
    Use mastergoIF DB_ID('AdventureWorksDW') IS NOT NULL
    BEGIN
    RESTORE DATABASE [AdventureWorksDW]
    FILE = N'AdventureWorksDW_Data'
    FROM
    DISK = N'C:\Program Files\Microsoft SQL Server\
    MSSQL10_50.SS2008\MSSQL\Backup\AdventureWorksDW.bak'
    WITH FILE = 1,
    MOVE N'AdventureWorksDW_Data'
    TO N'C:\Program Files\Microsoft SQL Server\
    MSSQL10_50.SS2008\MSSQL\DATA\AdventureWorksDW.mdf',
    MOVE N'AdventureWorksDW_Log'
    TO N'C:\Program Files\Microsoft SQL Server\
    MSSQL10_50.SS2008\MSSQL\DATA\AdventureWorksDW_0.LDF',
    NOUNLOAD, STATS = 10
    END
    Mark as answer, if it works.

  • Exclusive access could not be obtained because the database is in use

    Hi
    I am trying to use sql server 2005 management stodio to restore a database. But I got this error message:
    Exclusive access could not be obtained because the database is in use
    Anyone know how to solve this problem?
    Thanks
    Li

     Li556035 wrote:
    Hi
    I am trying to use sql server 2005 management stodio to restore a database. But I got this error message:
    Exclusive access could not be obtained because the database is in use
    Anyone know how to solve this problem?
    Thanks
    Li
    If you don not have any process running on your pc that uses your database like Enterprise Manager or any other third party application, use
    SqlConnection.ClearAllPools();
     in C# code before restoring. Like the following code:
    Code Snippet
    public void BackupAndRestore(string Query)
         SqlConnection.ClearAllPools();
    SqlConnection connection = new     SqlConnection(ConfigurationManager.AppSettings["ConnectToMasterDB"]);
         SqlDataAdapter da = new SqlDataAdapter();
         da.SelectCommand = new SqlCommand();
         da.SelectCommand.Connection = connection;
         da.SelectCommand.CommandText = Query;
         da.SelectCommand.ExecuteNonQuery();

  • How to access the database jar file using the derby 10.2.1.6 database ?

    Hi,
    How to access the database jar file using the derby 10.2.1.6 database ?
    I have used like below. And i am getting the following the error:
    "org.apache.tomcat.dbcp.dbcp.SQLNestedException: Cannot load JDBC driver class 'org.apache.derby.jdbc.EmbeddedDriver'
    at org.apache.tomcat.dbcp.dbcp.BasicDataSource.createDataSource(BasicDataSource.java:1136)"
    My context.xml file looks like this:
    <Context crossContext="true">
    <Resource name="jdbc/derby" auth="Container"
    type="javax.sql.DataSource" driverClassName="org.apache.derby.jdbc.EmbeddedDriver"
    url="jdbc:derby:jar(\CalypsoDemo\database.jar)samples"
    username="xxx" password="xxx" maxActive="20" maxIdle="10"
    maxWait="-1"/>
    </Context>
    What could be the reason.?
    Any suggestions will be appriciated.
    Thanks in Advance,
    Gana.

    ya, I have restarted. Can you please tell me whether the path which i am giving is right or not in the context file?
    Thanks,
    Gana.

  • Edit the database that RH10 uses to generate the CPD file

    Is it possible to edit the database that RH10 uses to generate the CPD file? I've got one weird entry in the topics list in the Project Manager pod. I've deleted the CPD file and let RH10 rebuild it but the entry is still there.  My team leader would like me to get rid of the entry before we send the project to translation. Thanks.

    Dang, I saw that same problem occur with a project I was trying to fix but eventually I had to start over on a fresh copy of the broken project and did not create the problem again.
    If you are using an agency that translates and uses RoboHelp, the last thing I would have done is delete the snippet. They would have translated that once instead of everywhere it is used thus keeping costs down. That is an aside though.
    Do you have a backup of the project so that you can recreate the Snippet in the hope that the project is good with that in and you can then delete again to check you used the right option?
    See www.grainge.org for RoboHelp and Authoring tips
    @petergrainge

  • What datatype should i use to store imaq image in sql database?

    Hi there i am thinking of saving the imaq image into database for retrieval in my website so that it's like a stream but i don't like what datatype does labview store the image as.

    You have two options for storing images in a relational database:
    A.  Don't put it in a database.  Store it as a file, and store the pointer int he DB (as mentioned above).
    B.  Store it as a blob datatype.  See here for more info.

  • How to send  changes in the Database Table Periodically using Change Pointe

    Hi,
           How to send  changes in the Database Table to the external system Periodically using Change Pointers.
    Thanks & Regards,
    Gopi.

    That depends on what table you are referring to.

  • Copy the database for my use.  my level is beginner

    hello, there is a Database here at work
    and i was given the permission by the dba to copy and put it in my local drive. i know this is a big one so it might not be possible.
    the reason is so i can create my application from maybe home without logging in the real databse.
    any ideas on how i can achieve this task?
    thanks

    Hi ,
    After installing the db software and configuring the starter database (using Data Base Configuration Assistant)- which can be done automatically , i advise you to do this way - the dba of your company can export the database schema(s) you work on or need and afterwards you can use this exported file to import it in your pc.....
    or he can provide you a sql script which contains all schema objects(tables,views....e.t.c.).
    Greetings,
    Simon

  • How the database interpreter identifies the database system being used

    Hi All,
    How the database interface identifies which database system is being used by the SAP, so that it converts open SQL statements into the correspoding Native SQL statements understood by the database system.
    Thank you.

    You can more information through FM DB_DBRELINFO.  And indeed even more through other function modules in the group SDBI_DBINFO.
    matt

  • How to store photo images in a database table?

    Hello Y'all,
    How do I store about 695 signs inventory photo images from a PDF file to an Oracle database table? We are using Oracle 10.2.0.2. What data type should I use for these images? How about the table space? What table space should I allocate to ensure there is no space issue?
    Thanks in advance for any/all the help.

    Here you go..
    Assuming you have a table
    test_blob (col1 BLOB);
    Create an oracle directory or use an existing one to place the image on the oracle server.
    create or replace directory tmp_blob as '/tmp';This tmp location should exist on your server where oracle is installed.
    also ftp the image file (say image1.bmp) to this location
    declare
    l_blob BLOB;
    l_bfle BFILE;
    l_re BOOLEAN := FALSE;
    Begin
    DBMS_LOB.createtemporary(l_blob, TRUE);
    insert into test_blob(col1) values (EMPTY_BLOB())
    returning col1 into l_blob;
    --return image into l_blob;
    l_bfile := BFILENAME('TMP_BLOB','image1.bmp');
    --check if file exists
    l_ret := DBMS_LOB.fileexists (l_bfile) = 1;
    if (l_ret)
    then
    DBMS_LOB.fileopen(l_bfile);
    DBMS_LOB.loadfromfile(l_blob, l_bfile, DBMS_LOB.getlength(l_bfile));
    commit;
    else
    DBMS_OUTPUT.put_line('File not present');
    end if;
    end;
    / not tested this exact one.. check for the syntax errors if any.. this should work

  • How to parse XML and store the data in  tables using sql or plsql?

    I want to parse the xml
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <xmlListWrapper>
        <size>2</size>
    <AppTypeID>10</AppTypeID>
    </xmlListWrapper>
    and store in a table
    |pk|apptypeid|
    1     10

    You can extract data from your XML along these lines...
    SQL> ed
    Wrote file afiedt.buf
      1  with t as (select xmltype('<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
      2  <xmlListWrapper>
      3    <size>2</size>
      4    <AppTypeID>10</AppTypeID>
      5    <AppTypeID>20</AppTypeID>
      6  </xmlListWrapper>') as xml from dual)
      7  --
      8  -- end of example data
      9  --
    10  select x.*
    11  from   t
    12        ,xmltable('/xmlListWrapper/AppTypeID'
    13                  passing t.xml
    14                  columns pk for ordinality
    15                         ,apptypeid number path '.'
    16*                ) x
    SQL> /
            PK  APPTYPEID
             1         10
             2         20
    SQL>
    Inserting it to a table is obviously achieved using an INSERT ... SELECT ... where the SELECT is extracting the data from the XML.

  • How to store the certificate file by using import java.security package?

    Hi,
    I have a certificate file whose extension is .p12(So, it conforms to pkcs 12 standart).
    I wanna store this file which is in my file system in my pc. and I wann to store this file to smart card?
    // this two row just load the specified file
    KeyStore keyStore = KeyStore.getInstance("PKCS12");
    keyStore.load(new java.io.FileInputStream(pkcs12File), keyPassword);
    // I need to store keyStore object to smart card. but I do not know how to? Any idea????

    This is not adding external p12 f�le inside the smart card ? Am I right? I want a p12 f�le to add this this file to smart card indside

  • How to Delete rows in the database table by using Table Control

    Hi Experts,
    I wrote one program.
    In that program i used table control.
    I displayed data from database table in the table control, but i want to delete selected rows.
    Can anybody please tell me this by writing sample code
    thank you
    Basu

    Hi ,
    Pls try this coding below or check the prg demo  - RSDEMO02 in se38
    WHEN 'DELL'.
    * remove marked lines
          LOOP AT IT_SPFLI WHERE MARKED = 'X'.
            DELETE IT_SPFLI.
          ENDLOOP.
          IF SY-SUBRC <> 0.
            GET CURSOR FIELD FLD LINE LINNO OFFSET OFF.
            SET CURSOR FIELD FLD LINE LINNO OFFSET OFF.
            IF FLD CP 'IT_SPFLI*' AND SY-SUBRC = 0.
              LINNO = LINNO + TC_SPFLI-TOP_LINE - 1.
              DELETE IT_SPFLI INDEX LINNO.
              TC_SPFLI-LINES = TC_SPFLI-LINES - 1.
            ENDIF.
          ENDIF.
    or another eg :
    MODULE USER_COMMAND_0100 INPUT.
        SAVE_CODE = OK_CODE.
        CLEAR OK_CODE.
        CASE SAVE_CODE.
    WHEN 'DELE'.
                CALL FUNCTION 'COPO_POPUP_TO_GOON'
                    EXPORTING
                         TEXTLINE1 = 'Selected rows will be deleted!'
                         TEXTLINE2 = 'Are you sure?'
                         TITEL     = 'Delete rows'
                    IMPORTING
                         answer    = confirmation.
                IF CONFIRMATION = 'G'.
                    REFRESH ITAB_PHONELIST.
                    CLEAR ITAB_PHONELIST.
                ENDIF.
    MODULE EXTRACT_USERDATA INPUT.
        CASE SAVE_CODE.
            WHEN 'DELE'.
                IF SELECTION IS INITIAL AND
                   confirmation = 'G'.
                     CLEAR ITAB_PHONELIST.
        ITAB_PHONELIST-NAME = RECORD-NAME.
        ITAB_PHONELIST-PHONE = RECORD-PHONE.
        ITAB_PHONELIST-EMAIL = RECORD-EMAIL.
        APPEND ITAB_PHONELIST.
    <b>Reward pts if found usefull :)</b>
    regards
    Sathish

  • E-Business Suite Customisations - which version of the Database can I use?

    Hi,
    We've made some customisations to the E-Business suite and want to find out what the Oracle official line is on licencing database. We think that making the customisations means that we need more database but could a lower (& cheaper) type of database license be acquired (standard?) to handle the processing for any customs and then, using a link, just load the finished data into the Apps interface, thereby avoiding any customs in the Apps db? If so, can it be on the same server as the Apps?

    The best place for such app specific request would be in one of the eBusiness forums.
    Nicolas.

Maybe you are looking for

  • Issue in uploading data to standerd DSO

    Hi Experts, Here I am in a process of loading data to 0SRIV_D3.I followed below steps. 1.Checked data availability in source system using RSA3.30 records were found in source system standerd datasource. 2.Created IP with Initialise with data transfer

  • Problem with itunes... Please help!

    Hi all, I have 100 songs in my itunes that successfully transferred to my ipod. Now when I go into itunes and double click on a song I want to hear in the library, it plays the song for about 3 seconds, then it skipps and scratches as if the cd is sk

  • Grant debug connect session to user

    I understand that if DBA hasn't granted following option to "user" following way: grant debug connect session to user;, then "user" wil lget following error when she tries to debug: ORA-0131:Insufficient Priviledges Debugging requires Debug connect s

  • SAP Netweaver EHP4 32bits

    Hello, I want to install sap _EHP4 in 32 bits server using SPAM/SAINT I dont have solution manager configured. 1) i wanted to know if I really need the xml which is generated from Solution manager or not (accrding im using 32bits and saint) 2) I can

  • ICloud Backup Details

    Will an iCloud backup also backup all of the settings and iOS settings?