Jump to content
Sign in to follow this  
Hiral

Help in SQL query

Recommended Posts

Hello Everyone,

I am writing a query in SQL to pull the first date an employee became a teacher with no break in service.  using the job table here to find effective date when a employee became teacher like example.

1. Teacher - 1/1/18.

2. coordinator- 2/1/18

3. Teacher- 3/1/18

Here in result I need the last entry as there is no gap in that title now.

Share this post


Link to post
Share on other sites

I don't think you can do that with a basic query, maybe a stored procedure would work or else you would need to get all of the results and use another language to go through the data.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

×
×
  • Create New...