This commit is contained in:
parent
f52a013e3f
commit
19bb9a1c8e
Binary file not shown.
|
@ -6,9 +6,21 @@
|
||||||
"AbsoluteMoniker": "D:0:0:{1CE29CD9-8ED4-497C-A794-85FA3BA3B87F}|SqlCustomFunctions.sqlproj|C:\\Repos\\SqlCustomFunctions\\ClsConversions.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}",
|
"AbsoluteMoniker": "D:0:0:{1CE29CD9-8ED4-497C-A794-85FA3BA3B87F}|SqlCustomFunctions.sqlproj|C:\\Repos\\SqlCustomFunctions\\ClsConversions.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}",
|
||||||
"RelativeMoniker": "D:0:0:{1CE29CD9-8ED4-497C-A794-85FA3BA3B87F}|SqlCustomFunctions.sqlproj|solutionrelative:ClsConversions.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}"
|
"RelativeMoniker": "D:0:0:{1CE29CD9-8ED4-497C-A794-85FA3BA3B87F}|SqlCustomFunctions.sqlproj|solutionrelative:ClsConversions.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Repos\\SqlCustomFunctions\\bin\\Release\\SqlCustomFunctions_15.publish.sql||{CC5D8DF0-88F4-4BB2-9DBB-B48CEE65C30A}",
|
||||||
|
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:bin\\Release\\SqlCustomFunctions_15.publish.sql||{CC5D8DF0-88F4-4BB2-9DBB-B48CEE65C30A}"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"AbsoluteMoniker": "D:0:0:{1CE29CD9-8ED4-497C-A794-85FA3BA3B87F}|SqlCustomFunctions.sqlproj|C:\\Repos\\SqlCustomFunctions\\IPFunctions.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}",
|
"AbsoluteMoniker": "D:0:0:{1CE29CD9-8ED4-497C-A794-85FA3BA3B87F}|SqlCustomFunctions.sqlproj|C:\\Repos\\SqlCustomFunctions\\IPFunctions.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}",
|
||||||
"RelativeMoniker": "D:0:0:{1CE29CD9-8ED4-497C-A794-85FA3BA3B87F}|SqlCustomFunctions.sqlproj|solutionrelative:IPFunctions.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}"
|
"RelativeMoniker": "D:0:0:{1CE29CD9-8ED4-497C-A794-85FA3BA3B87F}|SqlCustomFunctions.sqlproj|solutionrelative:IPFunctions.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Repos\\SqlCustomFunctions\\bin\\Release\\SqlCustomFunctions_15.publish.sql||{CC5D8DF0-88F4-4BB2-9DBB-B48CEE65C30A}|CodeFrame",
|
||||||
|
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:bin\\Release\\SqlCustomFunctions_15.publish.sql||{CC5D8DF0-88F4-4BB2-9DBB-B48CEE65C30A}|CodeFrame"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Repos\\SqlCustomFunctions\\bin\\Release\\SqlCustomFunctions_15.publish.sql||{CC5D8DF0-88F4-4BB2-9DBB-B48CEE65C30A}|ResultFrame",
|
||||||
|
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:bin\\Release\\SqlCustomFunctions_15.publish.sql||{CC5D8DF0-88F4-4BB2-9DBB-B48CEE65C30A}|ResultFrame"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"DocumentGroupContainers": [
|
"DocumentGroupContainers": [
|
||||||
|
@ -18,7 +30,7 @@
|
||||||
"DocumentGroups": [
|
"DocumentGroups": [
|
||||||
{
|
{
|
||||||
"DockedWidth": 200,
|
"DockedWidth": 200,
|
||||||
"SelectedChildIndex": 11,
|
"SelectedChildIndex": 13,
|
||||||
"Children": [
|
"Children": [
|
||||||
{
|
{
|
||||||
"$type": "Bookmark",
|
"$type": "Bookmark",
|
||||||
|
@ -64,6 +76,21 @@
|
||||||
"$type": "Bookmark",
|
"$type": "Bookmark",
|
||||||
"Name": "ST:0:0:{aa2115a1-9712-457b-9047-dbb71ca2cdd2}"
|
"Name": "ST:0:0:{aa2115a1-9712-457b-9047-dbb71ca2cdd2}"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"$type": "Bookmark",
|
||||||
|
"Name": "ST:1:0:{e8b06f52-6d01-11d2-aa7d-00c04f990343}"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"$type": "Document",
|
||||||
|
"DocumentIndex": 1,
|
||||||
|
"Title": "SqlCustomFunctions_15.publish.sql ",
|
||||||
|
"DocumentMoniker": "C:\\Repos\\SqlCustomFunctions\\bin\\Release\\SqlCustomFunctions_15.publish.sql",
|
||||||
|
"RelativeDocumentMoniker": "bin\\Release\\SqlCustomFunctions_15.publish.sql",
|
||||||
|
"ToolTip": "SqlCustomFunctions_15.publish.sql ",
|
||||||
|
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000826|",
|
||||||
|
"WhenOpened": "2025-09-26T11:13:36.185Z",
|
||||||
|
"EditorCaption": ""
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"$type": "Document",
|
"$type": "Document",
|
||||||
"DocumentIndex": 0,
|
"DocumentIndex": 0,
|
||||||
|
@ -72,14 +99,14 @@
|
||||||
"RelativeDocumentMoniker": "ClsConversions.cs",
|
"RelativeDocumentMoniker": "ClsConversions.cs",
|
||||||
"ToolTip": "C:\\Repos\\SqlCustomFunctions\\ClsConversions.cs",
|
"ToolTip": "C:\\Repos\\SqlCustomFunctions\\ClsConversions.cs",
|
||||||
"RelativeToolTip": "ClsConversions.cs",
|
"RelativeToolTip": "ClsConversions.cs",
|
||||||
"ViewState": "AgIAADgAAAAAAAAAAAAAAE8AAAAQAAAAAAAAAA==",
|
"ViewState": "AgIAADgAAAAAAAAAAAAAAEwAAAAFAAAAAAAAAA==",
|
||||||
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000738|",
|
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000738|",
|
||||||
"WhenOpened": "2025-09-23T11:15:50.492Z",
|
"WhenOpened": "2025-09-23T11:15:50.492Z",
|
||||||
"EditorCaption": ""
|
"EditorCaption": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"$type": "Document",
|
"$type": "Document",
|
||||||
"DocumentIndex": 1,
|
"DocumentIndex": 2,
|
||||||
"Title": "IPFunctions.cs",
|
"Title": "IPFunctions.cs",
|
||||||
"DocumentMoniker": "C:\\Repos\\SqlCustomFunctions\\IPFunctions.cs",
|
"DocumentMoniker": "C:\\Repos\\SqlCustomFunctions\\IPFunctions.cs",
|
||||||
"RelativeDocumentMoniker": "IPFunctions.cs",
|
"RelativeDocumentMoniker": "IPFunctions.cs",
|
||||||
|
|
|
@ -6,9 +6,21 @@
|
||||||
"AbsoluteMoniker": "D:0:0:{1CE29CD9-8ED4-497C-A794-85FA3BA3B87F}|SqlCustomFunctions.sqlproj|C:\\Repos\\SqlCustomFunctions\\ClsConversions.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}",
|
"AbsoluteMoniker": "D:0:0:{1CE29CD9-8ED4-497C-A794-85FA3BA3B87F}|SqlCustomFunctions.sqlproj|C:\\Repos\\SqlCustomFunctions\\ClsConversions.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}",
|
||||||
"RelativeMoniker": "D:0:0:{1CE29CD9-8ED4-497C-A794-85FA3BA3B87F}|SqlCustomFunctions.sqlproj|solutionrelative:ClsConversions.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}"
|
"RelativeMoniker": "D:0:0:{1CE29CD9-8ED4-497C-A794-85FA3BA3B87F}|SqlCustomFunctions.sqlproj|solutionrelative:ClsConversions.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Repos\\SqlCustomFunctions\\bin\\Release\\SqlCustomFunctions_15.publish.sql||{CC5D8DF0-88F4-4BB2-9DBB-B48CEE65C30A}",
|
||||||
|
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:bin\\Release\\SqlCustomFunctions_15.publish.sql||{CC5D8DF0-88F4-4BB2-9DBB-B48CEE65C30A}"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"AbsoluteMoniker": "D:0:0:{1CE29CD9-8ED4-497C-A794-85FA3BA3B87F}|SqlCustomFunctions.sqlproj|C:\\Repos\\SqlCustomFunctions\\IPFunctions.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}",
|
"AbsoluteMoniker": "D:0:0:{1CE29CD9-8ED4-497C-A794-85FA3BA3B87F}|SqlCustomFunctions.sqlproj|C:\\Repos\\SqlCustomFunctions\\IPFunctions.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}",
|
||||||
"RelativeMoniker": "D:0:0:{1CE29CD9-8ED4-497C-A794-85FA3BA3B87F}|SqlCustomFunctions.sqlproj|solutionrelative:IPFunctions.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}"
|
"RelativeMoniker": "D:0:0:{1CE29CD9-8ED4-497C-A794-85FA3BA3B87F}|SqlCustomFunctions.sqlproj|solutionrelative:IPFunctions.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Repos\\SqlCustomFunctions\\bin\\Release\\SqlCustomFunctions_15.publish.sql||{CC5D8DF0-88F4-4BB2-9DBB-B48CEE65C30A}|CodeFrame",
|
||||||
|
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:bin\\Release\\SqlCustomFunctions_15.publish.sql||{CC5D8DF0-88F4-4BB2-9DBB-B48CEE65C30A}|CodeFrame"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"AbsoluteMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|C:\\Repos\\SqlCustomFunctions\\bin\\Release\\SqlCustomFunctions_15.publish.sql||{CC5D8DF0-88F4-4BB2-9DBB-B48CEE65C30A}|ResultFrame",
|
||||||
|
"RelativeMoniker": "D:0:0:{A2FE74E1-B743-11D0-AE1A-00A0C90FFFC3}|\u003CMiscFiles\u003E|solutionrelative:bin\\Release\\SqlCustomFunctions_15.publish.sql||{CC5D8DF0-88F4-4BB2-9DBB-B48CEE65C30A}|ResultFrame"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"DocumentGroupContainers": [
|
"DocumentGroupContainers": [
|
||||||
|
@ -18,7 +30,7 @@
|
||||||
"DocumentGroups": [
|
"DocumentGroups": [
|
||||||
{
|
{
|
||||||
"DockedWidth": 200,
|
"DockedWidth": 200,
|
||||||
"SelectedChildIndex": 11,
|
"SelectedChildIndex": 13,
|
||||||
"Children": [
|
"Children": [
|
||||||
{
|
{
|
||||||
"$type": "Bookmark",
|
"$type": "Bookmark",
|
||||||
|
@ -64,6 +76,21 @@
|
||||||
"$type": "Bookmark",
|
"$type": "Bookmark",
|
||||||
"Name": "ST:0:0:{aa2115a1-9712-457b-9047-dbb71ca2cdd2}"
|
"Name": "ST:0:0:{aa2115a1-9712-457b-9047-dbb71ca2cdd2}"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"$type": "Bookmark",
|
||||||
|
"Name": "ST:1:0:{e8b06f52-6d01-11d2-aa7d-00c04f990343}"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"$type": "Document",
|
||||||
|
"DocumentIndex": 1,
|
||||||
|
"Title": "SqlCustomFunctions_15.publish.sql ",
|
||||||
|
"DocumentMoniker": "C:\\Repos\\SqlCustomFunctions\\bin\\Release\\SqlCustomFunctions_15.publish.sql",
|
||||||
|
"RelativeDocumentMoniker": "bin\\Release\\SqlCustomFunctions_15.publish.sql",
|
||||||
|
"ToolTip": "SqlCustomFunctions_15.publish.sql ",
|
||||||
|
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000826|",
|
||||||
|
"WhenOpened": "2025-09-26T11:13:36.185Z",
|
||||||
|
"EditorCaption": ""
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"$type": "Document",
|
"$type": "Document",
|
||||||
"DocumentIndex": 0,
|
"DocumentIndex": 0,
|
||||||
|
@ -72,14 +99,14 @@
|
||||||
"RelativeDocumentMoniker": "ClsConversions.cs",
|
"RelativeDocumentMoniker": "ClsConversions.cs",
|
||||||
"ToolTip": "C:\\Repos\\SqlCustomFunctions\\ClsConversions.cs",
|
"ToolTip": "C:\\Repos\\SqlCustomFunctions\\ClsConversions.cs",
|
||||||
"RelativeToolTip": "ClsConversions.cs",
|
"RelativeToolTip": "ClsConversions.cs",
|
||||||
"ViewState": "AgIAADgAAAAAAAAAAAAAAE8AAAAmAAAAAAAAAA==",
|
"ViewState": "AgIAADgAAAAAAAAAAAAAAE8AAAAnAAAAAAAAAA==",
|
||||||
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000738|",
|
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000738|",
|
||||||
"WhenOpened": "2025-09-23T11:15:50.492Z",
|
"WhenOpened": "2025-09-23T11:15:50.492Z",
|
||||||
"EditorCaption": ""
|
"EditorCaption": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"$type": "Document",
|
"$type": "Document",
|
||||||
"DocumentIndex": 1,
|
"DocumentIndex": 2,
|
||||||
"Title": "IPFunctions.cs",
|
"Title": "IPFunctions.cs",
|
||||||
"DocumentMoniker": "C:\\Repos\\SqlCustomFunctions\\IPFunctions.cs",
|
"DocumentMoniker": "C:\\Repos\\SqlCustomFunctions\\IPFunctions.cs",
|
||||||
"RelativeDocumentMoniker": "IPFunctions.cs",
|
"RelativeDocumentMoniker": "IPFunctions.cs",
|
||||||
|
|
|
@ -73,12 +73,16 @@ namespace SqlCustomFunctions
|
||||||
}
|
}
|
||||||
|
|
||||||
[Microsoft.SqlServer.Server.SqlFunction()]
|
[Microsoft.SqlServer.Server.SqlFunction()]
|
||||||
public static SqlString dtReportDateRange(SqlDateTime date1, SqlDateTime date2)
|
public static SqlString dtRangeHumanized(SqlDateTime date1, SqlDateTime date2)
|
||||||
{
|
{
|
||||||
SqlString rv = string.Empty;
|
SqlString rv = string.Empty;
|
||||||
|
|
||||||
if (date1.CompareTo(date2) == 0)
|
if (date1.IsNull || date2.IsNull)
|
||||||
|
rv = "Invalid Date Range Specified (one or both are NULL)";
|
||||||
|
else if (date1.Value.CompareTo(date2.Value) == 0)
|
||||||
rv = string.Format("{0:ddd MMM d, yyyy}", date1.Value);
|
rv = string.Format("{0:ddd MMM d, yyyy}", date1.Value);
|
||||||
|
//else if (date1.Value.Year == date2.Value.Year && date2.Value.Year == DateTime.Today.Year)
|
||||||
|
// rv = string.Format("{0:ddd MMM d} - {1:ddd MMM d}", date1.Value, date2.Value);
|
||||||
else if (date1.Value.Year == date2.Value.Year)
|
else if (date1.Value.Year == date2.Value.Year)
|
||||||
rv = string.Format("{0:ddd MMM d} - {1:ddd MMM d, yyyy}", date1.Value, date2.Value);
|
rv = string.Format("{0:ddd MMM d} - {1:ddd MMM d, yyyy}", date1.Value, date2.Value);
|
||||||
else
|
else
|
||||||
|
|
|
@ -23,7 +23,7 @@
|
||||||
<IncludeCompositeObjects>True</IncludeCompositeObjects>
|
<IncludeCompositeObjects>True</IncludeCompositeObjects>
|
||||||
<TargetDatabaseSet>True</TargetDatabaseSet>
|
<TargetDatabaseSet>True</TargetDatabaseSet>
|
||||||
<TargetFrameworkProfile />
|
<TargetFrameworkProfile />
|
||||||
<Recovery>SIMPLE</Recovery>
|
<Recovery>FULL</Recovery>
|
||||||
<PermissionSet>SAFE</PermissionSet>
|
<PermissionSet>SAFE</PermissionSet>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||||
|
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
File diff suppressed because one or more lines are too long
Binary file not shown.
Binary file not shown.
|
@ -5,7 +5,3 @@ C:\Repos\SqlCustomFunctions\obj\Release\SqlCustomFunctions.sqlproj.AssemblyRefer
|
||||||
C:\Repos\SqlCustomFunctions\obj\Release\SqlCustomFunctions.sqlproj.CoreCompileInputs.cache
|
C:\Repos\SqlCustomFunctions\obj\Release\SqlCustomFunctions.sqlproj.CoreCompileInputs.cache
|
||||||
C:\Repos\SqlCustomFunctions\obj\Release\SqlCustomFunctions.dll
|
C:\Repos\SqlCustomFunctions\obj\Release\SqlCustomFunctions.dll
|
||||||
C:\Repos\SqlCustomFunctions\obj\Release\SqlCustomFunctions.pdb
|
C:\Repos\SqlCustomFunctions\obj\Release\SqlCustomFunctions.pdb
|
||||||
C:\Repos\SqlCustomFunctions\obj\Release\Model.xml
|
|
||||||
C:\Repos\SqlCustomFunctions\obj\Release\refactor.xml
|
|
||||||
C:\Repos\SqlCustomFunctions\obj\Release\postdeploy.sql
|
|
||||||
C:\Repos\SqlCustomFunctions\obj\Release\predeploy.sql
|
|
||||||
|
|
Loading…
Reference in New Issue