I would benefit from more detail (like code and example data). I'm not sure how the "where" restriction fits in. If it's a mixed model, then you might want to consider random coefficients. Until more detail is available...
If you incorporate visits as continuous then (by default and depending on details), you are fitting a linear regression of the outcome on visit. This would be a somewhat crude assessment of trend that assumes linearity. Of course, with only 3 visits, it could be hard to assess the validity of the linearity assumption, and a "crude" assessment might just fine. I've taken this approach before and been comfortable with it.
You might find the SAS Statistical Procedures to be a better forum for this question. I have the (recently acquired) power to move your post, but I've never done that before. Let me know if you'd like me to (try to) move it 🙂