Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion apis/cqn.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ export type SELECT = { SELECT: {
having?: predicate,
orderBy?: ordering_term[],
limit?: { rows: val, offset: val },
forUpdate?: { wait: number },
forUpdate?: { wait: number, ignoreLocked: boolean },
forShareLock?: { wait: number },
search?: predicate,
count?: boolean,
Expand Down
2 changes: 1 addition & 1 deletion apis/ql.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ export class SELECT<T, Q = SELECT_from> extends ConstructedQuery<T> {

forShareLock (): this

forUpdate ({ wait }?: { wait?: number }): this
forUpdate({ wait, ignoreLocked }?: { wait?: number, ignoreLocked?: boolean }): this

alias (as: string): this
elements: EntityElements
Expand Down
1 change: 1 addition & 0 deletions test/typescript/apis/project/cds-cqn.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ res = sqn.SELECT.limit
res = sqn.SELECT.mixin
res = sqn.SELECT.forShareLock?.wait
res = sqn.SELECT.forUpdate?.wait
res = sqn.SELECT.forUpdate?.ignoreLocked
res = sqn.SELECT.search?.at(0)
testType<boolean | undefined>(sqn.SELECT.count)

Expand Down
1 change: 1 addition & 0 deletions test/typescript/apis/project/cds-ql.ts
Original file line number Diff line number Diff line change
Expand Up @@ -275,6 +275,7 @@ DELETE.from `${x}` .where `ID=${x}`

SELECT.from(Foos).forUpdate()
SELECT.from(Foos).forUpdate({wait: 5})
SELECT.from(Foos).forUpdate({ignoreLocked: true})
SELECT.from(Foos).forShareLock()

INSERT.into('Foos').values(1,2,3)
Expand Down