Add to all table a specifix prefix.

@param db
the db
@param prefix
the prefix
183179
public static void renameTablesWithPrefix(SQLiteDatabase db, final String prefix) {
		Logger.info("MASSIVE TABLE RENAME OPERATION: ADD PREFIX " + prefix);
		query(db, null, QueryType.TABLE, new OnResultListener() {

			@Override
			public void onRow(SQLiteDatabase db, String name, String sql) {
				sql = String.format("ALTER TABLE %s RENAME TO %s%s;", name, prefix, name);
				Logger.info(sql);
				db.execSQL(sql);

			}
		});
	}
1256862
public function addPrefix($prefix)
	{
		if (!in_array($prefix, $this->prefixes))
		{
			array_push($this->prefixes, trim($prefix));
		}

		return $this;
	}
949353
void init(BuildSource source) {
        this.sqlInfo = source.getSqlInfo();
        this.join = sqlInfo.getJoin();
        this.params = sqlInfo.getParams();
        this.context = source.getParamObj();
        this.prefix = source.getPrefix();
        this.suffix = source.getSuffix();
    }
143239
public void addDatabase(Database database)
    {
        if (m_databaseCollection == null)
            m_databaseCollection = new DatabaseCollection(this);
        m_databaseCollection.addDatabase(database);
    }
799269
public void addDatabase(Database database)
    {
        this.getDatabaseList((database.getDatabaseType() & DBConstants.TABLE_MASK)).put(database.getDatabaseName(false), database);
    }
625006
public void addForbiddenInjectionPrefix(String prefix) {
		if (!Strings.isEmpty(prefix)) {
			final String real = prefix.endsWith(".") ? prefix.substring(0, prefix.length() - 1) : prefix; //$NON-NLS-1$
			this.forbiddenInjectionPrefixes.add(real);
		}
	}
700314
private void registerPrefix(String field, String prefix,
      IndexOutput outPrefix) throws IOException {
    if (!prefixReferenceIndex.containsKey(field)) {
      prefixReferenceIndex.put(field, new HashMap<String, Long>());
      prefixIdIndex.put(field, new HashMap<String, Integer>());
    }
    if (!prefixReferenceIndex.get(field).containsKey(prefix)) {
      int id = 1 + prefixReferenceIndex.get(field).size();
      prefixReferenceIndex.get(field).put(prefix, outPrefix.getFilePointer());
      prefixIdIndex.get(field).put(prefix, id);
      outPrefix.writeString(prefix);
    }
  }
243583
public void setPrefixListIds(java.util.Collection<String> prefixListIds) {
        if (prefixListIds == null) {
            this.prefixListIds = null;
            return;
        }

        this.prefixListIds = new com.amazonaws.internal.SdkInternalList<String>(prefixListIds);
    }
525159
public void setDBPedia(String dbpedia) {
    if(dbpedia != null) {
      dbpedia = dbpedia.trim();
    }
    this.dbpedia = dbpedia;
  }
745984
public void prepare(Properties p, Connection cnx)
    {
        this.tablePrefix = p.getProperty("com.enioka.jqm.jdbc.tablePrefix", "");
        queries.putAll(DbImplBase.queries);
        for (Map.Entry<String, String> entry : DbImplBase.queries.entrySet())
        {
            queries.put(entry.getKey(), this.adaptSql(entry.getValue()));
        }
    }
435282
public static function prettifyTableName($table, $prefix = '')
    {
        if ($prefix) {
            $table = self::removePrefix($table, $prefix);
        }

        return self::underscoresToCamelCase($table, true);
    }
395848
def _db_remove_prefix(self, spec, recursive = False):
        
        if recursive:
            prefix = spec['prefix']
            del spec['prefix']
            where, params = self._expand_prefix_spec(spec)
            spec['prefix'] = prefix
            params['prefix'] = prefix
            where = 'prefix <<= %(prefix)s AND ' + where
        else:
            where, params = self._expand_prefix_spec(spec)

        sql = "DELETE FROM ip_net_plan AS p WHERE %s" % where
        self._execute(sql, params)
377683
public static String add(String prefix, String name) {
    return (prefix == null) ? name : prefix+"."+name;
  }
415092
public synchronized void add(FieldTable table) throws DBException
    {
        if (m_VKeyList == null)
            this.initKeyAreas(table);

        BaseBuffer bufferNew = (BaseBuffer)table.getDataSource(); // same as .getHandle(Constants.DATA_SOURCE_HANDLE);
        if (table.getRecord().getEditMode() == Constants.EDIT_ADD)
        {
            for (int iKeyArea = Constants.MAIN_KEY_AREA; iKeyArea < table.getRecord().getKeyAreaCount() + Constants.MAIN_KEY_AREA; iKeyArea++)
            {
                try   {
                    if (iKeyArea == Constants.MAIN_KEY_AREA)
                    {   // Special logic to set auto-counter field
                        FieldInfo field = table.getRecord().getCounterField();
                        if (field != null)
                            if (!field.isNull())
                                if (!table.getRecord().isAutoSequence())
                        {   // Autosequence disabled
                            int iValue = (int)field.getValue();
                            if (iValue >= m_iCounter)
                                m_iCounter = iValue + 1;    // New next counter value
                            field = null;   // Special case - autosequence is disabled, so write the field as is.
                        }
                        if (field != null)
                        {
                            field.setValue(m_iCounter++, Constants.DONT_DISPLAY, Constants.READ_MOVE);  // ReadMove keeps this method from being called again
                            table.fieldsToData(table.getRecord()); // Update buffer
                            bufferNew = (BaseBuffer)table.getDataSource();  // same as .getHandle(Constants.DATA_SOURCE_HANDLE);
                        }
                    }
                    bufferNew.bufferToFields(table.getRecord(), Constants.DONT_DISPLAY, Constants.READ_MOVE);
                    this.getPKeyArea(iKeyArea).doWrite(table, table.getRecord().getKeyArea(iKeyArea), bufferNew);
                } catch (DBException ex)    {
                    if (ex.getErrorCode() == Constants.DUPLICATE_KEY)
                    {
                        iKeyArea--;     // Duplicate key, delete all keys added so far!!!
                        while (iKeyArea >= Constants.MAIN_KEY_AREA)
                        {
                            bufferNew.bufferToFields(table.getRecord(), Constants.DONT_DISPLAY, Constants.READ_MOVE);
                            this.getPKeyArea(iKeyArea).doRemove(table, table.getRecord().getKeyArea(iKeyArea), bufferNew);
                            iKeyArea--;
                        }
                    }
                    throw ex;
                }
            }
            // Restore the record before returing (key.doWrite probably changed it).
            bufferNew.bufferToFields(table.getRecord(), Constants.DONT_DISPLAY, Constants.READ_MOVE);
        }
        else
            throw new DBException(Constants.INVALID_RECORD);
    }
409823
private <T> void setCached(String prefix, String postfix, T data) {
    cache.put(prefix + '.' + postfix, data);
  }
1176234
public void addAll(Configuration other, String prefix) {
		final StringBuilder bld = new StringBuilder();
		bld.append(prefix);
		final int pl = bld.length();

		synchronized (this.confData) {
			synchronized (other.confData) {
				for (Map.Entry<String, Object> entry : other.confData.entrySet()) {
					bld.setLength(pl);
					bld.append(entry.getKey());
					this.confData.put(bld.toString(), entry.getValue());
				}
			}
		}
	}
1171740
def add_prefix(prefix, s):
    ""
    # tokenize the XPath expression
    toks = xpath_lexer.scan(s)
    # add default prefix to unprefixed names
    toks2 = [_add_prefix(prefix, tok) for tok in toks]
    # build a string of the patched expression
    ls = [x.value for x in toks2]
    return ''.join(ls)