Named parameters enable you to specify an argument for a particular parameter by associating the argument with the parameter's name rather than with the parameter's position in the parameter list.
Questions tagged [named-parameters]
371 questions
1
vote
4 answers
What does ‘?’ stand for in SQL?
I have this SQL by a programmer:
$sql = "
INSERT INTO
`{$database}`.`table`
(
`my_id`,
`xType`,
`subType`,
`recordID`,
`textarea`
)
VALUES
(
{$my_id},
?xType,
?subType, …

Asim Zaidi
- 27,016
- 49
- 132
- 221
1
vote
0 answers
Which Python MySQL client libraries support named parameters?
From this answer and PEP-249 we can Python MySQL client libraries might support a variety of parameter styles.
In the real world, not so much.
>>> pymysql.paramstyle
'format'
>>> MySQLdb.paramstyle
'format'
>>> oursql.paramstyle
'qmark'
Are there…

Martin Burch
- 2,726
- 4
- 31
- 59
1
vote
1 answer
Scala 2.8: type inference of anonymous functions as default parameters
In Scala 2.8.0 RC 2 this definition:
def buttonGroup[T](values: Array[T], textProvider: T => String = (t: T => t.toString)) = ...
gives the error message:
not found: value t
def buttonGroup[T](values: Array[T], textProvider: T => String =…

Alexey Romanov
- 167,066
- 35
- 309
- 487
1
vote
1 answer
JPA lower() function on parameter
I have updated project from spring 3.2 to 4.1 and hibernate 4.2 to 4.3.7 and got interesting problem.
I have query:
function parameter: String email;
getQuery(getSelect() + "where lower(o.email) = lower(:email)").setParameter("email", email);
now,…

ekitru
- 172
- 1
- 5
- 16
1
vote
1 answer
stored procedure confusing named parameters 'Error converting data type nvarchar to int.'
Running the exact same sql command, I get an error depending on what order the parameters are defined in the stored proc. This error was originally encountered using a stored proc mapped through entity framework, but that does not seem to be the…

Derpy
- 1,458
- 11
- 15
1
vote
1 answer
How to set NHibernate named parameter like SQL Server, with the "@" character?
I want to use in NHibernate the "SQL Server template" for named parameters that is a "@" instead of the ":" ?
For example I want to use this:
select * from Users where ID = @id
instead of this:
select * from Users where ID = :id
This will be much…

Alex 75
- 2,798
- 1
- 31
- 48
1
vote
2 answers
How to build a SQL string, with values filled in, from a statement with named parameters?
I'm looking for a utility to prepare a SQL statement with named parameters and values, but not execute it. I just want the resulting SQL statement, with values substituted for named params, as a java.lang.String object. I did not find anything in…

bwfrieds
- 341
- 3
- 20
1
vote
3 answers
CakePHP - Can you make forms submit params as named params?
So GET forms make the usual urls like
.../search/?q=apple
Can you make a form create urls like
.../search/q:apple/

Temega
- 354
- 1
- 3
- 17
1
vote
1 answer
Scala 2.8 - Potential problem with named arguments
Consider the following code :
// My code
class Person(var age: Int)
// Client's code
object Main {
def main(args: Array[String]) {
val p = new Person(age = 18)
println(p.age)
}
}
Now say later I need to define an accessor method for…

missingfaktor
- 90,905
- 62
- 285
- 365
1
vote
2 answers
OleDB Parameters
I have this access db that I have a ddl for the state name and a ddl for the year. I have a gridview that I'd like to pass the value of the state drop down list into where clause. Obviously if I could use sql with the named parameters I would but…

Troy Bryant
- 994
- 8
- 29
- 60
1
vote
2 answers
How to specify named parameter value for NOT IN clause in MySQL query?
I have written the following SQL query:
$media_category_ids = array( 11, 12);
$params = array();
$sql = "SELECT `id`
FROM query
WHERE 1=1
AND WHERE query.media_category_id NOT IN (:media_category_ids)";
$params['media_category_ids'] =…

Mr B
- 3,980
- 9
- 48
- 74
1
vote
2 answers
Invoking Record Member with Optional Parameters using Named Arguments
Consider the following record definition and accompanying method:
type MyRecord = {
FieldA : int
FieldB : int
FieldC : int option
FieldD : int option
} with
static member Create(a,b,?c,?d) = {
FieldA = a
…

genericdeveloper
- 109
- 5
1
vote
1 answer
Reuse step method in Selenium
I am using common step method;
public void performAction(String actionText) {
//code to access actionText
}
Now I want to call this method in 2 ways. In the 1st case, I say;
I select action %action_text_taken_from_properties_string
Here I specify…

copenndthagen
- 49,230
- 102
- 290
- 442
1
vote
2 answers
How many parameters can be passed in a user defined function?
I'm relatively new to programming, have been working a lot in javascript, and now trying to learn php. The title basically says it. How many parameters can I pass in a user defined function?
I've noticed standard functions tend to accept different…

Eric
- 2,004
- 6
- 23
- 33
1
vote
2 answers
How can I find the missing parameters in a C# function call?
When a named parameter in a C# function is missing, the compiler only prints the number of arguments that are missing instead of printing the name of each missing parameter in the function:
prog.cs(10,27): error CS1501: No overload for method…

Anderson Green
- 30,230
- 67
- 195
- 328