Pipeline
Perform the pipeline of creating an insert statement. The 'insertee' is the case class on which the SQL insert statement is based. The schema is based on the EntityQuery which could potentially be an unquoted QuerySchema.
Attributes
- Graph
-
- Supertypes
Members list
Type members
Classlikes
Is the assignment list know at compile time or only runtime?
Is the assignment list know at compile time or only runtime?
Attributes
- Supertypes
-
trait Enumtrait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
- Known subtypes
-
case Static
Attributes
- Supertypes
-
class Objecttrait Matchableclass Any
- Self type
-
IgnoredColumns.type
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
Inherited classlikes
Attributes
- Inherited from:
- QuatMakingBase
- Supertypes
-
class Objecttrait Matchableclass Any
Value members
Concrete methods
Note that the only reason Parser is needed here is to pass it into parseInsertee. The batch pipeline driven by createFromPremade currently doesn't need it.
Note that the only reason Parser is needed here is to pass it into parseInsertee. The batch pipeline driven by createFromPremade currently doesn't need it.
Attributes
Create a static or dynamic quotation based on the state. Wrap the expr using some additional functions if we need to. This is used for the createFromPremade if we need to wrap it into insertReturning which is used for batch-returning query execution.
Create a static or dynamic quotation based on the state. Wrap the expr using some additional functions if we need to. This is used for the createFromPremade if we need to wrap it into insertReturning which is used for batch-returning query execution.
Attributes
Actually the same as deduceAssignmentsFromCaseClass, but I decided to write a separate function and comment it extensively since the logic is not simple to extrapolate. This function creates a series of assignments of a elaborated product. However, each assignment just assigns to the identifier which will be plugged in (i.e. BetaReduced) once the Ident is actually substituted. E.g. if we have something like this: val ip = quote { (p: Person) => query[Person].insertValue(p) }
and then later: run(ip(lift(Person("Joe",123))))
then the assignments list is just based on the p
identifier of the ip
quoted function i.e: (v:Person) => v.firstName -> p.firstName
this is achived by doing BetaReduce(v.firstName, v -> p). Later on when ip(lift(Person("Joe",123)))
happens the CaseClass(firstName -> lift(...), age -> lift(...))
comes in and all the right values are plugged in correctly.
Actually the same as deduceAssignmentsFromCaseClass, but I decided to write a separate function and comment it extensively since the logic is not simple to extrapolate. This function creates a series of assignments of a elaborated product. However, each assignment just assigns to the identifier which will be plugged in (i.e. BetaReduced) once the Ident is actually substituted. E.g. if we have something like this: val ip = quote { (p: Person) => query[Person].insertValue(p) }
and then later: run(ip(lift(Person("Joe",123))))
then the assignments list is just based on the p
identifier of the ip
quoted function i.e: (v:Person) => v.firstName -> p.firstName
this is achived by doing BetaReduce(v.firstName, v -> p). Later on when ip(lift(Person("Joe",123)))
happens the CaseClass(firstName -> lift(...), age -> lift(...))
comes in and all the right values are plugged in correctly.
Attributes
Inserted object can either be static: query[Person]insertValue(Person("Joe", "Bloggs")) or it can be lifted: query[Person].insertValue(lift(Person("Joe", "Bloggs")))
Inserted object can either be static: query[Person]insertValue(Person("Joe", "Bloggs")) or it can be lifted: query[Person].insertValue(lift(Person("Joe", "Bloggs")))
In the later case, it will become: {{ //Assuming x := Person("Joe", "Bloggs") CaseClassLift( Quoted(ast: CaseClass(name -> lift(idA)), ...), lifts: List(EagerLift(x.name, idA), ...)) ) }}
For batch queries liftQuery(people).foreach(p => query[Person].insertValue(p)) it will be just the ast Ident("p")
Attributes
Parse the input to of query[Person]insertValue(Person("Joe", "Bloggs")) into CaseClass(firstName="Joe",lastName="Bloggs")
Parse the input to of query[Person]insertValue(Person("Joe", "Bloggs")) into CaseClass(firstName="Joe",lastName="Bloggs")
Attributes
Get assignments from an entity and then either exclude or include them either statically or dynamically.
Get assignments from an entity and then either exclude or include them either statically or dynamically.
Attributes
Inherited methods
Attributes
- Inherited from:
- QuatMakingBase
Attributes
- Definition Classes
- Inherited from:
- QuatMaking