How to export .bib with the selected fields?

I want to export .bib with some selected Fields as I don’t want all the fields such as groups, marks output to a bib file as they are not needed in latex though they maynot be displayed.

You can do this after the export of your selected entries:

  • Open the newly-created .bib file.
  • Select the menu Quality -> Cleanup entries
  • Check “Enable field formatters”
  • In the drop-down menu at the window bottom, select the field you want to be removed (like Groups — groups is near the botton, I do not know why), and select the action “clear”. Add this combination to the list of cleanup actions by clicking on the “plus” sign (+).
  • click on OK

Note the dedicated help file is here : https://docs.jabref.org/finding-sorting-and-cleaning-entries/cleanupentries

Thank you for your kind reply.
However, this procedure may cause that some entries can not be used, what I want is to retain this entries, only when I export can I select the entries I want to export. For example, the comments entry I want it retains when I read and don’t want it to export.

Besides, field formatters seem a little uneasy to use.

In my mind, the procedure was to be applied on the already-exported entries (i.e. on the new .bib file). Hence, your main bibliographic file remains untouched.
And once you have set all the fields to be cleared in the clean-up entry dialog window, they are kept there for your next export.

I know the function but it is not I want.
For example, I have taken notes for an article and save it in the comments. However, I don’t want it to export to a new bib file which is used for a latex. (but I want it remains in the original bib file)
If it cleans up my notes in the original file it will bring me a lot of loss, I only want to filter it when export the selected entries to another bib file. All the entries will be saved fovever in the original bib file.

Sorry for the misunderstanding. To me, it became unclear what your issue is.

I understand you want:

  • to keep you main bibliographic file as it is.
  • to remove your notes/comments from the exported file.

If so, why cleaning your comments/notes in the exported file does not do the job?

I want:

  • to keep my main bibliographic file (eg 1.bib) as it is (with my notes/comments).
    1.bib:
    @Article{2020DvornikImportance,
    author = {Nikita Dvornik and Julien Mairal and Cordelia Schmid and Dvornik, Nikita and Mairal, Julien and Schmid, Cordelia},
    journal = {IEEE transactions on pattern analysis and machine intelligence},
    title = {On the importance of visual context for data augmentation in scene understanding},
    year = {2019},

    abstract = {111},
    comment = {222},

    publisher = {IEEE},
    }

  • to remove your notes/comments from the exported file to get a new file (2.bib).

2.bib:
@Article{2020DvornikImportance,
author = {Nikita Dvornik and Julien Mairal and Cordelia Schmid and Dvornik, Nikita and Mairal, Julien and Schmid, Cordelia},
journal = {IEEE transactions on pattern analysis and machine intelligence},
title = {On the importance of visual context for data augmentation in scene understanding},
year = {2019},
publisher = {IEEE},
}

  • my notes/commentsmy in main bibliographic file remains the same not like 2.bib.

However, when I cleaning your comments/notes in the exported file, 1.bib will be the same as 2.bib.

When you clean your file 2.bib using Quality -> Cleanup-entries, only the selected entries of 2.bib should be modified. So, the file 1.bib should remained the same.

Which version of JabRef are you using?
Could you make a video showing your actions?

I use JabRef 5.2–2020-12-24–6a2a512
Windows 10 10.0 amd64
Java 14.0.2.
I only have a 1.bib file in the begining and open it, which is the current and base file of jabref.
Then I want to output a 2.bib file which only has the selected fields I want (for example I don’t want the comments field). So I use your method:

  • Select the menu Quality -> Cleanup entries
  • Check “Enable field formatters”
  • In the drop-down menu at the window bottom, select the field you want to be removed (like Groups — groups is near the botton, I do not know why), and select the action “clear”. Add this combination to the list of cleanup actions by clicking on the “plus” sign (+).
  • click on OK
    After I gain a 2.bib file with the comments cleaned, 1.bib file has also clean the comments.

Maybe you can tell me to create the same file 2.bib as 1.bib first, then open 2.bib, then do the aboving. I think it is quite inconvenient and easy to get some serious problems like carelessly losing important data when forget to create the same 2.bib file. Maybe it can improves in the furture vesion.

You need to export your entries from file 1.bib to file 2.bib first. And then do the cleanup on the file 2.bib.

Hope it can improve in the furture vesion.
@Siedlerchr