Posts
 
Reputation
Joined
Last Seen
0 Reputation Points
Unknown Quality Score

No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.

0 Endorsements
~3K People Reached
Favorite Forums
Favorite Tags
mssql x 24
Member Avatar for Link82

Hey Everyone, So after weeks of torture, this things is near completion. We're using SSRS to display the report on the .NET side. However, I'm piecing together the last bits of the SQL query. So, I have three tables. One has names of all these buildings, one has contains reason_codes, …

Member Avatar for sknake
0
159
Member Avatar for Link82

Hey everyone, I'm working on something ridiculously convoluted right now and am so close to finishing, hopefully I can get some proper help here. I have my base table, as so: [CODE] -- Insert statements for procedure here CREATE TABLE #starter ( emplid char(6), acct_code char(128), div char(3), payroll_sect char(3), …

Member Avatar for Link82
0
130
Member Avatar for Link82

Hi everyone, So I need to find out if a date entered is a Sunday. If it is, I gotta do something special with this data. I'm not sure if Datepart will help or how to use it effectively to extract if it's a Sunday or if it's 1st day …

Member Avatar for sknake
0
116
Member Avatar for Link82

Hi All, Re-doing a giant, old, crusty sp. So here's a questions for all of you. I have two temp tables: #temp_acct_codes and #temp_hour_tracker. #temp_acct_codes contains these two columns in addition to a slew of others: week, hours, date_worked. #temp_hour_tracker contains week, hours_already_worked, 1_0_hrs, 1_5_hrs, 2_0_hrs, diff_hrs, eper_hrs, loc (different …

Member Avatar for Link82
0
136
Member Avatar for Link82

Hi everyone, It's my first time with looping through data in a query. I know there are two ways of doing this and one is using CURSOR (I read it'snot the nicest thing to use). Wouldn't mind hearing your thoughts. I will copy and paste my first attempt at usingCURSOR …

Member Avatar for cgyrob
0
1K
Member Avatar for Link82

I have a huge stored procedure which calls other mini-ones. The problem is that I need a temp table and I'd like to avoid a real table being used as a temp one. You've probably guessed by now, but if you haven't, a table variable is created at the beginning …

Member Avatar for sknake
0
157
Member Avatar for Link82

Hi Guys, Kind of stuck on a query here. [CODE] select *--, c.last_name + ', ' + c.first_name as name from dbo.tblLevelOneApprover a inner join dbo.tblLevelTwoApproverToLevelOneApprover b on convert(int, b.level_two_emplid) != convert(int, @emplid) where convert(int, a.emplid) = convert(int, b.level_one_emplid) [/CODE] I'm trying to get all level one managers who are …

Member Avatar for Link82
0
180
Member Avatar for Link82

Hi everyone, A few days ago I posted a question which someone did reply to. However, the tables have been re-arranged a bit and I didn't want to make my last thread confusing, so I thought I'd start fresh here. (Mod, you may close down my other thread; thanks). So …

Member Avatar for sknake
0
299
Member Avatar for Link82

Hi everyone, I've never had to do this before sooo, I need help. I have a table which maps managers to regular employees. So you could say that Manager A is mapped to 20 peeople and Manager B is mapped to 5, and so on. So the table looks like …

Member Avatar for sknake
0
354