I am using this code and it works. The truth is I don't know how to rewrite it more efficiently without goto. I personally think that using goto (new in php) is OK in this case, but other people are telling me that it's not ok. How should I rewrite my code without goto? Why do you think that my code is bad wth goto? I am not experienced programmer so any advice what am I doing wrong is appreciated.

```
    check_process:
    $random_code = substr(number_format(time() * rand(),0,'',''),0,10);

    $unique_check = $wpdb->get_var(
      "SELECT meta_id 
      FROM {$wpdb->postmeta} 
      WHERE meta_key = 'unique_code' 
      AND meta_value = '{$random_code}' 
      LIMIT 1"
    );

    if ($unique_check == NULL) {
       // OK
    }
    else {
        goto check_process; // go back and generate another unique code if are same
    }

```