Meeting Title: Greenforged Revenue Calculation Working Session Date: 2025-11-06 Meeting participants: Demilade Agboola, Emily Giant


WEBVTT

1 00:03:15.550 00:03:16.690 Emily Giant: Hello!

2 00:03:21.680 00:03:22.880 Demilade Agboola: Hello, how are you?

3 00:03:23.720 00:03:26.070 Emily Giant: Oh, I am fine. How are you?

4 00:03:26.700 00:03:31.779 Demilade Agboola: I’m doing alright. I have been cracking at this, and I think I’ve, like.

5 00:03:31.900 00:03:33.600 Demilade Agboola: Being able to figure out what’s going on.

6 00:03:34.120 00:03:38.179 Emily Giant: let… let’s see it. And then I can run my PR by you, because…

7 00:03:38.910 00:03:44.910 Emily Giant: I feel like it looks bigger than it is, and it’ll be easier to explain, but let’s… let’s get crackin’.

8 00:03:48.020 00:03:52.740 Demilade Agboola: Okay, give me one second… Does the…

9 00:03:53.390 00:03:55.280 Demilade Agboola: For some reason, my screen went off.

10 00:03:56.390 00:03:57.909 Demilade Agboola: Like, my second screen went, so…

11 00:03:58.690 00:03:59.410 Emily Giant: Hmm.

12 00:03:59.650 00:04:00.859 Demilade Agboola: Okay, it’s back up now.

13 00:04:01.160 00:04:01.780 Emily Giant: Okay.

14 00:04:02.830 00:04:04.310 Demilade Agboola: Alright,

15 00:04:06.690 00:04:15.329 Demilade Agboola: I have been testing, I’ve made a bunch of changes, and I’m committing and syncing. But, like, the major change I’ve made right now is…

16 00:04:15.590 00:04:22.049 Demilade Agboola: I figured out that What was happening with some of the orders.

17 00:04:22.450 00:04:29.140 Demilade Agboola: Alright, so, how do I put it? So, we had our test order, which I believe was this. This was the order.

18 00:04:29.370 00:04:40.469 Demilade Agboola: And we’re like, oh… I think right now, that’s fine. If I look at… dot, select…

19 00:04:41.660 00:04:51.840 Demilade Agboola: All from dbt Greenforged, or… orders were Shopify…

20 00:04:53.390 00:04:59.540 Demilade Agboola: dot ID, of course, like, this… That’s…

21 00:04:59.540 00:05:01.210 Emily Giant: OMS order ID, isn’t it?

22 00:05:02.360 00:05:05.960 Emily Giant: Yeah, but I think at this point… Oh, my God.

23 00:05:05.960 00:05:13.649 Demilade Agboola: When it’s all together, the OMS order ID is still technically… like, even in Shopify, if you go there, you can kind of still see it.

24 00:05:13.810 00:05:14.540 Emily Giant: Okay.

25 00:05:15.250 00:05:16.090 Demilade Agboola: Stop.

26 00:05:16.280 00:05:21.579 Demilade Agboola: But there’s also a flag for the system it’s coming from, I believe.

27 00:05:21.760 00:05:22.470 Emily Giant: Okay.

28 00:05:23.910 00:05:26.099 Demilade Agboola: Yeah, so you can also still see the shop pry.

29 00:05:33.590 00:05:41.889 Demilade Agboola: Oh, I was looking… alright, so in this case, yeah, we’re 318, so that’s fine. It’s fine for this use case.

30 00:05:41.890 00:05:42.430 Emily Giant: Yeah.

31 00:05:42.580 00:05:48.099 Demilade Agboola: So this use case… Believe it or not, it’s actually a very simple use case.

32 00:05:49.360 00:05:54.929 Demilade Agboola: Right? Because all that is canceled is canceled, all that is delivered is delivered.

33 00:05:55.710 00:06:03.229 Demilade Agboola: these use cases is where things get really funny. So, upfront, what’s happening here is there was something delivered

34 00:06:04.000 00:06:04.690 Demilade Agboola: Okay?

35 00:06:05.670 00:06:09.650 Demilade Agboola: And then there was a re-delivery of this, which was possible.

36 00:06:09.870 00:06:11.140 Emily Giant: Great.

37 00:06:11.470 00:06:13.200 Demilade Agboola: And then the Aussie delivery.

38 00:06:13.460 00:06:20.619 Demilade Agboola: Again, of this, it’s one console, and one… And we delivered, right?

39 00:06:21.460 00:06:23.640 Demilade Agboola: Because here is the tricky part.

40 00:06:25.610 00:06:28.280 Demilade Agboola: The customer only paid $85.

41 00:06:30.630 00:06:31.240 Demilade Agboola: Oh.

42 00:06:32.110 00:06:35.730 Demilade Agboola: I guess that that’s what I’m trying to get to.

43 00:06:36.890 00:06:39.160 Demilade Agboola: Because… So what I’m trying to do…

44 00:06:39.160 00:06:39.810 Emily Giant: useful.

45 00:06:40.990 00:06:45.360 Emily Giant: Sorry, go ahead, but I feel like… This will fix itself.

46 00:06:45.810 00:06:53.629 Emily Giant: In that there’s an overwrite in OMS CompEXF, or the new one, rather, that sets the re-delivery to zero.

47 00:06:55.030 00:06:59.619 Demilade Agboola: Yes, but remember that redistribution happens separately.

48 00:06:59.830 00:07:00.979 Emily Giant: That is true.

49 00:07:01.350 00:07:09.440 Demilade Agboola: So that’s what I’ve… that’s what I started doing now. So I have been able to over… get the override model of CT in here.

50 00:07:09.700 00:07:14.810 Demilade Agboola: And what I’m trying to do… it’s getting closer, but it’s not finally there.

51 00:07:15.110 00:07:16.650 Demilade Agboola: Because the weight…

52 00:07:16.920 00:07:24.470 Demilade Agboola: It’s part of what I’ve been looking at. But what… where I’m at right now is a point where…

53 00:07:24.990 00:07:27.419 Demilade Agboola: For this stat order that we saw.

54 00:07:28.830 00:07:34.750 Demilade Agboola: I’m able to see that, hey, there’s re-delivery.

55 00:07:36.040 00:07:39.340 Demilade Agboola: I wanted to be able to say, hey, because what’s happening now is…

56 00:07:39.930 00:07:42.490 Demilade Agboola: My thoughts are a bit all over the place, give me one second.

57 00:07:42.830 00:07:43.470 Emily Giant: I’m good.

58 00:07:43.970 00:07:46.140 Demilade Agboola: Alright, so what’s happening now is…

59 00:07:50.740 00:07:58.710 Demilade Agboola: because it’s… the author ID, I think it’s because it’s weighing on the…

60 00:07:58.930 00:08:06.600 Demilade Agboola: Gee, give me one second. Because right now, what’s happening here is I need it to be able to say the weight of this is 1,

61 00:08:07.290 00:08:13.270 Demilade Agboola: And the weight of what was accrued is 85, so it’s… the 85 should be assigned to this.

62 00:08:13.850 00:08:17.990 Demilade Agboola: But because there were two things delivered, I needed to be able to say, hey.

63 00:08:22.960 00:08:32.570 Emily Giant: Yeah, I see what’s happening. It’s that in more recent history, accrued revenue will show zero for forced upgrades, but for some reason.

64 00:08:32.980 00:08:38.949 Emily Giant: Here, it’s actually pulling The money into accrued revenue.

65 00:08:39.390 00:08:40.220 Demilade Agboola: Yeah.

66 00:08:40.549 00:08:43.049 Demilade Agboola: But, like, before, it was using…

67 00:08:43.190 00:08:49.190 Demilade Agboola: But it was… it had received, like, 85.

68 00:08:50.370 00:08:57.940 Demilade Agboola: Because what was delivered was 95, and what was also, like, initially delivered. Because remember, two things were actually delivered.

69 00:08:58.220 00:08:59.590 Demilade Agboola: put into this

70 00:08:59.760 00:09:08.700 Demilade Agboola: Actually, it was saying, you know, 95… 95 delivery, so before yesterday.

71 00:09:08.920 00:09:18.090 Demilade Agboola: I made that fix, that’s why I texted you. It was saying the delivery… the total cost of this one was 185, basically.

72 00:09:18.400 00:09:19.240 Demilade Agboola: 8.

73 00:09:19.650 00:09:20.510 Demilade Agboola: you know.

74 00:09:21.300 00:09:28.590 Demilade Agboola: But that was obviously not true, because I only paid 90,

75 00:09:30.940 00:09:34.250 Demilade Agboola: Again, it should be… 95.

76 00:09:34.460 00:09:35.769 Demilade Agboola: I’m almost there.

77 00:09:36.430 00:09:39.900 Demilade Agboola: what I’ve done now is I am tweaking

78 00:09:42.420 00:09:47.900 Demilade Agboola: the accrued revenue. It’s right down… it’s saying the revenue is 91.

79 00:09:48.460 00:09:53.179 Demilade Agboola: Or 5 off, so I’m trying to basically get that last $5.

80 00:09:53.530 00:09:54.419 Demilade Agboola: But yes.

81 00:09:54.420 00:09:57.239 Emily Giant: Places where there are cancellations and re-deliveries.

82 00:09:57.530 00:10:02.439 Demilade Agboola: Yeah, that’s kind of… yeah, it gets weird, so that’s kind of what I’m trying to… I’m almost there.

83 00:10:02.440 00:10:08.570 Emily Giant: Where do you do the re-delivery overwrite? Because I think where it has to happen is in accrued revenue.

84 00:10:09.320 00:10:18.810 Emily Giant: is the CTE with accrued revenue getting calculated? So that looks like what you’re doing, because that way, the re-delivery, if it assigns it a cost.

85 00:10:19.120 00:10:29.410 Emily Giant: Or if it assigns a forced upgrade slash re-delivery, or whatever, a cost, it’s zero, as… but that’s what you’re doing.

86 00:10:29.410 00:10:32.390 Demilade Agboola: Yeah, so basically what the delivery is not known.

87 00:10:33.660 00:10:38.040 Demilade Agboola: Right? And it’s where delivery occurs, basically, that is…

88 00:10:39.770 00:10:41.849 Emily Giant: And then, I think there needs to.

89 00:10:41.850 00:10:42.369 Demilade Agboola: It’s a grandmother.

90 00:10:42.370 00:10:44.130 Emily Giant: Condition of deleted.

91 00:10:45.340 00:10:48.329 Emily Giant: Wait, no, because deleted is how we get the accrued revenue.

92 00:10:51.740 00:10:56.830 Demilade Agboola: Yeah, so what I’m not doing here is… But when it’s deleted, though.

93 00:10:58.320 00:11:01.920 Demilade Agboola: It’s the adjusted accrued Revenue.

94 00:11:06.030 00:11:07.170 Demilade Agboola: Else it’s zero.

95 00:11:07.800 00:11:15.079 Demilade Agboola: Basically, so when it’s not deleted, it’s the adjusted accrued Revenue. And the idea now is when we now use the adjusted accrued Revenue, so basically.

96 00:11:15.920 00:11:19.069 Demilade Agboola: This is… It’s deleted.

97 00:11:19.500 00:11:24.120 Demilade Agboola: But, like, think… so think about it this way. I’m taking only the accurate revenue.

98 00:11:24.970 00:11:28.759 Demilade Agboola: itself, where… But people… where it’s…

99 00:11:29.510 00:11:31.849 Demilade Agboola: Where it’s not a re-delivery, right?

100 00:11:32.130 00:11:32.780 Emily Giant: Right.

101 00:11:33.140 00:11:39.330 Demilade Agboola: So, in that case, in this order, it would be the two other… so the 85 and the 95.

102 00:11:40.640 00:11:41.610 Demilade Agboola: I believe.

103 00:11:43.000 00:11:43.950 Demilade Agboola: Yes.

104 00:11:43.950 00:11:47.369 Emily Giant: Where… so the other 95 is coming from a forced upgrade, right?

105 00:11:47.590 00:11:49.480 Emily Giant: Because the re-delivery is fixed.

106 00:11:49.930 00:11:51.370 Emily Giant: Yes, not…

107 00:11:51.370 00:11:53.759 Demilade Agboola: We need a forced upgrade flag.

108 00:11:56.910 00:12:04.029 Emily Giant: I didn’t foresee, because in the future, those come in as zero. But because this is 2020,

109 00:12:04.160 00:12:19.680 Emily Giant: it’s not coming in as zero. Like, the other order we were looking at that has a lot of the same issues, if you look at the forced upgrade lines in the accrued revenue, they’re all 0 in the source.

110 00:12:22.030 00:12:31.680 Emily Giant: So, it’s the whole, like, line item has strikethrough. So there’s an element of… that is deleted.

111 00:12:34.860 00:12:39.840 Emily Giant: Because the $85 was deleted, and that’s what they paid, so that’s why…

112 00:12:40.540 00:12:41.440 Demilade Agboola: You know, but like…

113 00:12:41.440 00:12:44.870 Emily Giant: Yeah, I know what you’re saying, I’m just, like, thinking out loud.

114 00:12:45.030 00:12:48.840 Demilade Agboola: It was… it was… Deleted.

115 00:12:51.780 00:12:58.999 Emily Giant: But that’s what accrued revenue is. It’s like, this is what the customer paid. And they did not pay $95 for that thing that was added.

116 00:12:59.690 00:13:02.700 Demilade Agboola: I mean, certainly dip in IC5, if you include the…

117 00:13:02.700 00:13:03.560 Emily Giant: Yeah, with the…

118 00:13:03.630 00:13:12.769 Demilade Agboola: the shipping cost. Yeah, so it is 95, to be fair. So, like I said, it’s, like, it’s 90, it’s not off by much.

119 00:13:13.250 00:13:13.799 Emily Giant: Not at all.

120 00:13:13.800 00:13:14.250 Demilade Agboola: But, like.

121 00:13:14.770 00:13:15.360 Demilade Agboola: But…

122 00:13:15.590 00:13:22.129 Demilade Agboola: I obviously wanted to get us to that point, but I also looked at another one, so this one says 68.

123 00:13:23.160 00:13:25.339 Demilade Agboola: Plus 10, so it should be 78.

124 00:13:25.520 00:13:29.819 Demilade Agboola: It’s against a quite similar situation, where… pairs, too.

125 00:13:30.100 00:13:32.509 Emily Giant: That never got delivered. And then…

126 00:13:32.720 00:13:38.260 Emily Giant: There’s a re-delivery, and it’s still counting the money of the forced upgrade on the re-delivery.

127 00:13:38.830 00:13:41.870 Demilade Agboola: Yes. So this should be 78th.

128 00:13:42.670 00:13:46.909 Emily Giant: I wonder why it’s doing that, because, like, that should be…

129 00:13:47.180 00:13:49.930 Emily Giant: Zeroed out because it’s a re-delivery.

130 00:13:52.280 00:13:53.720 Emily Giant: You know what I mean?

131 00:13:54.290 00:14:01.490 Emily Giant: like… Why is it counting any revenue from that re-delivery, whether it was forced upgraded or not?

132 00:14:05.740 00:14:08.929 Demilade Agboola: So this is 63, so again, this is, like, slightly lower.

133 00:14:09.470 00:14:11.280 Demilade Agboola: And this, which is…

134 00:14:12.620 00:14:13.919 Emily Giant: 68, I think.

135 00:14:17.040 00:14:18.940 Demilade Agboola: Or some T-finger shipping to it.

136 00:14:18.940 00:14:19.610 Emily Giant: Yeah.

137 00:14:20.550 00:14:24.320 Demilade Agboola: I’m trying to get it to the point where it’s not.

138 00:14:25.090 00:14:30.600 Emily Giant: What in the world? It’s just odd, right? Like, why…

139 00:14:31.150 00:14:38.000 Emily Giant: Okay, so what does it say is the fulfilled revenue 63 accrued? That makes sense.

140 00:14:38.170 00:14:47.570 Emily Giant: What… if you pull the… CTE just for the accrued And the… the total revenues.

141 00:14:47.840 00:14:49.360 Emily Giant: What does it say?

142 00:14:51.270 00:14:52.400 Demilade Agboola: Okay, just like this.

143 00:14:53.370 00:14:54.040 Demilade Agboola: Thanks, Carmen.

144 00:14:54.040 00:14:54.830 Emily Giant: Yeah.

145 00:14:55.890 00:14:59.919 Emily Giant: I’m just trying to see where it’s… Deciding to be weird.

146 00:15:00.470 00:15:05.420 Emily Giant: Because, to me, your logic… mixed… perfect sense.

147 00:15:06.920 00:15:08.600 Demilade Agboola: I take this…

148 00:15:16.780 00:15:17.214 Demilade Agboola: Unbelievable

149 00:15:31.030 00:15:32.000 Demilade Agboola: I think so.

150 00:15:58.240 00:16:00.659 Emily Giant: One second, I’m going to grab my carafe of coffee.

151 00:16:01.380 00:16:02.249 Demilade Agboola: It’s all good.

152 00:16:43.630 00:16:46.960 Emily Giant: Okay, so that’s… oh, it’s the adjusted accrued revenue.

153 00:16:48.850 00:16:54.809 Emily Giant: So I think the adjusted accrued revenue… did you work in the re-delivery stuff to that one, too?

154 00:16:56.500 00:17:04.079 Demilade Agboola: The adjusted occurred revenue. So, in this case, B…

155 00:17:08.800 00:17:11.780 Demilade Agboola: Can I zero… would I be zeroing out the…

156 00:17:12.829 00:17:20.559 Emily Giant: Yeah, because you want it to be $0, right? The… the adjusted accrued revenue should be… .

157 00:17:20.560 00:17:21.259 Demilade Agboola: It was.

158 00:17:22.000 00:17:24.760 Emily Giant: The re-delivery should be part of that, too.

159 00:17:25.069 00:17:25.990 Demilade Agboola: So the…

160 00:17:26.740 00:17:27.789 Emily Giant: Sorry, go ahead.

161 00:17:28.400 00:17:31.219 Demilade Agboola: Okay, so this is saying where it’s not deleted.

162 00:17:31.430 00:17:32.150 Emily Giant: Hmm.

163 00:17:33.350 00:17:35.679 Demilade Agboola: Gotcha. Alright, so let’s try that.

164 00:17:36.170 00:17:36.600 Emily Giant: Yeah.

165 00:17:36.600 00:17:38.760 Demilade Agboola: Let me see what happens when…

166 00:17:39.860 00:17:44.539 Emily Giant: God, this data… I wish it didn’t, like, change so much over time.

167 00:17:44.670 00:17:51.140 Emily Giant: It’s… what… so I talked to Alex yesterday, as an aside, like, talking about the,

168 00:17:51.560 00:17:58.720 Emily Giant: I was trying to align line items in, Shopify, 2…

169 00:17:59.280 00:18:08.909 Emily Giant: OMS, HEVO data, and I was like, this is only getting populated, like, a third of the time, and this is what I need to, like, tie revenue to,

170 00:18:09.340 00:18:16.580 Emily Giant: to issues. And he was like, no one ever created that row. Hivo just made it on its own. And I was like, oh…

171 00:18:17.060 00:18:22.890 Emily Giant: Great. Okay. Like, at some point during the migration, Hivo just popped a new…

172 00:18:23.330 00:18:28.560 Emily Giant: Column into the table that is… sometimes accurate.

173 00:18:29.020 00:18:31.990 Emily Giant: So I have to, like, redo some of that, but he told me how.

174 00:18:32.710 00:18:34.880 Emily Giant: But, like, Hivo just changes shit.

175 00:18:35.110 00:18:36.130 Emily Giant: It’s great.

176 00:18:43.070 00:18:45.160 Demilade Agboola: Romeo should be…

177 00:18:49.120 00:18:53.170 Demilade Agboola: Let me see, what do I use the total adjusted revenue?

178 00:18:53.860 00:18:56.039 Emily Giant: In the… yeah, in the weight.

179 00:18:56.690 00:19:00.460 Demilade Agboola: Yeah, but then… The item weight…

180 00:19:19.740 00:19:26.070 Demilade Agboola: I don’t know what’s going on. It was… the screen seems to not be responding, so it’s okay.

181 00:19:27.620 00:19:29.770 Demilade Agboola: That was weird for a brief second.

182 00:19:30.380 00:19:32.370 Emily Giant: Yeah, even Redshift has been, like.

183 00:19:32.540 00:19:34.299 Emily Giant: just give up, guys. Just give up.

184 00:19:36.830 00:19:39.000 Demilade Agboola: Vick, don’t you have other things to do?

185 00:19:40.870 00:19:47.180 Emily Giant: It’s like… Like, inching your tennis racket towards you. Like, just go outside.

186 00:19:49.780 00:19:51.579 Demilade Agboola: I play tennis tomorrow, we’ll see.

187 00:19:51.590 00:19:52.680 Emily Giant: Nice.

188 00:19:53.320 00:20:02.899 Demilade Agboola: a bit… like, it’s, like, in the 50s, like, high 50s, though, but it’s, like, 50s here, so… not, like, tennis weather, but we’ll make it work.

189 00:20:03.250 00:20:04.739 Emily Giant: 50s Fahrenheit?

190 00:20:04.990 00:20:05.440 Demilade Agboola: association.

191 00:20:05.440 00:20:06.910 Emily Giant: like, dead, right? Like.

192 00:20:06.910 00:20:11.319 Demilade Agboola: Oh yeah, Celsius, if it was 50 degrees Celsius, that’s like Sahara temperatures.

193 00:20:11.320 00:20:14.639 Emily Giant: Yeah. You wouldn’t be playing tennis in that.

194 00:20:15.220 00:20:16.030 Demilade Agboola: I’m trying to get water out.

195 00:20:16.030 00:20:22.329 Emily Giant: Probably would, but… Okay, did it do anything, or is it still…

196 00:20:23.320 00:20:29.940 Demilade Agboola: Alright, so I think what I’m trying to say is that this is where… Because…

197 00:20:32.660 00:20:35.120 Emily Giant: So, some case when COS is deleted…

198 00:20:35.120 00:20:39.930 Demilade Agboola: The reason why I… But I was trying to exclude deliveries.

199 00:20:40.320 00:20:41.950 Demilade Agboola: By forcing it to zero.

200 00:20:42.860 00:20:44.150 Demilade Agboola: But then…

201 00:20:47.840 00:20:51.740 Demilade Agboola: I’m trying to think of, like, an institution like this. Give me a second…

202 00:20:53.430 00:20:54.150 Emily Giant: Yeah.

203 00:20:54.930 00:20:56.200 Emily Giant: That makes sense.

204 00:20:56.200 00:20:59.949 Demilade Agboola: Are we now going to… so, like, I’m thinking of, like, if it’s zero…

205 00:21:02.230 00:21:09.240 Demilade Agboola: Don’t we still want to split what was delivered…

206 00:21:10.090 00:21:13.149 Demilade Agboola: Like, the revenue that was delivered across.

207 00:21:15.820 00:21:24.550 Emily Giant: Yeah, you want to put… yeah, I hear what you’re saying. Like, we want the revenue, even if it was a re-delivery, to be associated with the item that was actually delivered.

208 00:21:24.790 00:21:33.080 Demilade Agboola: Exactly. So that’s kind of why I only zeroed out the actual… The actual, like.

209 00:21:33.250 00:21:39.610 Demilade Agboola: From… actually, from the revenue calculation, so the total accrued revenue, it should not count, basically.

210 00:21:39.990 00:21:46.780 Demilade Agboola: But from this, I didn’t want to exclude it, because I knew that, like, when it comes to, like, weighing the weight.

211 00:21:47.200 00:21:53.320 Demilade Agboola: of this, I wanted us to be able to still look at what… how much was… crude.

212 00:21:54.020 00:21:56.419 Emily Giant: And then use that as the weight for this.

213 00:21:57.370 00:21:59.890 Emily Giant: Okay, so I’m wondering, like.

214 00:22:00.100 00:22:07.580 Emily Giant: I’m just talking out loud, I don’t know if this even makes sense. Do we need to do it in the first CTE with, like, setting

215 00:22:07.880 00:22:14.639 Emily Giant: the revenue to zero so that it’s not excluded. And that way, like, the re-delivery

216 00:22:15.240 00:22:20.280 Emily Giant: Comes through to be added with $0, but the product doesn’t get excluded.

217 00:22:21.850 00:22:24.130 Emily Giant: So, with Peace Price Price.

218 00:22:24.300 00:22:29.910 Emily Giant: in the first CTE, where I’m… Where we’re, like.

219 00:22:30.820 00:22:35.660 Emily Giant: Getting ready to add the total accrued revenue,

220 00:22:36.430 00:22:39.940 Emily Giant: I… so it’s getting complicated, because it’s like.

221 00:22:40.110 00:22:45.919 Emily Giant: we almost want it at the sub-order level, not the order level, and that would maybe make it easier, but .

222 00:22:47.230 00:22:53.470 Demilade Agboola: But we’re still, like I said, at the order level, because, like, everything comes in on that order, and say, okay, so out of this order.

223 00:22:53.680 00:22:59.640 Demilade Agboola: Effectively, what we need to spread the… the…

224 00:23:00.030 00:23:07.010 Demilade Agboola: things are… okay, so let’s… let’s just… let’s just… you know what? Well, I think we’re getting quite complicated. Let me, give me one second, let me make it simpler.

225 00:23:08.150 00:23:11.120 Demilade Agboola: Docs.

226 00:23:11.690 00:23:12.550 Demilade Agboola: Alright.

227 00:23:14.200 00:23:20.940 Demilade Agboola: So, revenue needs to be… Delivered.

228 00:23:25.220 00:23:26.250 Demilade Agboola: attempts.

229 00:23:28.390 00:23:30.650 Emily Giant: I think if you adjust the K-State.

230 00:23:30.650 00:23:31.490 Demilade Agboola: can’t be.

231 00:23:31.640 00:23:32.790 Emily Giant: Peace Price.

232 00:23:33.850 00:23:35.210 Emily Giant: That will fix it.

233 00:23:38.150 00:23:41.189 Demilade Agboola: It’s… It’s to be spread.

234 00:23:44.870 00:23:45.910 Demilade Agboola: However…

235 00:23:48.940 00:23:50.100 Demilade Agboola: Avenue.

236 00:23:50.440 00:23:55.390 Demilade Agboola: It’s only recognized… on…

237 00:23:58.720 00:24:01.830 Demilade Agboola: non… Muted.

238 00:24:05.900 00:24:06.980 Demilade Agboola: Nong.

239 00:24:07.700 00:24:08.800 Demilade Agboola: delivery.

240 00:24:10.780 00:24:13.040 Demilade Agboola: Is this fair? Like, is fair, like…

241 00:24:13.040 00:24:21.110 Emily Giant: So… I guess so. Yeah, yeah, that is fair. It’s not recognized on re-delivery items.

242 00:24:23.050 00:24:26.539 Demilade Agboola: So basically, what we need to do is for every order.

243 00:24:27.140 00:24:30.540 Demilade Agboola: We need to get old items, or…

244 00:24:31.690 00:24:37.579 Demilade Agboola: Not delivered, like, were non-delivery and non-deleted. Some of the revenue.

245 00:24:38.360 00:24:39.020 Demilade Agboola: Right?

246 00:24:39.650 00:24:42.940 Demilade Agboola: And then, for all delivered items.

247 00:24:43.520 00:24:49.599 Demilade Agboola: So, delivered items will be recognized as the non… Deleted items, basically.

248 00:24:51.810 00:24:52.480 Demilade Agboola: Right?

249 00:24:53.870 00:24:54.250 Demilade Agboola: 100%.

250 00:24:55.220 00:24:59.410 Demilade Agboola: So, like, non… like, delivered items would be the non-delivered items.

251 00:25:00.410 00:25:01.280 Emily Giant: Yes.

252 00:25:03.430 00:25:04.140 Demilade Agboola: Boom.

253 00:25:05.140 00:25:08.220 Demilade Agboola: Let’s say item 1 was purchased.

254 00:25:16.210 00:25:17.520 Demilade Agboola: and delivered.

255 00:25:18.990 00:25:24.880 Demilade Agboola: Man… 2 on 3… We delivered…

256 00:25:30.140 00:25:30.820 Demilade Agboola: Sweet.

257 00:25:30.930 00:25:34.139 Demilade Agboola: Two council, right? Like, maybe, like, number 2 canceled?

258 00:25:35.790 00:25:43.270 Demilade Agboola: We would effectively be saying, revenue… of item 1.

259 00:25:46.550 00:25:48.900 Demilade Agboola: Let’s… Gross.

260 00:25:49.600 00:25:52.320 Demilade Agboola: Hi, Tan… I’m 3.

261 00:25:53.780 00:25:55.670 Demilade Agboola: The term width, which would be…

262 00:25:59.350 00:26:03.110 Demilade Agboola: The value of this would be zero, basically.

263 00:26:03.110 00:26:03.910 Emily Giant: Yes.

264 00:26:04.440 00:26:06.959 Demilade Agboola: Alright, so we have our case statements.

265 00:26:07.660 00:26:11.489 Demilade Agboola: This… this makes it easier for us to look into the code itself, alright.

266 00:26:12.280 00:26:14.390 Demilade Agboola: So right now, what we’re doing…

267 00:26:20.090 00:26:23.959 Demilade Agboola: Is that… so we have the accrued revenue, which quantity times price.

268 00:26:25.110 00:26:28.330 Demilade Agboola: Joseph, which is the Peace Prize Corps.

269 00:26:29.490 00:26:36.580 Demilade Agboola: And so now, what we’re seeing is the total item is without… Every delivery.

270 00:26:39.120 00:26:39.779 Emily Giant: These are…

271 00:26:39.780 00:26:42.109 Demilade Agboola: So, the adjusted accrued revenue.

272 00:26:42.110 00:26:45.030 Emily Giant: Like, those re-delivery items should always be zero.

273 00:26:47.750 00:26:50.719 Demilade Agboola: Yeah, it really varies times are always zero, right?

274 00:26:51.420 00:26:52.280 Emily Giant: Yes.

275 00:26:52.780 00:26:59.440 Demilade Agboola: And then… That means that, like, once the reverse at zero.

276 00:27:00.370 00:27:11.579 Demilade Agboola: all the rest. I think what’s happening is, yeah, all the rest is the accrued revenue on that transaction, which is why, in this case, they’re getting 68, which is fine.

277 00:27:12.050 00:27:19.040 Emily Giant: Yep, that’s exactly right. It’s the accrued revenue is correct, it’s the total adjusted, because it added the price of the re-delivery.

278 00:27:21.320 00:27:23.620 Demilade Agboola: Yes, but isn’t…

279 00:27:23.620 00:27:29.279 Emily Giant: I think it needs to be fixed in the piece price in the very first CTE, not the case statement.

280 00:27:29.660 00:27:34.869 Demilade Agboola: Yeah, but, like, in this case, shouldn’t… again, remember there was splitting? In this case, like, this is literally a scenario.

281 00:27:35.170 00:27:38.190 Demilade Agboola: Actually, splitting the revenue across 1 and 3.

282 00:27:38.680 00:27:43.510 Emily Giant: No, because that’s a re-delivery. The billy is zero. No revenue for the billy.

283 00:27:44.630 00:27:46.770 Demilade Agboola: So in this case, even though it’s a re-delivery.

284 00:27:48.310 00:27:51.510 Demilade Agboola: The revenue on this is still only going to be due to the confetti.

285 00:27:51.730 00:27:55.389 Emily Giant: Yes. Because that’s what was… even though it says suborder printed.

286 00:27:55.570 00:28:08.659 Emily Giant: I guarantee it was sent out the door. And, like, that is what should get the revenue. Because that piece went into a box where whatever the hell happened to that box.

287 00:28:08.820 00:28:14.040 Emily Giant: We don’t know. But… It… that… that unit disappeared.

288 00:28:14.490 00:28:16.969 Emily Giant: And then they have to send a re-delivery.

289 00:28:17.480 00:28:25.260 Emily Giant: Which would be $0. So, it still only… the revenue still only goes to that first order, and it should never go to the re-delivery.

290 00:28:26.030 00:28:29.709 Demilade Agboola: Okay, and so in this case, same thing here as well.

291 00:28:31.500 00:28:33.010 Demilade Agboola: It should have got to the mimosa.

292 00:28:33.260 00:28:33.900 Emily Giant: Yep.

293 00:28:34.570 00:28:35.910 Demilade Agboola: Alright, let me see.

294 00:28:38.570 00:28:39.610 Demilade Agboola: Chair.

295 00:28:43.520 00:28:48.369 Demilade Agboola: Alright then, I think that’s helpful. I’ll finish this up then, and then I’ll push…

296 00:28:49.050 00:28:56.979 Emily Giant: Okay, can I show you my PR real quick, so that we can… Okay. I need to prepare dashboards for a meeting, so I’m like, ahhh!

297 00:28:58.220 00:29:02.699 Emily Giant: And it’s back in our inventory day, so put your inventory hat back on.

298 00:29:04.050 00:29:04.890 Emily Giant: Alright.

299 00:29:05.040 00:29:07.020 Emily Giant: I might not even have this pulled up yet.

300 00:29:08.330 00:29:10.130 Emily Giant: Let’s see…

301 00:29:10.990 00:29:19.189 Emily Giant: I need to get a new window going. I was looking for, a mason to help us with bricks in our basement, and that is all over my other tab, so…

302 00:29:22.390 00:29:25.900 Emily Giant: Please don’t make me do two-factor. Okay, good.

303 00:29:27.920 00:29:32.440 Emily Giant: Okay, so… let me go to… Gitub?

304 00:29:34.330 00:29:39.159 Emily Giant: 14 repositories seems like too many for our company size, doesn’t it?

305 00:29:39.270 00:29:40.180 Emily Giant: Anyway.

306 00:29:41.760 00:29:42.850 Emily Giant: Mmm…

307 00:29:47.790 00:29:49.350 Emily Giant: Okay…

308 00:29:52.350 00:29:53.330 Emily Giant: Alright.

309 00:29:53.470 00:30:06.490 Emily Giant: So it says 17 files were changed, but that’s kind of like a, huh, not really. So remember, back in our inventory days… oh, that’s just LookML. That’s… this is just Looker.

310 00:30:07.100 00:30:08.500 Emily Giant: I don’t know why that’s there.

311 00:30:08.760 00:30:11.250 Emily Giant: So dim…

312 00:30:11.900 00:30:20.939 Emily Giant: So, back in the inventory days, we did the calculation for, pre-sale committed and, on-hand committed.

313 00:30:21.710 00:30:29.860 Emily Giant: So there’s another use case for items that were never committed. And they look like… this.

314 00:30:36.770 00:30:40.140 Emily Giant: like this. Not committed. So,

315 00:30:40.960 00:30:46.250 Emily Giant: The… the supply chain and planning team needs to know

316 00:30:46.420 00:30:50.410 Emily Giant: When orders are not committed, so that they could evaluate risk with, like.

317 00:30:50.490 00:31:08.709 Emily Giant: promos, and yada yada yada during holidays, and, like, it gives you a better idea of how many orders versus how many units, because we have this, like… remember Mother’s Day when units weren’t claiming, and then we’d get oversold, and people would freak out and say that it was us having negative available for sale, but we were like, no, you’re oversold.

318 00:31:08.710 00:31:11.219 Emily Giant: It’s because of this. Things not committing.

319 00:31:11.410 00:31:18.309 Emily Giant: So, instead of having the one CTE, it used to be called, suborder, suborders with lots.

320 00:31:19.030 00:31:20.090 Demilade Agboola: Okay.

321 00:31:20.090 00:31:26.019 Emily Giant: Split it. It was, well, I’ll just show you the difference. But it’s gonna be…

322 00:31:26.700 00:31:32.980 Emily Giant: I actually got rid of that file, this suborders with lots, but I’ll show you what it was.

323 00:31:35.250 00:31:46.549 Emily Giant: it was this very long CTE with, like, the unranked on hand, and then the pre-sales were under it, and then it would say, like, pull everything from pre-sales that

324 00:31:46.740 00:32:02.459 Emily Giant: aren’t in the on-hand committed. So now I split them into 3 different ones, starting with the committed suborders, since that’s how we always would, like, yank out the ones that are pre-sales or not committed. So now it’s unranked on hand, and this pulls all the on-hand committed orders.

325 00:32:02.940 00:32:06.580 Emily Giant: And then there’s pre-sale committed, which pulls in everything from…

326 00:32:06.760 00:32:22.730 Emily Giant: committed suborders, the CTE, and pulls the pre-sales. The difference here is that, it joins on, inventory number instead of inventory assignment, but it’s a join, so anything without a,

327 00:32:23.010 00:32:27.780 Emily Giant: Inventory number gets… not included. But…

328 00:32:28.030 00:32:39.510 Emily Giant: the uncommitted orders don’t have an inventory number, and that’s how you identify them. So, there’s a third one that pulls all the orders with commitments, and then does a left join.

329 00:32:40.490 00:32:46.939 Emily Giant: And filters for… Where inventory number is null.

330 00:32:47.600 00:32:53.750 Emily Giant: And that gives you the uncommitted. And then the rest is the same, but I just changed the name.

331 00:32:53.930 00:33:01.870 Emily Giant: Because it used to say uncommitted items delivered, but that’s not true anymore. It’s just all uncommitted items. So the rest of the changes are…

332 00:33:02.680 00:33:06.289 Emily Giant: I do not want to merge this. Why is this in here?

333 00:33:07.220 00:33:10.169 Emily Giant: Sorry, this is the work that you and I are doing.

334 00:33:10.600 00:33:17.860 Emily Giant: So I need to, like, reset this so it’s not part of the… The deployment.

335 00:33:19.650 00:33:29.630 Emily Giant: Whoops, okay. Anyway, so all I did was change to uncommitted instead of uncommitted delivered, and that’s all the changes in the rest of the CTEs down the line.

336 00:33:30.640 00:33:36.520 Emily Giant: But that does effectively give the uncommitted order, so that’s the only real change with this.

337 00:33:37.440 00:33:43.450 Emily Giant: outside of… how can I revert this? Can I revert the,

338 00:33:45.780 00:33:50.580 Emily Giant: the redistribution model, so it’s not included in the CTE.

339 00:33:52.030 00:33:54.850 Emily Giant: Or in this… this PR?

340 00:33:54.850 00:33:57.739 Demilade Agboola: Can you, like, click on the three dots?

341 00:34:01.480 00:34:03.529 Demilade Agboola: In case you want to delete the file.

342 00:34:09.480 00:34:10.210 Emily Giant: Okay.

343 00:34:31.230 00:34:33.330 Emily Giant: So, I did the,

344 00:34:37.150 00:34:38.280 Emily Giant: Let’s see…

345 00:34:41.590 00:34:46.430 Emily Giant: total uncommitted quantity doesn’t exist. Okay, so there’s a… I have to fix this error, I don’t…

346 00:34:46.659 00:34:48.830 Emily Giant: I don’t know where this went.

347 00:34:49.070 00:34:53.740 Emily Giant: But… That’s… that’s the gist of the PR.

348 00:34:56.460 00:35:05.650 Emily Giant: And it seems to work well. But my question was, is there, like, a better way to,

349 00:35:06.280 00:35:10.550 Emily Giant: Like, increment… is there a faster way to…

350 00:35:11.240 00:35:24.139 Emily Giant: filter out the orders from the committed and pre-sale committed CTEs, because I feel like it makes it run a long time when I do where suborder is not in, and then reference an entire CTE.

351 00:35:25.700 00:35:31.929 Emily Giant: or an entire model for it to, like, go through the suborders. It just seems to make it run slower.

352 00:35:32.780 00:35:35.200 Demilade Agboola: Just a… just do a join at the left join.

353 00:35:40.330 00:35:40.890 Emily Giant: Nope.

354 00:35:43.500 00:35:54.599 Emily Giant: how… what do you mean? I’ve seen this done, and I just don’t… I have low confidence in my ability to do it. But it’s here. I have this in every one of the models, and it just… I feel like it’s…

355 00:35:54.880 00:35:56.010 Emily Giant: Too much.

356 00:35:58.020 00:36:01.170 Demilade Agboola: Let’s just do… you could do… so for this, you could do an inner join.

357 00:36:03.020 00:36:03.500 Emily Giant: Okay.

358 00:36:03.500 00:36:07.480 Demilade Agboola: If you don’t inter-join, if it’s not in there, it will not be part of it.

359 00:36:09.470 00:36:11.910 Emily Giant: Oh… Hmm, okay.

360 00:36:13.110 00:36:16.420 Emily Giant: And it shouldn’t be part of it, automatically.

361 00:36:17.050 00:36:24.900 Emily Giant: Because of the filtering on… the previous… ones.

362 00:36:25.350 00:36:35.549 Demilade Agboola: And joins are… joins are faster than where clauses. If you can use a… if you can use a good join in a join, it’ll just kind of remove the ones that aren’t part of it.

363 00:36:40.480 00:36:41.280 Emily Giant: Okay.

364 00:36:42.400 00:36:43.320 Emily Giant: Sweet.

365 00:36:52.930 00:36:53.960 Emily Giant: Okay.

366 00:36:54.560 00:36:58.190 Emily Giant: So, that seems pretty clear.

367 00:36:59.420 00:37:00.809 Emily Giant: Alright.

368 00:37:01.260 00:37:05.040 Emily Giant: That was all I really had a question about, but,

369 00:37:06.730 00:37:09.329 Emily Giant: Yeah, I added tests to make sure that, like.

370 00:37:09.620 00:37:16.050 Emily Giant: the suborders and the lots, or the suborders and the adjustment IDs were unique and stuff, and they’re all passing.

371 00:37:16.270 00:37:26.229 Emily Giant: So low-risk deployment outside of the fact that I got an error, which I need to fix before deploying it. But… does this look okay?

372 00:37:29.480 00:37:30.869 Emily Giant: In terms of, like.

373 00:37:31.200 00:37:39.750 Emily Giant: the changes from one huge CTE that does the pre-sale and the committed versus three separate ones that chunk out the logic.

374 00:37:51.650 00:37:52.670 Emily Giant: Hello.

375 00:37:54.210 00:37:56.800 Demilade Agboola: That should be fine.

376 00:37:58.650 00:37:59.870 Demilade Agboola: That’s what you heard that.

377 00:38:02.030 00:38:05.339 Emily Giant: Yeah, I can now. You were breaking up a bit before.

378 00:38:06.640 00:38:10.309 Demilade Agboola: Well, I think that should be fine, like, that looks fine.

379 00:38:10.700 00:38:13.319 Emily Giant: Okay, yeah, not much was changed, so…

380 00:38:14.000 00:38:17.829 Emily Giant: But I will have to, like, when I deploy it.

381 00:38:17.830 00:38:18.480 Demilade Agboola: Mix the run.

382 00:38:18.480 00:38:25.999 Emily Giant: Gonna be new columns in… wait, my other question was, like, none of these inventory models are incremental.

383 00:38:26.970 00:38:30.730 Emily Giant: outside of, like, the raw tables.

384 00:38:31.950 00:38:37.439 Emily Giant: Is that something that, like, maybe Awash could do? Like, these have to be… they run pretty fast.

385 00:38:37.600 00:38:43.450 Emily Giant: But still, like, that seems unnecessary, that, like… None of them are incremental.

386 00:38:46.680 00:39:04.290 Demilade Agboola: I mean, to be fair, I don’t think they need to be. I don’t think… the initial goal should not be to make things incremental. If they… it’s when they start to get heavy that you… you think incremental. Right now… right now, the entire thing… the entire polyatomic, like, run takes about, like, 5 minutes, 6 minutes? Yeah. That’s still fine.

387 00:39:04.740 00:39:05.280 Emily Giant: Okay.

388 00:39:06.160 00:39:19.220 Demilade Agboola: But, like, obviously, going forward, like, if things are getting slower, or that we have a table that is being a bottleneck, then yeah, we can look at the incremental function. Because incremental also comes with these data quality risks, right?

389 00:39:19.500 00:39:20.380 Emily Giant: Yeah.

390 00:39:20.640 00:39:21.450 Emily Giant: Truth.

391 00:39:21.820 00:39:25.650 Emily Giant: Okay. Well, in that case, I’ll deploy this,

392 00:39:26.100 00:39:32.069 Emily Giant: once I fix that error, and it runs. And then, with your fixes, I think that…

393 00:39:32.510 00:39:35.740 Emily Giant: Do you feel like you have a good path forward? I feel like you know what you’re doing.

394 00:39:37.280 00:39:40.579 Demilade Agboola: Yeah, I have a good idea of what I need to do for this.

395 00:39:40.990 00:39:49.300 Demilade Agboola: Use the item we based off of…

396 00:39:49.640 00:39:51.780 Demilade Agboola: All non-re-delivery.

397 00:39:54.600 00:39:55.030 Emily Giant: Yes.

398 00:39:55.030 00:40:01.520 Demilade Agboola: I think… I think my spin will be… Great question.

399 00:40:06.310 00:40:07.030 Emily Giant: So…

400 00:40:07.840 00:40:08.190 Demilade Agboola: Yeah.

401 00:40:08.190 00:40:10.040 Emily Giant: In the… yeah, in the Google.

402 00:40:10.040 00:40:14.999 Demilade Agboola: All non-deleted, also. It’s basically, like, all non-deleted.

403 00:40:15.600 00:40:21.830 Demilade Agboola: All non-deleted, non-reelivery will get the… revenue split.

404 00:40:22.010 00:40:23.350 Emily Giant: Yes, exactly.

405 00:40:25.120 00:40:28.150 Emily Giant: Non-deleted, non-re-delivery.

406 00:40:29.190 00:40:30.150 Demilade Agboola: I’ll get there by myself.

407 00:40:30.150 00:40:36.109 Emily Giant: And then, in the final model, you will overwrite subscriptions, too.

408 00:40:36.510 00:40:40.280 Emily Giant: But… None of what we’re looking at are subscriptions.

409 00:40:40.580 00:40:43.330 Emily Giant: So, shouldn’t be a problem.

410 00:40:43.530 00:40:47.370 Emily Giant: And that logic still applies to subscriptions, so…

411 00:40:47.520 00:40:52.140 Emily Giant: Anyway, and then I just wanted to double check

412 00:40:52.960 00:40:59.289 Emily Giant: I don’t know if it’s because my, my instance isn’t updated, but…

413 00:40:59.550 00:41:03.210 Emily Giant: In the final revenue model,

414 00:41:05.030 00:41:09.630 Emily Giant: There’s the new, like, the fixed… fact, legacy.

415 00:41:09.870 00:41:15.289 Emily Giant: this is the new… in fact, legacy order components is the new OMS CompEXF base.

416 00:41:15.670 00:41:22.170 Emily Giant: And then everything upstream of it is all, like, the cleaned, fixed stuff that we did. So…

417 00:41:22.940 00:41:42.929 Emily Giant: you are using this lineage that’s not in the Pandera Paradigm instead of the Pandera Paradigm? Okay, cool. Just making sure, because I want to delete Pandera Paradigm. Would it be a good move for me to work on filling in… because it’s suborders, the OMS sub-orders that pulls in the delivery information?

418 00:41:43.130 00:41:49.670 Emily Giant: Do you want me to work on filling in, in Legacy, where we’re missing delivery info?

419 00:41:50.740 00:41:59.939 Demilade Agboola: Yeah, I was actually even thinking of adding some of this, like, re-deliver info to the component union table, because I feel like it would be helpful to have it higher up.

420 00:42:00.420 00:42:01.190 Emily Giant: Yeah.

421 00:42:02.570 00:42:03.490 Emily Giant: Okay.

422 00:42:03.760 00:42:05.960 Demilade Agboola: Thank you. Yeah, so…

423 00:42:06.290 00:42:07.189 Emily Giant: So, yeah.

424 00:42:07.320 00:42:14.930 Emily Giant: Well, once we get… once we get the numbers, then I think it’ll be really easy to fill in all of those…

425 00:42:15.140 00:42:20.070 Emily Giant: null columns. So, not terribly worried about that, but…

426 00:42:20.780 00:42:26.999 Emily Giant: Okay, cool. Well, just huddle me if you need anything. I don’t really have any meetings after, like, 1 o’clock today.

427 00:42:27.370 00:42:28.430 Demilade Agboola: Okay, sounds good.

428 00:42:28.540 00:42:31.149 Emily Giant: Hammering away. Alright, thank you, I’ll talk to you soon.

429 00:42:31.560 00:42:32.710 Demilade Agboola: Jason, bye.

430 00:42:32.710 00:42:33.260 Emily Giant: Hey.