An electronic device comprising: a storage configured to store a database; a memory; and at least one processor operably connected to the storage and the memory, wherein the memory is configured to store a plurality of instructions that, when executed, cause the at least one processor to: identify a state of a Write-Ahead Logging, WAL, file that is at least temporarily storing modified data corresponding to data stored in the database, wherein the WAL file is related to a first operation mode of the database based on a WAL scheme, in response to identifying the WAL file in a first state that allows reading data included in the WAL file, identify a state of a WAL index file that stores information indicating a portion of the database to store the data stored in the WAL file, and, in response to identifying the WAL index file in a first state indicating that data included in the WAL index file is allowed to be read, perform transactions related to an operation of modifying the data stored in the database, an operation of reading the data stored in the database, an operation of deleting the data stored in the database and/or an operation of adding to the data stored in the database, wherein the transactions are performed using the WAL file and the WAL index file, and in response to identifying the WAL file in a second state different from the first state that does not allow reading data included in the WAL file, perform the transactions, based on a second operation mode of the database based on a roll-back scheme. a storage configured to store a database; a memory; and at least one processor operably connected to the storage and the memory, wherein the memory is configured to store a plurality of instructions that, when executed, cause the at least one processor to: identify a state of a Write-Ahead Logging, WAL, file that is at least temporarily storing modified data corresponding to data stored in the database, wherein the WAL file is related to a first operation mode of the database based on a WAL scheme, in response to identifying the WAL file in a first state that allows reading data included in the WAL file, identify a state of a WAL index file that stores information indicating a portion of the database to store the data stored in the WAL file, and, in response to identifying the WAL index file in a first state indicating that data included in the WAL index file is allowed to be read, perform transactions related to an operation of modifying the data stored in the database, an operation of reading the data stored in the database, an operation of deleting the data stored in the database and/or an operation of adding to the data stored in the database, wherein the transactions are performed using the WAL file and the WAL index file, and in response to identifying the WAL file in a second state different from the first state that does not allow reading data included in the WAL file, perform the transactions, based on a second operation mode of the database based on a roll-back scheme. identify a state of a Write-Ahead Logging, WAL, file that is at least temporarily storing modified data corresponding to data stored in the database, wherein the WAL file is related to a first operation mode of the database based on a WAL scheme, in response to identifying the WAL file in a first state that allows reading data included in the WAL file, identify a state of a WAL index file that stores information indicating a portion of the database to store the data stored in the WAL file, and, in response to identifying the WAL index file in a first state indicating that data included in the WAL index file is allowed to be read, perform transactions related to an operation of modifying the data stored in the database, an operation of reading the data stored in the database, an operation of deleting the data stored in the database and/or an operation of adding to the data stored in the database, wherein the transactions are performed using the WAL file and the WAL index file, and in response to identifying the WAL file in a second state different from the first state that does not allow reading data included in the WAL file, perform the transactions, based on a second operation mode of the database based on a roll-back scheme.