Currently I am facing one telerik open access error. It would be great if you can help on this. The error message like below :
(See Pic1)
The model diagram looks like below snapshot :
(See Pic2)
Each different class (MtSubmitter,MtInventor,MtStaffMember,MtCorrespondent,MtValidator,MtMeetingLeader) mapped with different View.
(See Pic3)
After Implementing the different QuickSearchMethod of different class, If I execute any QuckSearchMethod(Ex:- QuckSearckCorrespondent) , its working fine .
(See Pic4)
Now if I execute any other QuickSearchMethod(Ex:-QuickSearchInventor), I am getting the above error.
Similarly if I execute QuickSearchStaffMember, I am also getting the same error.
(See Pic5)
(i.e After running application ,if I execute any QuickSerachMethod it may be QuckSearckCorrespondent,it may be QuickSearchInventor etc.. its working fine,but after executing one QuickSearchMethod if I execute other QuickSearchMethod I am getting the above error.)
After debugging on QuickSearchMethod(Ex:-QuickSearchInvention) I am getting the below information :
(See Pic6)
If I execute the Sql query explicitly I am getting the data,but not understand why I am getting the above error.
SELECT a."NAMEKEY" COL1, a."BIRTHDAY" COL2, a."COMPANYKEY" COL3, a."COMPANYKEY" COL4, a."COMPANYNAME" COL5, |
a."FIRSTNAME" COL6, a."FUNCTIONNAME" COL7, a."INITIALS" COL8, a."MIDDLEINITIALS" COL9, a."MIDDLENAME" COL10, a."GENDER" COL11, |
a."NAMEINFORMATION" COL12, a."TITLEKEY" COL13, a."NATIONALITYCOUNTRYKEY" COL14, a."NATIONALITYCOUNTRYKEY" COL15, |
a."OFFICENUMBER" COL16, a."TITLEKEY" COL17, b."NAMECODE" COL18, b."CURRENCYKEY" COL19, b."DATECEASED" COL20, |
b."DATESTART" COL21, b."EMAIL" COL22, b."LANGUAGEKEY" COL23, b."LDAPUNIQUEID" COL24, |
b."CURRENCYKEY" COL25, b."LANGUAGEKEY" COL26, b."LOTUSNOTESUNIQUEID" COL27, b."NAME" COL28, b."ENTITYTYPE" COL29, |
b."PARENTNAMEKEY" COL30, b."TIMECODE" COL31, b."TIMERATE" COL32, b."NAME" xj1 FROM "VWINVENTORINDIVIDUAL" a JOIN |
"NAME" b ON (a."NAMEKEY" = b."NAMEKEY") WHERE (1=1) |
The QuickSearchMethod(Ex:-QuickSearchInventor) has been written like below snapshot :
public Collection<Inventor> QuickSearchInventor(string pSearchText, string[] pSearchFields, int pStartFrom, int pFetchCount, bool pIsShowAll, InvokeContext ctx) |
{ |
Collection<Inventor> serviceResult = null; |
try |
{ |
using (IObjectScope scope = NameScopeProvider.GetNewObjectScope()) |
{ |
IQueryable<MtInventor> result; |
result =from c in scope.Secure<MtInventor>() |
where true |
orderby c.Name |
select c; |
var cnt = result.Count<MtInventor>(); |
if (result.Count<MtInventor>() > 0) |
{ |
serviceResult =new Collection<Inventor>(); |
using (NameComponentFacade<MtInventor, Inventor> mapper = new NameComponentFacade<MtInventor, Inventor>()) |
{ |
foreach (MtInventor modelRecord in result) |
{ |
if (!String.IsNullOrEmpty(pSearchText)) |
{ |
bool isRecordMatchWithFilterCriteria = CommonHelper.IsMatch(modelRecord, pSearchText, pSearchFields); |
if (!isRecordMatchWithFilterCriteria) continue; |
} |
serviceResult.Add(mapper.GetContractObject(modelRecord)); |
} |
if (pFetchCount != 0 && pFetchCount >= 0 && !pIsShowAll) |
{ |
serviceResult =new Collection<Inventor>(serviceResult.Skip(pStartFrom).Take(pFetchCount).ToList<Inventor>()); |
} |
} |
} |
} |
} |
catch (Exception ex) |
{ |
throw new Exception("Error in retrieving records : (" + ex.Message + ")", ex); |
} |
return serviceResult; |
} |
It would be great if you can give some idea for resolving this issue.
Thank you for your kind assistance.
Best Regards,
Ujjwal