Table gets recreated and data is lost when I publish my customization

Whenever I publish my customization to business central online, my custom table gets recreated and all data is lost.

Is there an option to prevent table from being recreated if it already exists?

Do you pubis from VSC? If yes, then you need to use "schemaUpdateMode = Synchronize" instead ofRecreate

(docs.microsoft.com/…/devenv-retaining-data-after-publishing))