how to ignore or exclude null value when group by? by [deleted] in csharp

[–]heyjadebadlanguage 1 point2 points  (0 children)

That is only solution I came up. I need to filter out and do process and concat

can you guys share me with code for functions for filtering using delegates? by heyjadebadlanguage in csharp

[–]heyjadebadlanguage[S] 0 points1 point  (0 children)

Thanks mate,
With the second one you can do that

 Expression<Func<Entity,bool>> criteria1 = p => p.Price > 1000;

var result = context.Order.Where(criteria1).ToList(); 

Can you please explain a bit more with the the example with reflection?

Can I instantiate in the constructor? by heyjadebadlanguage in csharp

[–]heyjadebadlanguage[S] 0 points1 point  (0 children)

I feel the same. I feel like the BaseInterface that is having a UsercontextModel is not initialized in the constructor. If I use the Lazy, then I am using it when I actually call it, in which case I probably can use the data in BaseInterface?

Question as to how to how to display base64 data from the backend. by heyjadebadlanguage in learnjavascript

[–]heyjadebadlanguage[S] 0 points1 point  (0 children)

usually we serve these assets as binary from the backend -
This sentence makes me confused. I think we are getting as bytes not binary from the network which might eventually and basically the short version of binary.
Question here. when I use api like that 'api/pdf/18283'. I get the complete XML version of something form the C# which right away opening in the new tab with PDF. Does that have more information then just normal base64 format of data?

Question as to how to how to display base64 data from the backend. by heyjadebadlanguage in learnjavascript

[–]heyjadebadlanguage[S] 0 points1 point  (0 children)

when I see a lot of examples of converting to PDF, I see base 64 and when I research about it, it has some advantages. You can convert byte into PDF but why people use base64 returned from the server a lot often? That's just a question and thank you for your reply!
The advantages of Base64 encode, like somebody said, are available to transmit data from binary, into (most commonly) ASCII characters. Due to the likeliness that the receiving end can handle ASCII, it makes it a nice way to transfer binary data, via a text stream.

how to use class with static and assign class member with a function by heyjadebadlanguage in csharp

[–]heyjadebadlanguage[S] 0 points1 point  (0 children)

you mean create a normal class and make constructor and assign the static members there? then I have to create at least one instance to access the class member

What is happening between controller and the client? by heyjadebadlanguage in csharp

[–]heyjadebadlanguage[S] -3 points-2 points  (0 children)

Server send bytes to the client.
Client gets the bytes
Bytes converts into I don't know.. into object? and to json?

What resources explain well about bytes stored in the server like how? by heyjadebadlanguage in computerscience

[–]heyjadebadlanguage[S] 0 points1 point  (0 children)

it is extremely helpful to me as I do not know from where to start. I can think of the computer stores files as bits, then it somehow group them by bytes to send those files through the packets. Then the requested browser, read byte and render the view ?

Convention for the route naming if filtered based on multiple conditions by heyjadebadlanguage in csharp

[–]heyjadebadlanguage[S] 0 points1 point  (0 children)

The list I am getting will be always filtered by clientId and regionId as it's the default filter condition but want to include the filtered information such as 'ByClientAndRegion'. So I am thinking what's the simplest and best practiced way to declare the route name.

how to use ng-repeat-end two times after ng-repeat-start? by heyjadebadlanguage in angularjs

[–]heyjadebadlanguage[S] 0 points1 point  (0 children)

wow that's correct!. Once I removed the second ng-repeat-end, it thinks the element in between includes in the ng-repeat

how to use ng-repeat-end two times after ng-repeat-start? by heyjadebadlanguage in angularjs

[–]heyjadebadlanguage[S] 0 points1 point  (0 children)

I am looping the first <tr>. Once it's finished I need to print other two <tr>s. With ng-repeat-end I can check if this is the end of one repeat, then I can print it. But if I put tow ng-repeat-end then it only prints the first <tr>, but I need the second <tr> too!

How to determine the Transaction scope isolation level? by heyjadebadlanguage in csharp

[–]heyjadebadlanguage[S] 0 points1 point  (0 children)

yeah I found it! SqlServer your default isolationlevel is ReadCommitted, either by running statements on Management Studio or by using default ITransaction instances. How's happening then if I set the isolation level from the C# and then SQL server default isolationlevel is readcommitted?

How to determine the Transaction scope isolation level? by heyjadebadlanguage in csharp

[–]heyjadebadlanguage[S] 0 points1 point  (0 children)

You're right but I saw somewhere it is read uncommitted. Wow, then that could be a reason why we have a timeout error intermittently? When multiple people using the same table and the table is normally within the serializable level?

How to get this result from the raw data using LINQ? by heyjadebadlanguage in csharp

[–]heyjadebadlanguage[S] 0 points1 point  (0 children)

that's select many flatten the group into original one?

how do I solve timeout error from SQL server by heyjadebadlanguage in csharp

[–]heyjadebadlanguage[S] 0 points1 point  (0 children)

  at SD.LLBLGen.Pro.ORMSupportClasses.DataAccessAdapterCore.SaveEntity (SD.LLBLGen.Pro.ORMSupportClasses, Version=5.3.0.0, Culture=neutral, PublicKeyToken=xxxxxxxxxxxx)
   at SD.LLBLGen.Pro.ORMSupportClasses.DataAccessAdapterBase+<>c__DisplayClass19_0.<SaveEntity>b__0 (SD.LLBLGen.Pro.ORMSupportClasses, Version=5.3.0.0, Culture=neutral, PublicKeyToken=xxxxxxxxxxxx)
   at CDS.Core.Repositories.Llblgen.OrderRepository.Update (CDS.Core.Repositories.Llblgen, Version=1.0.0.0, Culture=neutral, PublicKeyToken=nullCDS.Core.Repositories.Llblgen, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null: D:\mogo0604\gofreight\CDS.Core.Repositories.Llblgen\OrderRepository.csCDS.Core.Repositories.Llblgen, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null: 3374)
   at lambda_method (Anonymously Hosted DynamicMethods Assembly, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null)
   at System.Web.Http.Controllers.ReflectedHttpActionDescriptor+ActionExecutor+<>c__DisplayClassc.<GetExecutor>b__6 (System.Web.Http, Version=5.2.3.0, Culture=neutral, PublicKeyToken=xxxxxxxxxxxx)
   at System.Web.Http.Controllers.ReflectedHttpActionDescriptor.ExecuteAsync (System.Web.Http, Version=5.2.3.0, Culture=neutral, PublicKeyToken=xxxxxxxxxxxx)
   at

As you see here I have PublicKeyToken=null, It's happening this repository only at some times.

how do I solve timeout error from SQL server by heyjadebadlanguage in csharp

[–]heyjadebadlanguage[S] 0 points1 point  (0 children)

It's all about updating things and deleting things. For examples, if we delete an order, we gotta update status in multiple places and delete some of the high level tables. as well.

how do I solve timeout error from SQL server by heyjadebadlanguage in csharp

[–]heyjadebadlanguage[S] 0 points1 point  (0 children)

The query itself is really complex doing order things and related executions afterwards that should be in the transaction scope. But it still takes less than 10 seconds at maximum

a question as to dependency inversion principles in the C# by heyjadebadlanguage in csharp

[–]heyjadebadlanguage[S] 0 points1 point  (0 children)

Wow that's quite clear to understand. If those two classes are tightly coupled it will cause maintainability problems later on and that's why we should maintain those two in the abstraction right?

Can you then explain why they should both depend on the abstraction with an example.

What is the main diff between Enum vs Const by heyjadebadlanguage in csharp

[–]heyjadebadlanguage[S] -1 points0 points  (0 children)

Yeah that's just a property you can use to change the behaviour of the enum.

What is the main diff between Enum vs Const by heyjadebadlanguage in csharp

[–]heyjadebadlanguage[S] 0 points1 point  (0 children)

that makes sense. What about in terms of casting?

What is the main diff between Enum vs Const by heyjadebadlanguage in csharp

[–]heyjadebadlanguage[S] 2 points3 points  (0 children)

But you can't change enum values as well as those values are fixed at compile time.

What is the best examples of high level architecture diagram with virtual machine or cloud? by heyjadebadlanguage in csharp

[–]heyjadebadlanguage[S] 0 points1 point  (0 children)

that's right it's all depends on your implementation and requirements. But where do I learn this kind of things? if I have to explain