Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Nested transaction sample from Usage does not work for iOS #12

Open
brody4hire opened this issue Apr 21, 2012 · 1 comment
Open

Nested transaction sample from Usage does not work for iOS #12

brody4hire opened this issue Apr 21, 2012 · 1 comment

Comments

@brody4hire
Copy link
Member

The sample from the Usage section is an excellent test of nested transactions. @marcucio did some good work to make this sample work with batching for the Android version. I also did a quick test to verify that this sample is also working with the real HTML5 SQL API in Safari (with sqlitePlugin.openDatabase replaced by window.openDatabase). However, the nested SQL command does not seem to be executed for the iOS version, which gives me confidence that it is written correctly and we should try to make it working with the iOS version as well.

I would like to do some of the Javascript cleanup first and then identify which mechanisms will have to be changed to get this working with the iOS version.

@brody4hire
Copy link
Member Author

As it turns out, you have to turn off the batching optimization in the Android version of SQLitePlugin.js to get the nested transaction sample working on the Android version. A workaround is to simply create a new transaction inside the executeSql callback function to execute a nested SQL statement. This is now clearly documented in README.md so this issue is changed from a bug to an enhancement, with a lower priority than some of the other issues.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant