CDF missing in field: Difference between revisions

From IMSMA Wiki
Jump to navigation Jump to search
Created page with "<pre>SELECT customdefinedfield.name, customdefinedfield.cdf_datatype, customdefinedfield.entitytype FROM customdefinedfield Left Join `field` ON customdefinedfield.cdf_id = `f..."
 
No edit summary
 
(2 intermediate revisions by 2 users not shown)
Line 1: Line 1:
<pre>SELECT
This query check if all records in ''customdefinedfield'' are in ''field''
<pre>
SELECT
customdefinedfield.name,
customdefinedfield.name,
customdefinedfield.cdf_datatype,
customdefinedfield.cdf_datatype,
Line 8: Line 10:
WHERE
WHERE
`field`.cdf_guid IS NULL
`field`.cdf_guid IS NULL
</pre>


-----------------------------------------------------------------------
This query check if all CDF records in ''field'' are in ''customdefinedfield''
 
<pre>
SELECT
SELECT
`field`.property_name,
`field`.property_name,
Line 21: Line 24:
WHERE
WHERE
customdefinedfield.cdf_id IS NULL  AND
customdefinedfield.cdf_id IS NULL  AND
`field`.cdf_guid IS NOT NULL
`field`.cdf_guid IS NOT NULL AND
(`field`.fieldtype =  'cdf' OR
`field`.fieldtype =  'select_cdf')
ORDER BY
`field`.fieldtype ASC
</pre>


</pre>
{{NavBox Upgrade}}
[[Category:NoPublic]]
[[Category:NoPublic]]
[[Category:SQL Queries]]

Latest revision as of 09:48, 12 July 2014

This query check if all records in customdefinedfield are in field

SELECT
customdefinedfield.name,
customdefinedfield.cdf_datatype,
customdefinedfield.entitytype
FROM
customdefinedfield
Left Join `field` ON customdefinedfield.cdf_id = `field`.cdf_guid
WHERE
`field`.cdf_guid IS NULL

This query check if all CDF records in field are in customdefinedfield

SELECT
`field`.property_name,
`field`.fieldtype,
`field`.display_mechanism,
`field`.cdf_guid
FROM
customdefinedfield
Right Outer Join `field` ON customdefinedfield.cdf_id = `field`.cdf_guid
WHERE
customdefinedfield.cdf_id IS NULL  AND
`field`.cdf_guid IS NOT NULL  AND
(`field`.fieldtype =  'cdf' OR
`field`.fieldtype =  'select_cdf')
ORDER BY
`field`.fieldtype ASC

{{#switch:|subgroup|child=|none=|#default=

}}{{#if:|}}{{#if:Upgrade Process|<td style="text-align:left;border-left-width:2px;border-left-style:solid;|{{#if:|}}}}{{#if:|{{#if:IMSMA Hub{{#switch:{{#if:|{{{border}}}|child}}|subgroup|child=|none=|#default=

}}{{#ifeq:|Template|{{#ifeq:{{#if:|{{{border}}}|child}}|child||{{#ifeq:{{#if:|{{{border}}}|child}}|subgroup||{{#switch:cdf missing in field

|doc
|sandbox
|testcases =
|#default = {{#switch:
 |plainlist
 |hlist
 |hlist hnum
 |hlist vcard
 |vcard hlist = 
 |#default = 
 }}
}}

}}}}}}|}}{{#if:|{{{group2}}}<td style="text-align:left;border-left-width:2px;border-left-style:solid;|

{{{list2}}}

}}{{#if:|{{#if:IMSMA Hub{{#switch:{{#if:|{{{border}}}|child}}|subgroup|child=|none=|#default=

}}{{#ifeq:|Template|{{#ifeq:{{#if:|{{{border}}}|child}}|child||{{#ifeq:{{#if:|{{{border}}}|child}}|subgroup||{{#switch:cdf missing in field

|doc
|sandbox
|testcases =
|#default = {{#switch:
 |plainlist
 |hlist
 |hlist hnum
 |hlist vcard
 |vcard hlist = 
 |#default = 
 }}
}}

}}}}}}|}}{{#if:|{{{group3}}}<td style="text-align:left;border-left-width:2px;border-left-style:solid;|

{{{list3}}}

}}{{#if:|{{#if:|{{{group4}}}<td style="text-align:left;border-left-width:2px;border-left-style:solid;|

{{{list4}}}

}}{{#if:|{{#if:|{{{group5}}}<td style="text-align:left;border-left-width:2px;border-left-style:solid;|

{{{list5}}}

}}{{#if:|{{#if:|{{{group6}}}<td style="text-align:left;border-left-width:2px;border-left-style:solid;|

{{{list6}}}

}}{{#if:|{{#if:|{{{group7}}}<td style="text-align:left;border-left-width:2px;border-left-style:solid;|

{{{list7}}}

}}{{#if:|{{#if:|{{{group8}}}<td style="text-align:left;border-left-width:2px;border-left-style:solid;|

{{{list8}}}

}}{{#if:|{{#if:|{{{group9}}}<td style="text-align:left;border-left-width:2px;border-left-style:solid;|

{{{list9}}}

}}{{#if:|{{#if:|{{{group10}}}<td style="text-align:left;border-left-width:2px;border-left-style:solid;|

{{{list10}}}

}}{{#if:|{{#if:|{{{group11}}}<td style="text-align:left;border-left-width:2px;border-left-style:solid;|

{{{list11}}}

}}{{#if:|{{#if:|{{{group12}}}<td style="text-align:left;border-left-width:2px;border-left-style:solid;|

{{{list12}}}

}}{{#if:|{{#if:|{{{group13}}}<td style="text-align:left;border-left-width:2px;border-left-style:solid;|

{{{list13}}}

}}{{#if:|{{#if:|{{{group14}}}<td style="text-align:left;border-left-width:2px;border-left-style:solid;|

{{{list14}}}

}}{{#if:|{{#if:|{{{group15}}}<td style="text-align:left;border-left-width:2px;border-left-style:solid;|

{{{list15}}}

}}{{#if:|{{#if:|{{{group16}}}<td style="text-align:left;border-left-width:2px;border-left-style:solid;|

{{{list16}}}

}}{{#if:|{{#if:|{{{group17}}}<td style="text-align:left;border-left-width:2px;border-left-style:solid;|

{{{list17}}}

}}{{#if:|{{#if:|{{{group18}}}<td style="text-align:left;border-left-width:2px;border-left-style:solid;|

{{{list18}}}

}}{{#if:|{{#if:|{{{group19}}}<td style="text-align:left;border-left-width:2px;border-left-style:solid;|

{{{list19}}}

}}{{#if:|{{#if:|{{{group20}}}<td style="text-align:left;border-left-width:2px;border-left-style:solid;|

{{{list20}}}

}}{{#if:|{{#if:IMSMA Hub{{#switch:{{#if:|{{{border}}}|child}}|subgroup|child=|none=|#default=

}}{{#ifeq:|Template|{{#ifeq:{{#if:|{{{border}}}|child}}|child||{{#ifeq:{{#if:|{{{border}}}|child}}|subgroup||{{#switch:cdf missing in field

|doc
|sandbox
|testcases =
|#default = {{#switch:
 |plainlist
 |hlist
 |hlist hnum
 |hlist vcard
 |vcard hlist = 
 |#default = 
 }}
}}

}}}}}}|}}

{{{below}}}

}}{{#switch:|subgroup|child=

|none=|#default=}}{{#ifeq:|Template|{{#ifeq:|child||{{#ifeq:|subgroup||{{#switch:cdf missing in field
|doc
|sandbox
|testcases =
|#default = {{#switch:hlist
 |plainlist
 |hlist
 |hlist hnum
 |hlist vcard
 |vcard hlist = 
 |#default = 
 }}
}}

}}}}}}