title: SQL Error [500310] [42703]: [Amazon](500310) Invalid operation: column "engagement_time_msec" does not exist in events_20180626_temp;
body: <p>I am making this query </p>
  
  <pre><code>SELECT event_params FROM public.events_20180626_temp where event_name='user_engagement';
  </code></pre>
  
  <p>and It gives correct out as below.</p>
  
  <pre><code>{"firebase_screen_class": "SplashScreenActivity", "firebase_event_origin": "auto", "firebase_screen_id": "7757319118664517009", "engagement_time_msec": "3804"}
  {"firebase_screen_class": "BaseActivity", "firebase_event_origin": "auto", "firebase_screen_id": "-8308759841787556451", "engagement_time_msec": "5184"}
  {"firebase_screen_class": "SplashScreenActivity", "firebase_event_origin": "auto", "firebase_screen_id": "5605799982713019219", "engagement_time_msec": "2976"}
  {"firebase_screen_class": "CreateTaleActivity", "firebase_event_origin": "auto", "firebase_screen_id": "5605799982713019221", "engagement_time_msec": "46937"}
  {"firebase_screen_class": "TaleLocationActivity", "firebase_event_origin": "auto", "firebase_screen_id": "5605799982713019223", "engagement_time_msec": "2952"}
  {"firebase_screen_class": "TalePhotoEditorActivity", "firebase_event_origin": "auto", "firebase_screen_id": "5605799982713019228", "engagement_time_msec": "2295"}
  {"firebase_screen_class": "BaseActivity", "firebase_event_origin": "auto", "firebase_screen_id": "5605799982713019220", "engagement_time_msec": "10664"}
  </code></pre>
  
  <p>When I am changing query to extract the value of the key "engagement_time_msec" it says <code>engagement_time_msec</code> doesn't exists in the table. Here is the query for that.</p>
  
  <pre><code>select json_extract_path_text(event_params, "engagement_time_msec") from public.events_20180626_temp where event_name='user_engagement';
  </code></pre>
  
  <p>I confirmed if <code>event_params</code> column contains valid json string using the query below.</p>
  
  <p><code>select is_valid_json(event_params) from public.events_20180626_temp;</code></p>
  
  <p>It returned <code>true</code> for each row.</p>
  
  <pre><code>true
  true
  true
  true
  true
  true
  </code></pre>
  
  <p>Can anybody help me out here?. I am totally new to redshift. Thanks.</p>
  
  <p>FYI data type of column <code>event_params</code> is  <code>varchar(65553)</code></p>