Beispiel #1
0
        /// <summary>
        /// Substitutes ADO parameter placeholders (?) for all encountered
        /// parameter specifications.  It also tracks the positions of these
        /// parameter specifications within the query string.  This accounts for
        /// ordinal-params, named-params, and ejb3-positional-params.
        ///  </summary>
        /// <param name="sqlString">The query string. </param>
        /// <returns> The SQL query with parameter substitution complete. </returns>
        private SqlString SubstituteParams(string sqlString)
        {
            var recognizer = new ParameterSubstitutionRecognizer(factory);

            ParameterParser.Parse(sqlString, recognizer);
            parametersSpecifications = recognizer.ParametersSpecifications.ToList();

            return(recognizer.result.ToSqlString());
        }
Beispiel #2
0
        /// <summary>
        /// Substitues ADO parameter placeholders (?) for all encountered
        /// parameter specifications.  It also tracks the positions of these
        /// parameter specifications within the query string.  This accounts for
        /// ordinal-params, named-params, and ejb3-positional-params.
        ///  </summary>
        /// <param name="sqlString">The query string. </param>
        /// <returns> The SQL query with parameter substitution complete. </returns>
        private SqlString SubstituteParams(string sqlString)
        {
            ParameterSubstitutionRecognizer recognizer = new ParameterSubstitutionRecognizer();

            ParameterParser.Parse(sqlString, recognizer);

            namedParameters.Clear();
            foreach (KeyValuePair <string, object> de in recognizer.namedParameterBindPoints)
            {
                namedParameters.Add(de.Key, de.Value);
            }

            return(recognizer.result.ToSqlString());
        }
Beispiel #3
0
        /**
         * Substitues JDBC parameter placeholders (?) for all encountered
         * parameter specifications.  It also tracks the positions of these
         * parameter specifications within the query string.  This accounts for
         * ordinal-params, named-params, and ejb3-positional-params.
         *
         * @param sqlString The query string.
         * @return The SQL query with parameter substitution complete.
         */
        private SqlString substituteParams(string sqlString)
        {
            ParameterSubstitutionRecognizer recognizer = new ParameterSubstitutionRecognizer();
            ParameterParser.Parse(sqlString, recognizer);

            namedParameters.Clear();
            foreach (DictionaryEntry de in recognizer.namedParameterBindPoints)
            {
                namedParameters.Add(de.Key, de.Value);
            }

            return recognizer.result.ToSqlString();
        }
		/// <summary> 
		/// Substitues ADO parameter placeholders (?) for all encountered
		/// parameter specifications.  It also tracks the positions of these
		/// parameter specifications within the query string.  This accounts for
		/// ordinal-params, named-params, and ejb3-positional-params.
		///  </summary>
		/// <param name="sqlString">The query string. </param>
		/// <returns> The SQL query with parameter substitution complete. </returns>
		private SqlString SubstituteParams(string sqlString)
		{
			var recognizer = new ParameterSubstitutionRecognizer(factory);
			ParameterParser.Parse(sqlString, recognizer);
			parametersSpecifications = recognizer.ParametersSpecifications.ToList();

			return recognizer.result.ToSqlString();
		}