1# OH_Predicates 2 3## Overview 4 5Defines a **predicates** object. 6 7**Since**: 10 8 9**Related module**: [RDB](capi-rdb.md) 10 11**Header file**: [oh_predicates.h](capi-oh-predicates-h.md) 12 13### Member Variables 14 15| Name | Description | 16| ---------- | -------------------------------- | 17| int64_t id | Unique identifier of the **H_Predicates** struct.| 18 19### Member Functions 20 21| Name | Description | 22| ------------------------------------------------------------ | ------------------------------------------------------------ | 23| [OH_Predicates *(*equalTo)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject)](#equalto) | Pointer to the function used to create a predicates object to search for the field values that are equal to the specified value. | 24| [OH_Predicates *(*notEqualTo)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject)](#notequalto) | Pointer to the function used to create a predicates object to search for the field values that are not equal to the specified value.<br>This method is equivalent to "!=" in SQL statements.| 25| [OH_Predicates *(*beginWrap)(OH_Predicates *predicates)](#beginwrap) | Pointer to the function used to add a left parenthesis to the predicates.<br>This method is equivalent to "(" in SQL statements.| 26| [OH_Predicates *(*endWrap)(OH_Predicates *predicates)](#endwrap) | Pointer to the function used to add a right parenthesis to the predicates.<br>This method is equivalent to ")" in SQL statements.| 27| [OH_Predicates *(*orOperate)(OH_Predicates *predicates)](#oroperate) | Pointer to the function used to add the OR operator to the predicates.<br>This method is equivalent to **OR** in SQL statements.| 28| [OH_Predicates *(*andOperate)(OH_Predicates *predicates)](#andoperate) | Pointer to the function used to add the AND operator to the predicates.<br>This method is equivalent to **AND** in SQL statements.| 29| [OH_Predicates *(*isNull)(OH_Predicates *predicates, const char *field)](#isnull) | Pointer to the function used to create a predicates object to search for the field values that are null.<br>This method is equivalent to **IS NULL** in SQL statements.| 30| [OH_Predicates *(*isNotNull)(OH_Predicates *predicates, const char *field)](#isnotnull) | Pointer to the function used to create a predicates object to search for the field values that are not null.<br>This method is equivalent to **IS NOT NULL** in SQL statements.| 31| [OH_Predicates *(*like)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject)](#like) | Pointer to the function used to create a predicates object to search for the field values that are similar to the specified string.<br>This method is equivalent to **LIKE** in SQL statements.| 32| [OH_Predicates *(*between)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject)](#between) | Pointer to the function used to create a predicates object to search for the field values that are within the specified range.<br>This method is equivalent to **BETWEEN** in SQL statements.| 33| [OH_Predicates *(*notBetween)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject)](#notbetween) | Pointer to the function used to create a predicates object to search for the field values that are out of the specified range.<br>This method is equivalent to **NOT BETWEEN** in SQL statements.| 34| [OH_Predicates *(*greaterThan)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject)](#greaterthan) | Pointer to the function used to create a predicates object to search for the field values that are greater than the specified value.<br>This method is equivalent to ">" in SQL statements.| 35| [OH_Predicates *(*lessThan)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject)](#lessthan) | Pointer to the function used to create a predicates object to search for the records that are less than the given value in the specified field.<br>This method is equivalent to "<" in SQL statements.| 36| [OH_Predicates *(*greaterThanOrEqualTo)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject)](#greaterthanorequalto) | Pointer to the function used to create a predicates object to search for the field values that are greater than or equal to the specified value.<br>This method is equivalent to ">=" in SQL statements.| 37| [OH_Predicates *(*lessThanOrEqualTo)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject)](#lessthanorequalto) | Pointer to the function used to create a predicates object to search for the records that are less than or equal to the specified **valueObject** in the specified field.<br>This method is equivalent to "<=" in SQL statements.| 38| [OH_Predicates *(*orderBy)(OH_Predicates *predicates, const char *field, OH_OrderType type)](#orderby) | Pointer to the function used to create a predicates object to sort the values in the specified column in ascending or descending order.<br>This method is equivalent to **ORDER BY** in SQL statements.| 39| [OH_Predicates *(*distinct)(OH_Predicates *predicates)](#distinct) | Pointer to the function used to create a predicates object to filter out duplicate records.<br>This method is equivalent to **DISTINCT** in SQL statements.| 40| [OH_Predicates *(*limit)(OH_Predicates *predicates, unsigned int value)](#limit) | Pointer to the function used to create a predicates object to specify the maximum number of records.<br>This method is equivalent to **LIMIT** in SQL statements.| 41| [OH_Predicates *(*offset)(OH_Predicates *predicates, unsigned int rowOffset)](#offset) | Pointer to the function used to create a predicates object to specify the start position of the query result.<br>This method is equivalent to **OFFSET** in SQL statements.| 42| [OH_Predicates *(*groupBy)(OH_Predicates *predicates, char const *const *fields, int length)](#groupby) | Pointer to the function used to create a predicates object to group the results by the specified columns.<br>This method is equivalent to **GROUP BY** in SQL statements.| 43| [OH_Predicates *(*in)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject)](#in) | Pointer to the function used to create a predicates object to search for the field values that are within the specified range.<br>This method is equivalent to **IN** in SQL statements.| 44| [OH_Predicates *(*notIn)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject)](#notin) | Pointer to the function used to create a predicates object to search for the field values that are out of the specified range.<br>This method is equivalent to **NOT IN** in SQL statements.| 45| [OH_Predicates *(*clear)(OH_Predicates *predicates)](#clear) | Pointer to the function used to clear a predicates instance. | 46| [int (*destroy)(OH_Predicates *predicates)](#destroy) | Destroys an **OH_Predicates** object and reclaims the memory occupied. | 47 48 49## Member Function Description 50 51### equalTo() 52 53``` 54OH_Predicates *(*equalTo)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject) 55``` 56 57**Description** 58 59Pointer to the function used to create a predicates object to search for the field values that are equal to the specified value. 60 61**Since**: 10 62 63**Parameters** 64 65| Name | Description | 66| ------------------------- | ------------------------------------------------------------ | 67| OH_Predicates *predicates | Pointer to the **OH_Predicates** instance. | 68| const char *field | Pointer to the column name in the database table. | 69| [OH_VObject](capi-rdb-oh-vobject.md) *valueObject | Pointer to an [OH_VObject](capi-rdb-oh-vobject.md) instance, indicating the value to be matched with the predicate.| 70 71**Returns** 72 73| Type | Description | 74| --------------- | -------------------------- | 75| OH_Predicates * | Predicates that match the specified field.| 76 77### notEqualTo() 78 79``` 80OH_Predicates *(*notEqualTo)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject) 81``` 82 83**Description** 84 85Pointer to the function used to create a predicates object to search for the field values that are not equal to the specified value.<br>This method is equivalent to "!=" in SQL statements. 86 87**Since**: 10 88 89**Parameters** 90 91| Name | Description | 92| --------------------------------------------- | ------------------------------------------------------------ | 93| OH_Predicates *predicates | Pointer to the **OH_Predicates** instance. | 94| const char *field | Column name in the database table. | 95| [OH_VObject](capi-rdb-oh-vobject.md) *valueObject | Pointer to an [OH_VObject](capi-rdb-oh-vobject.md) instance, indicating the value to be matched with the predicate.| 96 97**Returns** 98 99| Type | Description | 100| --------------- | -------------------------- | 101| OH_Predicates * | Predicates that match the specified field.| 102 103### beginWrap() 104 105``` 106OH_Predicates *(*beginWrap)(OH_Predicates *predicates) 107``` 108 109**Description** 110 111Pointer to the function used to add a left parenthesis to the predicates.<br>This method is equivalent to "(" in SQL statements. 112 113**Since**: 10 114 115**Parameters** 116 117| Name | Description | 118| ------------------------ | --------------------------------- | 119| H_Predicates *predicates | Pointer to the **OH_Predicates** instance.| 120 121**Returns** 122 123| Type | Description | 124| --------------- | ---------------------- | 125| OH_Predicates * | Predicates with a left parenthesis.| 126 127### endWrap() 128 129``` 130OH_Predicates *(*endWrap)(OH_Predicates *predicates) 131``` 132 133**Description** 134 135Pointer to the function used to add a right parenthesis to the predicates.<br>This method is equivalent to ")" in SQL statements. 136 137**Since**: 10 138 139**Parameters** 140 141| Name | Description | 142| ------------------------- | --------------------------------- | 143| OH_Predicates *predicates | Pointer to the **OH_Predicates** instance.| 144 145**Returns** 146 147| Type | Description | 148| --------------- | ---------------------- | 149| OH_Predicates * | Predicates with a right parenthesis.| 150 151### orOperate() 152 153``` 154OH_Predicates *(*orOperate)(OH_Predicates *predicates) 155``` 156 157**Description** 158 159Pointer to the function used to add the OR operator to the predicates.<br>This method is equivalent to **OR** in SQL statements. 160 161**Since**: 10 162 163**Parameters** 164 165| Name | Description | 166| ------------------------- | --------------------------------- | 167| OH_Predicates *predicates | Pointer to the **OH_Predicates** instance.| 168 169**Returns** 170 171| Type | Description | 172| --------------- | ---------------------- | 173| OH_Predicates * | Predicates with the OR condition.| 174 175### andOperate() 176 177``` 178OH_Predicates *(*andOperate)(OH_Predicates *predicates) 179``` 180 181**Description** 182 183Pointer to the function used to add the AND operator to the predicates.<br>This method is equivalent to **AND** in SQL statements. 184 185**Since**: 10 186 187**Parameters** 188 189| Name | Description | 190| ------------------------- | --------------------------------- | 191| OH_Predicates *predicates | Pointer to the **OH_Predicates** instance.| 192 193**Returns** 194 195| Type | Description | 196| --------------- | ---------------------- | 197| OH_Predicates * | Predicates with the AND condition.| 198 199### isNull() 200 201``` 202OH_Predicates *(*isNull)(OH_Predicates *predicates, const char *field) 203``` 204 205**Description** 206 207Pointer to the function used to create a predicates object to search for the field values that are null.<br>This method is equivalent to **IS NULL** in SQL statements. 208 209**Since**: 10 210 211**Parameters** 212 213| Name | Description | 214| ------------------------- | --------------------------------- | 215| OH_Predicates *predicates | Pointer to the **OH_Predicates** instance.| 216| const char *field | Column name in the database table. | 217 218**Returns** 219 220| Type | Description | 221| --------------- | -------------------------- | 222| OH_Predicates * | Predicates that match the specified field.| 223 224### isNotNull() 225 226``` 227OH_Predicates *(*isNotNull)(OH_Predicates *predicates, const char *field) 228``` 229 230**Description** 231 232Pointer to the function used to create a predicates object to search for the field values that are not null.<br>This method is equivalent to **IS NOT NULL** in SQL statements. 233 234**Since**: 10 235 236**Parameters** 237 238| Name | Description | 239| ------------------------- | --------------------------------- | 240| OH_Predicates *predicates | Pointer to the **OH_Predicates** instance.| 241| const char *field | Column name in the database table. | 242 243**Returns** 244 245| Type | Description | 246| --------------- | -------------------------- | 247| OH_Predicates * | Predicates that match the specified field.| 248 249### like() 250 251``` 252OH_Predicates *(*like)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject) 253``` 254 255**Description** 256 257Pointer to the function used to create a predicates object to search for the field values that are similar to the specified string.<br>This method is equivalent to **LIKE** in SQL statements. 258 259**Since**: 10 260 261**Parameters** 262 263| Name | Description | 264| --------------------------------------------- | ------------------------------------------------------------ | 265| OH_Predicates *predicates | Pointer to the **OH_Predicates** instance. | 266| const char *field | Column name in the database table. | 267| [OH_VObject](capi-rdb-oh-vobject.md) *valueObject | Pointer to an [OH_VObject](capi-rdb-oh-vobject.md) instance, indicating the value to be matched with the predicate.| 268 269**Returns** 270 271| Type | Description | 272| --------------- | -------------------------- | 273| OH_Predicates * | Predicates that match the specified field.| 274 275 276### between() 277 278``` 279OH_Predicates *(*between)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject) 280``` 281 282**Description** 283 284Pointer to the function used to create a predicates object to search for the field values that are within the specified range.<br>This method is equivalent to **BETWEEN** in SQL statements. 285 286**Since**: 10 287 288**Parameters** 289 290| Name | Description | 291| --------------------------------------------- | ------------------------------------------------------------ | 292| OH_Predicates *predicates | Pointer to the **OH_Predicates** instance. | 293| const char *field | Column name in the database table. | 294| [OH_VObject](capi-rdb-oh-vobject.md) *valueObject | Pointer to an [OH_VObject](capi-rdb-oh-vobject.md) instance, indicating the value to be matched with the predicate.| 295 296**Returns** 297 298| Type | Description | 299| --------------- | -------------------------- | 300| OH_Predicates * | Predicates that match the specified field.| 301 302### notBetween() 303 304``` 305OH_Predicates *(*notBetween)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject) 306``` 307 308**Description** 309 310Pointer to the function used to create a predicates object to search for the field values that are out of the specified range.<br>This method is equivalent to **NOT BETWEEN** in SQL statements. 311 312**Since**: 10 313 314**Parameters** 315 316| Name | Description | 317| --------------------------------------------- | ------------------------------------------------------------ | 318| OH_Predicates *predicates | Pointer to the **OH_Predicates** instance. | 319| const char *field | Column name in the database table. | 320| [OH_VObject](capi-rdb-oh-vobject.md) *valueObject | Pointer to an [OH_VObject](capi-rdb-oh-vobject.md) instance, indicating the value to be matched with the predicate.| 321 322**Returns** 323 324| Type | Description | 325| --------------- | -------------------------- | 326| OH_Predicates * | Predicates that match the specified field.| 327 328### greaterThan() 329 330``` 331OH_Predicates *(*greaterThan)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject) 332``` 333 334**Description** 335 336Pointer to the function used to create a predicates object to search for the field values that are greater than the specified value.<br>This method is equivalent to ">" in SQL statements. 337 338**Since**: 10 339 340**Parameters** 341 342| Name | Description | 343| --------------------------------------------- | ------------------------------------------------------------ | 344| OH_Predicates *predicates | Pointer to the **OH_Predicates** instance. | 345| const char *field | Column name in the database table. | 346| [OH_VObject](capi-rdb-oh-vobject.md) *valueObject | Pointer to an [OH_VObject](capi-rdb-oh-vobject.md) instance, indicating the value to be matched with the predicate.| 347 348**Returns** 349 350| Type | Description | 351| --------------- | -------------------------- | 352| OH_Predicates * | Predicates that match the specified field.| 353 354### lessThan() 355 356``` 357OH_Predicates *(*lessThan)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject) 358``` 359 360**Description** 361 362Pointer to the function used to create a predicates object to search for the records that are less than the given value in the specified field.<br>This method is equivalent to "<" in SQL statements. 363 364**Since**: 10 365 366**Parameters** 367 368| Name | Description | 369| --------------------------------------------- | ------------------------------------------------------------ | 370| OH_Predicates *predicates | Pointer to the **OH_Predicates** instance. | 371| const char *field | Column name in the database table. | 372| [OH_VObject](capi-rdb-oh-vobject.md) *valueObject | Pointer to an [OH_VObject](capi-rdb-oh-vobject.md) instance, indicating the value to be matched with the predicate.| 373 374**Returns** 375 376| Type | Description | 377| --------------- | -------------------------- | 378| OH_Predicates * | Predicates that match the specified field.| 379 380### greaterThanOrEqualTo() 381 382``` 383OH_Predicates *(*greaterThanOrEqualTo)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject) 384``` 385 386**Description** 387 388Pointer to the function used to create a predicates object to search for the field values that are greater than or equal to the specified value.<br>This method is equivalent to ">=" in SQL statements. 389 390**Since**: 10 391 392**Parameters** 393 394| Name | Description | 395| --------------------------------------------- | ------------------------------------------------------------ | 396| OH_Predicates *predicates | Pointer to the **OH_Predicates** instance. | 397| const char *field | Column name in the database table. | 398| [OH_VObject](capi-rdb-oh-vobject.md) *valueObject | Pointer to an [OH_VObject](capi-rdb-oh-vobject.md) instance, indicating the value to be matched with the predicate.| 399 400**Returns** 401 402| Type | Description | 403| --------------- | -------------------------- | 404| OH_Predicates * | Predicates that match the specified field.| 405 406### lessThanOrEqualTo() 407 408``` 409OH_Predicates *(*lessThanOrEqualTo)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject) 410``` 411 412**Description** 413 414Pointer to the function used to create a predicates object to search for the records that are less than or equal to the specified **valueObject** in the specified field.<br>This method is equivalent to "<=" in SQL statements. 415 416**Since**: 10 417 418**Parameters** 419 420| Name | Description | 421| ------------------------- | ------------------------------------------------------------ | 422| OH_Predicates *predicates | Pointer to the **OH_Predicates** instance. | 423| const char *field | Column name in the database table. | 424| OH_VObject *valueObject | Pointer to an [OH_VObject](capi-rdb-oh-vobject.md) instance, indicating the value to be matched with the predicate.| 425 426**Returns** 427 428| Type | Description | 429| --------------- | -------------------------- | 430| OH_Predicates * | Predicates that match the specified field.| 431 432### orderBy() 433 434``` 435OH_Predicates *(*orderBy)(OH_Predicates *predicates, const char *field, OH_OrderType type) 436``` 437 438**Description** 439 440Pointer to the function used to create a predicates object to sort the values in the specified column in ascending or descending order.<br>This method is equivalent to **ORDER BY** in SQL statements. 441 442**Since**: 10 443 444**Parameters** 445 446| Name | Description | 447| ------------------------------------- | ---------------------------------------------- | 448| OH_Predicates *predicates | Pointer to the **OH_Predicates** instance. | 449| const char *field | Column name in the database table. | 450| [OH_VObject](capi-rdb-oh-vobject.md) type | Sorting type, which is an [OH_VObject](capi-rdb-oh-vobject.md).| 451 452**Returns** 453 454| Type | Description | 455| --------------- | -------------------------- | 456| OH_Predicates * | Predicates that match the specified field.| 457 458### distinct() 459 460``` 461OH_Predicates *(*distinct)(OH_Predicates *predicates) 462``` 463 464**Description** 465 466Pointer to the function used to create a predicates object to filter out duplicate records.<br>This method is equivalent to **DISTINCT** in SQL statements. 467 468**Since**: 10 469 470**Parameters** 471 472| Name | Description | 473| ------------------------- | --------------------------------- | 474| OH_Predicates *predicates | Pointer to the **OH_Predicates** instance.| 475 476**Returns** 477 478| Type | Description | 479| --------------- | ------------------------------ | 480| OH_Predicates * | Predicates that can filter out duplicate records.| 481 482### limit() 483 484``` 485OH_Predicates *(*limit)(OH_Predicates *predicates, unsigned int value) 486``` 487 488**Description** 489 490Pointer to the function used to create a predicates object to specify the maximum number of records.<br>This method is equivalent to **LIMIT** in SQL statements. 491 492**Since**: 10 493 494**Parameters** 495 496| Name | Description | 497| ------------------------- | --------------------------------- | 498| OH_Predicates *predicates | Pointer to the **OH_Predicates** instance.| 499| unsigned int value | Maximum number of data records. | 500 501**Returns** 502 503| Type | Description | 504| --------------- | ------------------------------------ | 505| OH_Predicates * | Predicates that specify the maximum number of records.| 506 507### offset() 508 509``` 510OH_Predicates *(*offset)(OH_Predicates *predicates, unsigned int rowOffset) 511``` 512 513**Description** 514 515Pointer to the function used to create a predicates object to specify the start position of the query result.<br>This method is equivalent to **OFFSET** in SQL statements. 516 517**Since**: 10 518 519**Parameters** 520 521| Name | Description | 522| ------------------------- | ---------------------------------- | 523| OH_Predicates *predicates | Pointer to the **OH_Predicates** instance. | 524| unsigned int rowOffset | Start position, which is a positive integer.| 525 526**Returns** 527 528| Type | Description | 529| --------------- | ------------------------------------ | 530| OH_Predicates * | Predicates that specify the start position of the returned result.| 531 532### groupBy() 533 534``` 535OH_Predicates *(*groupBy)(OH_Predicates *predicates, char const *const *fields, int length) 536``` 537 538**Description** 539 540Pointer to the function used to create a predicates object to group the results by the specified columns.<br>This method is equivalent to **GROUP BY** in SQL statements. 541 542**Since**: 10 543 544**Parameters** 545 546| Name | Description | 547| ------------------------- | ---------------------------------------------------- | 548| OH_Predicates *predicates | Pointer to the **OH_Predicates** instance. | 549| char const *const *fields | Names of columns to group. | 550| int length | Length of **fields**.| 551 552**Returns** 553 554| Type | Description | 555| --------------- | ---------------------- | 556| OH_Predicates * | Predicates that group rows with the same value.| 557 558### in() 559 560``` 561OH_Predicates *(*in)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject) 562``` 563 564**Description** 565 566Pointer to the function used to create a predicates object to search for the field values that are within the specified range.<br>This method is equivalent to **IN** in SQL statements. 567 568**Since**: 10 569 570**Parameters** 571 572| Name | Description | 573| --------------------------------------------- | ------------------------------------------------------------ | 574| OH_Predicates *predicates | Pointer to the **OH_Predicates** instance. | 575| const char *field | Pointer to the column name in the database table. | 576| [OH_VObject](capi-rdb-oh-vobject.md) *valueObject | Pointer to an [OH_VObject](capi-rdb-oh-vobject.md) instance, indicating the value to be matched with the predicate.| 577 578**Returns** 579 580| Type | Description | 581| --------------- | -------------------------- | 582| OH_Predicates * | Predicates that match the specified field.| 583 584### notIn() 585 586``` 587OH_Predicates *(*notIn)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject) 588``` 589 590**Description** 591 592Pointer to the function used to create a predicates object to search for the field values that are out of the specified range.<br>This method is equivalent to **NOT IN** in SQL statements. 593 594**Since**: 10 595 596**Parameters** 597 598| Name | Description | 599| --------------------------------------------- | ------------------------------------------------------------ | 600| OH_Predicates *predicates | Pointer to the **OH_Predicates** instance. | 601| const char *field | Pointer to the column name in the database table. | 602| [OH_VObject](capi-rdb-oh-vobject.md) *valueObject | Pointer to an [OH_VObject](capi-rdb-oh-vobject.md) instance, indicating the value to be matched with the predicate.| 603 604**Returns** 605 606| Type | Description | 607| --------------- | -------------------------- | 608| OH_Predicates * | Predicates that match the specified field.| 609 610### clear() 611 612``` 613OH_Predicates *(*clear)(OH_Predicates *predicates) 614``` 615 616**Description** 617 618Clears a predicates instance. 619 620**Since**: 10 621 622**Parameters** 623 624| Name | Description | 625| ------------------------- | --------------------------------- | 626| OH_Predicates *predicates | Pointer to the **OH_Predicates** instance.| 627 628**Returns** 629 630| Type | Description | 631| --------------- | ------------------ | 632| OH_Predicates * | Cleared predicates.| 633 634### destroy() 635 636``` 637int (*destroy)(OH_Predicates *predicates) 638``` 639 640**Description** 641 642Destroys an **OH_Predicates** object and reclaims the memory occupied. 643 644**Since**: 10 645 646**Parameters** 647 648| Name | Description | 649| ------------------------- | --------------------------------- | 650| OH_Predicates *predicates | Pointer to the **OH_Predicates** instance.| 651 652**Returns** 653 654| Type| Description | 655| ---- | ------------------------------------------ | 656| int | Returns **RDB_OK** if the operation is successful; returns an error code otherwise.| 657