Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
script
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
姚闰伍
script
Commits
7e3a802c
Commit
7e3a802c
authored
Dec 05, 2018
by
蘑菇🍄
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
购物车状态判断
parent
56276b6e
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
8 deletions
+8
-8
数据组装pro.sql
jnby-pomme/数据组装pro.sql
+8
-8
No files found.
jnby-pomme/数据组装pro.sql
View file @
7e3a802c
...
...
@@ -364,7 +364,7 @@ INSERT INTO `tab_gic_mall_collection_copy`
SELECT
replace
(
uuid
(),
'-'
,
''
)
as
collection_id
,
members_view
.
member_id
,
members_view
.
enterprise_id
,
pro
.
brand_id
,
pro
.
mall_pro_id
,
pro
.
pro_name
as
mall_pro_name
,
pro
.
mall_pro_spu_price
as
mall_pro_collected_price
,
pro
.
mall_pro_spu_price
as
mall_pro_price
,
pro
.
mall_pro_spu_price
as
mall_pro_collected_price
,
pro
.
mall_pro_spu_price
as
mall_pro_price
,
pro
.
mall_pro_image_url
,
pro
.
mall_pro_spu_price
,
co
.
`status`
,
co
.
create_time
,
co
.
create_time
as
update_time
,
members_view
.
clique_id
,
members_view
.
clique_member_id
,
1
as
from_erp
...
...
@@ -385,16 +385,16 @@ INSERT INTO `tab_gic_mall_shopping_cart_copy` (
,
`mall_pro_summary_price`
,
`clique_id`
,
`clique_member_id`
,
`from_erp`
)
SELECT
replace
(
uuid
(),
'-'
,
''
)
as
shopping_cart_id
,
members_view
.
member_id
,
pro
.
enterprise_id
,
pro
.
brand_id
,
pro
.
mall_pro_id
,
pro
.
pro_name
as
mall_pro_name
,
sku
.
mall_pro_sku_id
,
IFNULL
(
sku
.
mall_prop_values
,
'[{}]'
)
as
mall_pro_sku_attr
replace
(
uuid
(),
'-'
,
''
)
as
shopping_cart_id
,
members_view
.
member_id
,
members_view
.
enterprise_id
,
pro
.
brand_id
,
pro
.
mall_pro_id
,
cart
.
mall_pro_name
,
sku
.
mall_pro_sku_id
,
IFNULL
(
sku
.
mall_prop_values
,
'[{}]'
)
as
mall_pro_sku_attr
,
cart
.
mall_pro_price
,
pro
.
mall_pro_image_url
,
cart
.
mall_pro_number
,
sku
.
mall_pro_sku_price
,
cart
.
mall_pro_summary_price
as
mall_pro_payable_price
,
1
as
status
,
cart
.
create_time
,
cart
.
create_time
as
update_time
,
cart
.
mall_pro_summary_price
as
mall_pro_payable_price
,
IF
(
isnull
(
pro
.
mall_pro_id
),
0
,
1
)
as
status
,
cart
.
create_time
,
cart
.
create_time
as
update_time
,
cart
.
mall_pro_summary_price
,
members_view
.
clique_id
,
members_view
.
clique_member_id
,
1
as
from_erp
from
mall_shoopping_cart
cart
left
join
tab_gic_mall_pro
_sku
sku
on
sku
.
mall_pro_sku_code
=
cart
.
mall_sku_code
left
join
tab_gic_mall_pro
pro
on
pro
.
pro_code
=
cart
.
mall_pro_code
and
pro
.
enterprise_id
=
'ff8080816170e8990161f6736b4c6033'
left
join
`gic3.0`
.
tab_gic_member_pommedeterre
members_view
on
members_view
.
card_num
=
cart
.
cardno
left
join
tab_gic_mall_pro
pro
on
pro
.
pro_code
=
cart
.
mall_pro_code
and
pro
.
enterprise_id
=
'ff8080816170e8990161f6736b4c6033'
left
join
tab_gic_mall_pro
_sku
sku
on
sku
.
mall_pro_sku_code
=
cart
.
mall_sku_code
and
sku
.
enterprise_id
=
'ff8080816170e8990161f6736b4c6033'
left
join
`gic3.0`
.
tab_gic_member_pommedeterre
members_view
on
members_view
.
card_num
=
cart
.
cardno
group
by
cart
.
cardno
,
cart
.
mall_pro_code
,
cart
.
mall_sku_code
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment