case --col.system_type_name WHEN (CHARINDEX('nvarchar',system_type_name)>0) then 'string' when (system_type_name='bigint') then 'long' when (system_type_name='binary') then 'byte[]' when (system_type_name='bit') then 'bool' when (system_type_name='char') then 'string' when (system_type_name='date') then 'DateTime' when (system_type_name='datetime') then 'DateTime' when (system_type_name='datetime2') then 'DateTime' when (system_type_name='datetimeoffset') then 'DateTimeOffset' when (CHARINDEX('decimal',system_type_name)>0) then 'decimal' when (system_type_name='float') then 'float' when (system_type_name='image') then 'byte[]' when (system_type_name='int') then 'int' when (system_type_name='money') then 'decimal' when (system_type_name='nchar') then 'string' when (system_type_name='ntext') then 'string' when (CHARINDEX('numeric',system_type_name)>0) then 'decimal' when (system_type_name='real') then 'double' when (system_type_name='smalldatetime') then 'DateTime' when (system_type_name='smallint') then 'short' when (system_type_name='smallmoney') then 'decimal' when (system_type_name='text') THEN 'string' when (system_type_name='time') then 'TimeSpan' when (system_type_name='timestamp') then 'DateTime' when (system_type_name='tinyint') then 'byte' when (system_type_name='uniqueidentifier') then 'Guid' when (system_type_name='varbinary') then 'byte[]' when (system_type_name='varchar') then 'string' ELSE ('UNKNOWN_') + col.system_type_name end ColumnType, case when col.is_nullable = 1 and col.name in ('bigint', 'bit', 'date', 'datetime', 'datetime2', 'datetimeoffset', 'decimal', 'float', 'int', 'money', 'numeric', 'real', 'smalldatetime', 'smallint', 'smallmoney', 'time', 'tinyint', 'uniqueidentifier') then '?' else '' end NullableSign -- name, system_type_name FROM sys.dm_exec_describe_first_result_set(@sql, NULL, 1) AS col
By default datatables load all record from database and then use search in client side. but it often cause problem in large data set, to load from database.
Problem Arise when use to set image source using javascript , then after publish in IIS sub directory image is not loaded, for hosting directory miss match. then we can catch the hosting directory , and append to image source.
var dd = '<% =Request.ApplicationPath %>';
console.log(dd);