If I forgot to save wallet.dat after i make transaction

Dear BTCGPU Enthusiast,
If i forgot to save or make back up wallet after i make transaction with BTG Core 15.2 , and the wallet has damage , but i still have the back up wallet.dat from 2018 , will i lose the new transaction ?

PS: when i make transaction the wallet is not sync with the network.

I’m not 100% clear what you’re asking, but I’ll do my best.

Note that when you’re asking questions about BTG and the Core Wallet, you can also search the web for the same issues with the Bitcoin Core Wallet; the BTG Core Wallet is based on the Bitcoin Core Wallet and the vast majority of functionality and fixes are the same as for the same-version Bitcoin wallet.

If i forgot to save or make back up wallet after i make transaction with BTG Core 15.2 , and the wallet has damage , but i still have the back up wallet.dat from 2018 , will i lose the new transaction ?

The status of your wallet software doesn’t really matter to the transaction - all that matters is what is on the blockchain.

You say, “after i make transaction…” it sounds like you’re sending coins. If you made a transaction to spend coins from that wallet software, and that transaction was broadcast to the network and got onto the blockchain, then that transaction is now part of permanent history on the blockchain. You personal wallet software cannot change it. It cannot be lost.

On the other hand, if you received a payment to your wallet address, then someone else put a transaction on the blockchain with a payment to your address. Again, that transaction is on the blockchain forever. Nothing you do to your wallet software will change that. It cannot be lost.

None of it can be “lost,” it’s all on the blockchain.

However: if you’re talking about funds you received, and you completely lose your wallet info, you may lose the ability to control those funds. The ability to control the funds in your address rests upon the private keys that the wallet software generated. These private keys give the authority to sign a transaction to send coins from your address to someone else.

The funds will sit on the blockchain, but if you can’t control them, they might as well be “lost.”

Here you’re talking about a “new transaction” after your wallet was “damaged.” So it doesn’t sound like sending, it sounds like receiving.

Your wallet address can still receive funds on the blockchain. That address still works fine in and does not rely upon your wallet software at all.

If you’re talking about a transaction to receive funds, your wallet software’s status at the time does not matter at all.

If you’re talking about sending a transaction: it’s technically possible for wallet software to create and send a transaction if it is connected to the network, even if the wallet is not synced. If the transaction is valid, the network will accept it and the funds transfer will proceed.

“Synced” means the wallet has all the information on all the blocks so that all amounts are up to date. “Connected” means that your wallet can talk to other nodes to get (and give) information.

If you are connected, you can send a transaction and, assuming it’s a valid transaction (the funds exist), then it will be accepted by the network and added to the blockchain.

While you are connected, your wallet will also ask other nodes for copies of any blocks it doesn’t yet know about so that it can catch up and be “in sync” with the rest of the world. This way, it knows about any new transactions which put money into you address that you can send.

The problem is that if the wallet software is not yet fully synced with the network, how does the wallet know how many coins are in the wallet address? Until the wallet gets to the very last block, it doesn’t know how many coins were received to that address, and it doesn’t know how many were already spent. The other nodes do know, especially the miners. So, if you try to send a transaction saying “spend these coins from my wallet,” and they’ve already be spent, the other nodes will know it and will refuse the transaction.

Some wallet software will not even allow you to compose a transaction to send coins until the wallet is synced, because it doesn’t know what coins it has available to spend until it is synced. I believe the BTG Core wallet will allow you to compose a transaction to send coins while still syncing, as long as it already knew about those coins - in other words, it can try to spend coins received long ago. Other nodes will respect that transactions, as long as those old coins are still yours to spend.

However, if you’re talking about receiving, then it’s all fine - coins are received on the blockchain to your wallet address, and your wallet software is completely unnecessary for that.

i still have the back up wallet.dat from 2018

That’s good. You should be able to restore your ability to control all the funds received under that wallet, including all the change addresses it used when sending… assuming you used the normal Core Wallet functions to make your transactions. (If you got fancy and technical using the command line, this may not be true.)

Hello edward,
It is very pleased to see your reply with very detail explanation , i am very sorry if my question confused you , maybe its my english very bad so i can not deliver the right meaning from my question .
I send the coin to my exchange wallet before i go with my unsynced BTG core wallet, and it was damage cause my children play with my external hard drive while i am gone :slight_smile: . that is 5 months ago story . I tried to use - rescan and - reindex to synced my wallet again , but the transaction i had been made is not there .
just wondering , is it any kind relation with the 51% attack hit that we experienced on january ?
Thank you and Best regards to you Edward and all Bitcoingold enthusiast
Robert Wijaya

It has absolutely nothing to do with the 51% attack in January - those attacks could only affect the attacker’s own coins, not yours or anyone else’s.

Check your address and the exchange wallet address on a blockchain explorer like https://explorer.bitcoingold.org/insight.

If the transaction was sent 5 months ago, you will see it on chain in the explorer.
If the transaction was not sent, you will not see it in the explorer.

This is true regardless of the state of your personal wallet software - transfers occur on the blockchain, so the blockchain has all the information.