class_docstr: Database for `OperationsCache` class.
  Includes low-level idea of caching pipeline nodes using relational database.
  
  :param cache_dir: path to the place where cache files should be stored.
class_docstr_tok: ["Database","for","`","OperationsCache","`","class",".","Includes","low-level","idea","of","caching","pipeline","nodes","using","relational","database",".",":","param","cache_dir",":","path","to","the","place","where","cache","files","should","be","stored","."]
docstr: Creates temp table to keep order of uids while doing select operation in operations getter.
  
  :param cur: cursor with already installed DB connection
  :param uids: list of operations uids for keeping the order
  
  :return tmp_name: str name of newly created temp table
docstr_tok: ["Creates","temp","table","to","keep","order","of","uids","while","doing","select","operation","in","operations","getter",".",":","param","cur",":","cursor","with","already","installed","DB","connection",":","param","uids",":","list","of","operations","uids","for","keeping","the","order",":","return","tmp_name",":","str","name","of","newly","created","temp","table"]
code: def _create_temp_for_ordered_select(
      cur: sqlite3.Cursor, uids: List[str]
  ) -> str:
      """
      Creates temp table to keep order of uids while doing select operation in operations getter.
  
      :param cur: cursor with already installed DB connection
      :param uids: list of operations uids for keeping the order
  
      :return tmp_name: str name of newly created temp table
      """
      _, *other = uids
      tmp_name = f"tmp_{getpid()}"
      query = (
          f"CREATE TEMP TABLE {tmp_name} AS SELECT 1 as id1, ? as id2"
      )
      for num, _ in enumerate(other, 2):
          query += f" union SELECT {num} as id1, ? as id2"
      cur.execute(query, uids)
      return tmp_name
  
file_path: FEDOT/fedot/core/caching/pipelines_cache_db.py
imports: import pickle
  import sqlite3
  from contextlib import closing
  from os import getpid
  from typing import List, Optional, Tuple, TypeVar
  from fedot.core.caching.base_cache_db import BaseCacheDB
  from fedot.core.operations.operation import Operation
label_desc: Use image node_id 2 for calling the OperationsCacheDB obj's underlying member method code with example usage: obj._create_temp_for_ordered_select(cur, uids) and returns: tmp_name