Skip to content

Commit 7116cd7

Browse files
quweifanquweifan
andauthored
fix:修复特殊语句执行的问题 (#8)
* fix:修复特殊语句执行的问题 * release: @react-native-oh-library/react-native-sqlite-storage@6.0.1-0.0.6 --------- Co-authored-by: quweifan <quweifan1@h-partners.com>
1 parent 3c26a1f commit 7116cd7

File tree

5 files changed

+4
-5
lines changed

5 files changed

+4
-5
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@react-native-oh-tpl/react-native-sqlite-storage",
3-
"version": "6.0.1-0.0.5",
3+
"version": "6.0.1-0.0.6",
44
"description": "SQLite3 bindings for React Native (Android & iOS)",
55
"overrides":{
66
"@react-native/codegen": "0.74.0"

platforms/harmony/sqlite_storage.har

-38 Bytes
Binary file not shown.
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
export default class BuildProfile {
2-
static readonly HAR_VERSION = '6.0.1-0.0.5';
2+
static readonly HAR_VERSION = '6.0.1-0.0.6';
33
static readonly BUILD_MODE_NAME = 'debug';
44
static readonly DEBUG = true;
55
}

platforms/harmony/sqlite_storage/oh-package.json5

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
"description": "",
77
"main": "ts.ts",
88
"type": "module",
9-
"version": "6.0.1-0.0.5",
9+
"version": "6.0.1-0.0.6",
1010
"dependencies": {
1111
"@rnoh/react-native-openharmony": "file:../react_native_openharmony",
1212
}

platforms/harmony/sqlite_storage/src/main/ets/SQLitePluginTurboModule.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -260,7 +260,7 @@ export class SQLitePluginTurboModule extends TurboModule implements TM.SQLitePlu
260260
Logger.debug(CommonConstants.TAG, 'test--SQLitePlugin=backgroundExecuteSqlBatch>>>>>>插入数据失败=' + errorMessage);
261261
}
262262

263-
} else if (queryType == 'UPDATE' || queryType == 'DELETE') {
263+
} else if (queryType == 'UPDATE' || queryType == 'DELETE' || queryType == 'ALTER') {
264264
needRawQuery = false;
265265
let rowsAffected: relationalStore.ValueType = -1
266266

@@ -310,7 +310,6 @@ export class SQLitePluginTurboModule extends TurboModule implements TM.SQLitePlu
310310

311311
if (needRawQuery) {
312312
try {
313-
querySql = querySql.replace('PRAGMA table_info', 'SELECT * FROM');
314313
let resultSet = await rdbStore.querySql(querySql)
315314
const count = resultSet.columnCount;
316315
Logger.debug(CommonConstants.TAG, 'test--SQLitePlugin=backgroundExecuteSqlBatch>>>>>>查询数据个数====' + count);

0 commit comments

Comments
 (0)