I am new to PyQGIS and I want to add one more field in my existed table. Here is my code:
pointLayer = QgsVectorLayer(uri, 'my_layer', 'delimitedtext')
pointLayer.dataProvider().addAttributes([QgsField("new1", QVariant.Double)])
pointLayer.updateFields()
However, there's no difference if I print the names of the field before and after adding attributes respectively.
I don't know how to fix the problem and the code does not have any error. I will appreciate it if you can help me out.