Skip to content

Commit

Permalink
chore(autocomplete): add supported types (#1826)
Browse files Browse the repository at this point in the history
  • Loading branch information
Raubzeug authored Jan 20, 2025
1 parent bb6d7be commit e99b217
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/types/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,4 +29,11 @@ export enum YQLType {
TzDate = 'TzDate',
TzDateTime = 'TzDateTime',
TzTimestamp = 'TzTimestamp',
Date32 = 'Date32',
Datetime64 = 'Datetime64',
Timestamp64 = 'Timestamp64',
Interval64 = 'Interval64',
TzDate32 = 'TzDate32',
TzDatetime64 = 'TzDatetime64',
TzTimestamp64 = 'TzTimestamp64',
}
7 changes: 7 additions & 0 deletions src/utils/monaco/yql/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,13 @@ export const SimpleTypes = [
'Datetime',
'Timestamp',
'Interval',
'Date32',
'Datetime64',
'Timestamp64',
'Interval64',
'TzDate32',
'TzDatetime64',
'TzTimestamp64',
'Null',
'Int8',
'Uint8',
Expand Down
7 changes: 7 additions & 0 deletions src/utils/query.ts
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,13 @@ export const getColumnType = (type: string) => {
case YQLType.TzDate:
case YQLType.TzDateTime:
case YQLType.TzTimestamp:
case YQLType.Date32:
case YQLType.Datetime64:
case YQLType.Timestamp64:
case YQLType.Interval64:
case YQLType.TzDate32:
case YQLType.TzDatetime64:
case YQLType.TzTimestamp64:
return 'date';
default:
return undefined;
Expand Down

0 comments on commit e99b217

Please sign in to comment.