2

I am a newbie to Pervasive and I am trying to fetch all records from Patient table where the Date of birth of Patient is not '11/30/0002'

The Birthdate is stored in MM/DD/YYYY format in the system

Requesting your assistance

Mayur K
  • 21
  • 2

1 Answers1

2

If the field is defined as a date, then you can use the standard format to restrict the data. For example:

select * from Patient where birthdate <> '0002-11-30'

The date format YYYY-MM-DD. If it's not in that format, you can convert it using various functions. For example:

select right('06/05/1995',4) + '-'  + substring('06/05/1995',4,2) + '-' + left('06/05/1995', 2)
mirtheil
  • 8,952
  • 1
  • 30
  • 29