Skip to content

Commit

Permalink
more type changes, test not actually fixed :/
Browse files Browse the repository at this point in the history
  • Loading branch information
mitchwadair committed Dec 18, 2024
1 parent 251dea3 commit 5cb0fc6
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
3 changes: 1 addition & 2 deletions drizzle-orm/src/singlestore-core/columns/vector.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,8 @@ export type SingleStoreVectorBuilderInitial<TName extends string> = SingleStoreV
dataType: 'array';
columnType: 'SingleStoreVector';
data: Array<number>;
driverParam: Array<number>;
driverParam: string;
enumValues: undefined;
generated: undefined;
}>;

export class SingleStoreVectorBuilder<T extends ColumnBuilderBaseConfig<'array', 'SingleStoreVector'>>
Expand Down
4 changes: 2 additions & 2 deletions drizzle-orm/src/singlestore-core/expressions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,10 @@ export function substring(
}

// Vectors
export function dotProduct(column: SingleStoreColumn | SQL.Aliased, value: Array<number>) {
export function dotProduct(column: SingleStoreColumn | SQL.Aliased, value: Array<number>): SQL {
return sql`${column} <*> ${JSON.stringify(value)}`;
}

export function euclideanDistance(column: SingleStoreColumn | SQL.Aliased, value: Array<number>) {
export function euclideanDistance(column: SingleStoreColumn | SQL.Aliased, value: Array<number>): SQL {
return sql`${column} <-> ${JSON.stringify(value)}`;
}

0 comments on commit 5cb0fc6

Please # to comment.