-
Type: Bug
-
Resolution: Cannot Reproduce
-
Priority: Major - P3
-
None
-
Affects Version/s: 0.9.9
-
Component/s: None
-
None
The following code fails to convert the data type from a boolean to a double (calling $set). If this feature is not supported by $set, perhaps the driver should check the data type and throw an illegal argument exception if the types do not match.
if (doc.containsField(SiteDocField.HAS_SYND_FEED.key)) {
final Object obj = doc.get(SiteDocField.HAS_SYND_FEED.key);
if (obj != null)
else
{ doc.removeField(SiteDocField.HAS_SYND_FEED.key); pCol.save(doc); } pDb.getDb().getLastError();
}
The code below successfully changes the data type (by calling save(doc)).
if (doc.containsField(SiteDocField.HAS_SYND_FEED.key)) {
final Object obj = doc.get(SiteDocField.HAS_SYND_FEED.key);
if (obj != null)
else
{ doc.removeField(SiteDocField.HAS_SYND_FEED.key); } pCol.save(doc);
pDb.getDb().getLastError();
}