Wyobraźmy sobie następujący scenariusz. Mamy jakąś bazę danych i chcemy do niej wstawić gotowe testowe rekordy lub zaktualizować już istniejące. Jak możemy to zrobić?
Bazy danych i XML 2329 dni, 9 godzin, 13 minut temu 150 źrodło rozwiń
We have many solutions for versioning data through time. One of the cleanest, most transparent and pretty effortless in my opinion are Temporal Tables which are available in MS SQL 2016+. What’s really great about that approach is that unless you need to retrieve state from the certain point in time or browse through changes in a specified time range, you can query against a versioned table in an exactly same way that you would do with any other one.
Bazy danych i XML 2430 dni, 8 godzin, 1 minutę temu 77 źrodło rozwiń
Recently I’ve had occasion to work much more than usually with NHibernate. This is a really great ORM and a very mature project, but when you make a mistake it informs you about that in a very generic way (in most cases). The problem that hunted me for a few days was the issue with field length constrains (which was caused by insufficient and inconsistent REST API validation). When there was a discrepancy between declared field length in NHibernate mapping and validation logic (or the vali...
Bazy danych i XML 2433 dni, 10 godzin, 3 minuty temu 52 źrodło rozwiń
My last blog post was about a feature in SQL Server called Row Level Security Policy. It’s quite simple and known feature for people who’re working directly with databases. But most .NET developers are using ORM of some kind to work with DB, and some of them tend to be blind to stuff that is not available through object model in an easy way. And since Entity Framework is most popular ORM in C# environment and my ORM of choice in most cases, I’ll show you how to use RLS in it.
Bazy danych i XML 2484 dni, 21 godzin, 48 minut temu 105 źrodło rozwiń
In some scenarios, like single-database multi-tenant or soft delete ones, you could want to restrict access to your rows based on a value stored in one or more values stored in your columns in example IsDeleted flag or some kind of TenantId column. Since SQL Server 2016 we have a wonderful tool for that called Row Level Security Policy.
Bazy danych i XML 2500 dni, 7 godzin, 9 minut temu 114 źrodło rozwiń
When I’ve started working with Azure SQL there were some differences to SQL Server that I’ve needed to get used to. One of the first was that you just can’t query other databases that you’re already in, querying for [OtherDB].[dbo].[SomeTable] just wasn’t possible anymore. It appears that it may not be possible, but you actually can query for data in other databases.
Written by Dawid Sibińskion I’ve recently met a weird issue with T-SQL scripts at work and would like to share it with you today 🙂 On daily basis I work a lot with MS SQL Server databases. We often create many T-SQL objects (tables, views, procedures, functions) and because of some reasons we cannot use Entity Framework or another from widely available ORMs. Nonetheless, all objects created in the database must be kept in the form of SQL scripts (files) containing set of CREATE, ALTER, INSERT,...
Bazy danych i XML 2583 dni, 8 godzin, 3 minuty temu 69 źrodło rozwiń
Supporting and maintaining an old and inefficient websites bring us a lot of problems and stress. Especially when a website was started a long time ago in already pretty outdated technology and architecture, but somehow it succeeded and can’t handle its own popularity. What a coincidence, I have the website exactly like this one! And recently I’ve managed to get rid of one stress point, at least for now. All this thanks to benefits of one particular public cloud service.
Co mają wspólnego StarWars i bazy danych? Jak to co? Walkę z gwiazd(k)ami 🙂
Bazy danych i XML 2607 dni, 7 godzin, 25 minut temu 160 źrodło rozwiń
How to simply search the entire database knowing only the parameters/names of the returned values?
Bazy danych i XML 2622 dni, 11 godzin, 46 minut temu 167 źrodło rozwiń
Porady w tsql: jak uzyskać pierwszy/ostatni dzień w roku / miesiącu oraz inne operacje na datach. Dodatkowo wytłumaczenie zasad działania.
Bazy danych i XML 2626 dni, 11 godzin, 8 minut temu 145 źrodło rozwiń
Lista kilku ważnych dobrych praktyk programowania w TSQL.
Bazy danych i XML 2632 dni, 9 godzin, 46 minut temu 439 źrodło rozwiń
Czy Snapshot Isolation to idealny sposób na rozwiązanie wszystki problemów z Twoją bazą? Jakie anomalie możemy napotkać używając go i na co trzeba uważać? Zapraszam do lektury
Architektura 2640 dni, 9 godzin, 34 minuty temu 59 źrodło rozwiń
Stale rosnąca baza pytań rekrutacyjnych dla programistów.
Poznaj jeden ze sposobów ochrony swoich danych przechowywanych w usłudze Microsoft Azure.
Daj się poznać 2017 2791 dni, 21 godzin, 2 minuty temu 44 źrodło rozwiń
Tworząc bazę danych dla SmogBota, mimo że jest ona stosunkowo niewielka jeśli chodzi o złożoność i ilość obiektów, postanowiłem zaimplementować kilka dobrych praktyk i pokazać w jaki sposób można zwiększyć bezpieczeństwo takowej bazy, nie męcząc się zbytnio :) Całość mechanizmu jest prosta i przejrzysta a opiera się to na schema bazodanowych.
Daj się poznać 2017 2823 dni, 8 godzin, 47 minut temu 98 źrodło rozwiń
C#, SQL, JS i ten sam problem - referencje bez ustawionych wartości. Kilka luźnych analogii i sposobów na radzenie sobie z NullRefenceException i podobnymi zjawiskami. I na koniec o tym, jak to wygląda w świecie F#.
Sztuka programowania 2836 dni, 22 godziny, 24 minuty temu 230 źrodło rozwiń
Yep, it’s not rocket science, but it can really help you in your everyday work. If you don’t know about this trick – you can waste a lof of time.
Bazy danych i XML 2868 dni, 9 godzin, 9 minut temu 96 źrodło rozwiń
I want to get in a good habit of recording some simple tutorials from time to time using the English language, so here comes the first one about my experience with running the SQL Server on Linux. Enjoy! The first thing you need to do is to open the following website and follow the selected installation guide. For example, I’m using the ElementaryOS so I chose the Ubuntu guide. Also, make sure you’ll install the SQL Server Tools. Eventually,...
How to show your SQL19 Dec 2016 | Category: Programming | Tag: F#, SQL Last time we did a good job. We tracked store procedures hitting our server and we printed some details to the console. This was good, but this is not the end of what we can do. The first version contained hard-coded file name used to extract data and we only put the result on the console. Today we'll change this hard-coded file to a parameter and we add printing result to the file and to the chart.